Skip to content

Fix event-loop hang when dlopen'd Go/cgo lib coexists with WASM on Linux - #31161

Open
robobun wants to merge 21 commits into
mainfrom
farm/ebd23fe3/fix-31158-sigpwr-sa-onstack
Open

Fix event-loop hang when dlopen'd Go/cgo lib coexists with WASM on Linux#31161
robobun wants to merge 21 commits into
mainfrom
farm/ebd23fe3/fix-31158-sigpwr-sa-onstack

ship the real fix from WebKit#235, drop the band-aid

ce6f4c1
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed May 21, 2026 in 16m 38s

Code review found 2 potential issues

Found 5 candidates, confirmed 2. See review comments for details.

Details

Severity Count
🔴 Important 0
🟡 Nit 2
🟣 Pre-existing 0
Severity File:Line Issue
🟡 Nit scripts/build/deps/webkit.ts:10 prebuiltDestDir cache-key collision for autobuild-preview-* version string
🟡 Nit test/regression/issue/31158.test.ts:52-53 Stale test comment/step references removed post-dlopen band-aid

Annotations

Check warning on line 10 in scripts/build/deps/webkit.ts

See this annotation in the file changed.

@claude claude / Claude Code Review

prebuiltDestDir cache-key collision for autobuild-preview-* version string

nit: `prebuiltDestDir()` keys the cache extraction dir on `cfg.webkitVersion.slice(0, 16)`, and `"autobuild-preview-pr-235-a355e3e0".slice(0, 16) === "autobuild-previe"` — the PR number and commit hash are truncated away, so every `autobuild-preview-*` tag (including a future revision of #235) maps to the same shared-cache dir. The `.identity` stamp catches this within a single worktree, but with the machine-shared `$BUN_INSTALL/build-cache` across worktrees the colliding `-I` path can let ninja

Check warning on line 53 in test/regression/issue/31158.test.ts

See this annotation in the file changed.

@claude claude / Claude Code Review

Stale test comment/step references removed post-dlopen band-aid

These comments (and the file-header at lines 13-14, "call `dlopen` once more so the repair fires") describe the Bun-side `repair_jsc_gc_signal_after_dlopen()` band-aid that was deleted in ce6f4c16. The shipped fix is now the WTF ucontext-SP change (oven-sh/WebKit#235), which *tolerates* `SA_ONSTACK` rather than clearing it — nothing runs at this second `dlopen` anymore. Either drop step 2 (it's vestigial) or reword the comments to reflect the actual mechanism.