Skip to content

worker: make termination interrupt a worker blocked in Atomics.wait - #32802

Closed
robobun wants to merge 2 commits into
mainfrom
farm/26492eef/worker-terminate-atomics-wait
Closed

worker: make termination interrupt a worker blocked in Atomics.wait#32802
robobun wants to merge 2 commits into
mainfrom
farm/26492eef/worker-terminate-atomics-wait

ci: retrigger

f9540be
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Aug 9, 2026 in 18m 50s

Code review found 1 potential issue

Found 1 candidates, confirmed 1. See review comments for details.

Details

Severity Count
🔴 Important 0
🟡 Nit 1
🟣 Pre-existing 0
Severity File:Line Issue
🟡 Nit src/jsc/bindings/bindings.cpp:5197 SigintWatcher::signalAll shares the same bug: breakOnSigint cannot interrupt Atomics.wait

Annotations

Check warning on line 5197 in src/jsc/bindings/bindings.cpp

See this annotation in the file changed.

@claude claude / Claude Code Review

SigintWatcher::signalAll shares the same bug: breakOnSigint cannot interrupt Atomics.wait

Same-class sibling not covered: `SigintWatcher::signalAll()` (src/jsc/bindings/vm/SigintWatcher.cpp:210) calls `globalObject->vm().notifyNeedTermination()` directly from its background thread — the identical off-thread pattern fixed here, but bypassing this wrapper, so it does not get `setHasTerminationRequest()`. Consequence: `vm.runInThisContext('Atomics.wait(...)', { breakOnSigint: true })` + Ctrl+C wakes the waiter, which sees `hasTerminationRequest()` still false and re-parks forever (Node