[webkit-changes] [WebKit/WebKit] 5ed2b8: Make CONJECTURE_ASSERT crash in WTFCrashDueToConje...
Commit Queue
noreply at github.com
Fri Sep 13 13:38:05 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 5ed2b87de57716b0af4ffc7f36143a3fa73a4733
https://github.com/WebKit/WebKit/commit/5ed2b87de57716b0af4ffc7f36143a3fa73a4733
Author: Mark Lam <mark.lam at apple.com>
Date: 2024-09-13 (Fri, 13 Sep 2024)
Changed paths:
M Source/WTF/wtf/Assertions.cpp
M Source/WTF/wtf/Assertions.h
M Source/WTF/wtf/Threading.cpp
Log Message:
-----------
Make CONJECTURE_ASSERT crash in WTFCrashDueToConjectureAssert.
https://bugs.webkit.org/show_bug.cgi?id=279562
rdar://135839946
Reviewed by Alexey Proskuryakov.
This will make it easier to distinguish from other normal assertion failures.
1. Also changed the failure message and dumped the stack. For reference, here's an
example of a failure message which I fabricated by inserting a bad CONJECTURE_ASSERT:
CONJECTURE ASSERTION FAILED: vmCreationShouldCrash
./runtime/VM.cpp(244) : JSC::VM::VM(VMType, HeapType, WTF::RunLoop *, bool *)
1 0x103389e34 WTFCrashDueToConjectureAssert
2 0x1041f869c JSC::VM::VM(JSC::VM::VMType, JSC::HeapType, WTF::RunLoop*, bool*)
3 0x1041f9768 JSC::VM::tryCreate(JSC::HeapType, WTF::RunLoop*)
4 0x100df5690 jscmain(int, char**)
5 0x100df519c main
6 0x19ea38274 start
2. Also added a runtime switch for enabling / disabling CONJECTURE_ASSERTs. Note: there
is already a build time flag ENABLE_CONJECTURE_ASSERT that needs to be set to 1 in order
for CONJECTURE_ASSERTs to be supported. In addition to that, CONJECTURE_ASSERTs is
disabled by default at runtime. To enable it, you need to define the environment
variable ENABLE_WEBKIT_CONJECTURE_ASSERT.
A reminder about using CONJECTURE_ASSERT: it is not enable in the EWS builds, and hence,
is not tested by the EWS. The person who adds a CONJECTURE_ASSERT is responsible for testing
that it builds (with ENABLE_CONJECTURE_ASSERT=1) and that it runs (passes tests).
* Source/WTF/wtf/Assertions.cpp:
* Source/WTF/wtf/Assertions.h:
* Source/WTF/wtf/Threading.cpp:
(WTF::initialize):
Canonical link: https://commits.webkit.org/283648@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list