Skip to content

diag: bisect parked-worker finalization across Bun and WebKit (do not merge) - #206

Closed
steipete wants to merge 3 commits into
mainfrom
claude/diag-parked-worker-gc-r2
Closed

steipete wants to merge 3 commits into
mainfrom
claude/diag-parked-worker-gc-r2

Conversation

@steipete

@steipete steipete commented Oct 25, 2026 •

Copy link
Copy Markdown

Diagnostic only; do not merge.

The unchanged parked-worker immediate-GC case added by #129 fails on the signed Windows ARM64 executable from 6aba42d75d, while the prior qualified 807211511f executable passes. Previous native traces show a complete wake/timer/GC-end sequence without a finalizer enqueue.

This draft runs two crossed builds in one native ARM64 diagnostic iteration:

Bun source Published engine
6aba42d75d a2976f02 (prior qualified engine)
807211511f 419b5a04 (current engine)

Each build uses the complete checksum-pinned engine manifest from the corresponding source revision. The native job checks the actual executable revision, engine revision, PE architecture, and unchanged regression-case hash. Ten interleaved trials of each crossed build run alongside the original signed executables as controls. No timeout or assertion is changed.

A separate dispatch tests an environment-gated call to the existing clearStackBelowCaller immediately before the asynchronous collection request, comparing the same executable with that call disabled and enabled. The helper and its clearing size are unchanged. A passing diagnostic would support the hypothesis, not prove a stale root or a production fix.

The existing release workflow is temporarily reduced to dispatch-only diagnostic jobs, with no publication or signing jobs. Other build/lint jobs are suppressed on this diagnostic branch. The investigation has a maximum of four ARM64 iterations; this draft will close unmerged afterward. No WebKit source or release is changed.

The first crossed-build attempt stopped at compilation: the coverage/profiler function-range tuple and block-query APIs differ across engine versions. The next crossed attempt uses small, explicit adapters only in CodeCoverage.cpp and JSInspectorProfiler.cpp; the unchanged test runs with coverage disabled. Adapter hashes and the exact modified-path list are retained in build metadata. These adapters do not alter GC, allocation, event-loop, or worker code.

@steipete

Copy link
Copy Markdown
Author

Closing this diagnostic draft unmerged. The native comparison places the regression on the engine side:

Native Windows ARM64 executable Pass Original 10 s timeout
Original signed S7 10 0
Original signed S8 0 10
S8 Bun + S7 engine 10 0
S7 Bun + new engine 0 10

Crossed comparison, run 40166390479. Both crossed builds use the complete checksum-pinned engine manifest. Coverage-only adapters reconcile profiler APIs; the test runs without coverage. No GC, worker, or test code changes are used in this comparison.

The final async-clearing comparison, run 40169137156, reuses the same diagnostic executable: clearing OFF timed out 10/10; clearing ON passed 10/10. Original signed controls again produced S8 10/10 timeouts and S7 10/10 passes. All 80 completed trial logs, executable identities/hashes, and engine/adapter manifest hashes were checked. The original test and deadline are unchanged.

The helper's effect supports stack- or timing-sensitive retention but does not identify a collection-time root or an exact causal engine commit. The earlier failing traces complete wake delivery, timer firing, and GC end without finalizer enqueue. A retained dump identifies the marked fixture victim, but contains no pointer into it in the captured stacks or general-purpose/SIMD registers; that later snapshot cannot establish why it was marked. The requested Windows register/stack-capture files and Heap::gatherStackRoots are unchanged across the old/new engine replays and published pins.

The first crossed attempt failed compilation on the profiler API differences. The first async native attempt failed before any trial because of an artifact-directory assumption. Those setup failures are recorded, and their repairs received Codex review. No runtime fix is proposed here. An engine repair needs its own investigation and WebKit release; this draft and its diagnostic branch must not be merged.

@steipete steipete closed this Oct 25, 2026
@steipete
steipete deleted the claude/diag-parked-worker-gc-r2 branch October 25, 2026 06:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant