Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: ef6ad2a4ee36fc5121380b39628e17a8624e9ec6
https://github.com/WebKit/WebKit/commit/ef6ad2a4ee36fc5121380b39628e17a8624e9ec6
Author: Dan Hecht <[email protected]>
Date: 2026-10-08 (Thu, 08 Oct 2026)
Changed paths:
M Source/JavaScriptCore/heap/Collector.cpp
M Source/JavaScriptCore/heap/Heap.cpp
Log Message:
-----------
[JSC] Suspend compiler threads when any of a collection's heaps has JIT plans
https://bugs.webkit.org/show_bug.cgi?id=326695
rdar://189426550
Reviewed by Marcus Plutowski.
A collection reads the JIT worklist threads' safepoints, in the JIT Worklist
constraint and when End removes dead plans, which is safe only while it has
suspended those threads. It decides whether to suspend from its one heap's VM;
once it covers several heaps, it has to suspend if any of their VMs has active
plans. The worklist is process-wide, so one suspension covers every VM's
threads.
Also assert, where Heap walks the worklist, that a heap with active plans is
walked only while its collection has suspended the threads; the walks'
existing assertIsOwner() cannot tell, since a compiling thread holds its own
lock. And remove a stale comment about per-tier worklists.
No change in behavior.
* Source/JavaScriptCore/heap/Collector.cpp:
(JSC::Collector::suspendCompilerThreads):
* Source/JavaScriptCore/heap/Heap.cpp:
(JSC::Heap::removeDeadCompilerWorklistEntries):
(JSC::Heap::clearConcurrentRetainedDataIfPossible):
Canonical link: https://commits.webkit.org/323111@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications