Skip to content

Run FLS cleanup callbacks before process detach - #756

Merged
gmh5225 merged 1 commit into
devfrom
codex/windows-fls-exit-cleanup
Oct 9, 2026
Merged

gmh5225 merged 1 commit into
devfrom
codex/windows-fls-exit-cleanup

Conversation

@gmh5225

@gmh5225 gmh5225 commented Oct 9, 2026 •

Copy link
Copy Markdown
Contributor

Normal PE entry return, ExitProcess and RtlExitUserProcess skipped registered FLS cleanup callbacks. Independent original programs print both body and cleanup records, while the previous process model printed only the body. Run current-fiber cleanup before DLL/TLS process-detach notifications using the existing ABI, observer provenance and execution budgets. Clear each completed fiber value while retaining its process-wide index, including callbacks allocated in later slots during cleanup.

Termination-time loader operations have a different contract from ordinary load/unload. Refuse these requests before module mutation; an independent original Windows fixture records the corresponding native unload trace without treating it as a supported model contract.

Validation: regressions fail on the prior implementation. Final focused suite: 81 registered, 33 passed, 48 explicit platform/backend skips, zero failures. Four complete affected suites: 1,407 registered, 656 passed, 751 explicit skips, zero failures. Frozen-CLI checks pass for all three system exit paths, the existing Windows detach contract, and explicit loader refusal. The three system originals also pass native Wine checks; the full lifetime Wine traces differ from the existing Windows contract and are retained as separate observations. Native workflow preflight (84 tests), capability manifest (23 entries), pinned formatting, and all 297 Markdown files / ten translations pass. Four new mandatory tests bring the WHP inventory to 5,054 and KVM to 5,077. Exact-head native Windows execution failed at 96906f994ee71311548c54569379f6cb668baf6e; details are recorded below.

Native follow-up: run37995384869 completed with four failing checks. Two reproduce the earlier nested original mismatch; the independent native system/lifetime oracles also show Windows does not run the newly allocated child callback during the current exit sweep. All four ancillary jobs pass. The native semantic differences are being investigated with bounded original-program observations; native acceptance has not passed.

Follow-up: the native Windows FLS mismatches are corrected by #761, verified at 013385d5f96e6dbf2b3410b70e45c1a7e3ba9f31 and merged as 47e366b2b45b32b1acf226f0d929fed167a11d61. Exact-head WHP run 38020288691 passes all 5,056 mandatory cases, including the previously failing original-image and native termination checks. The earlier failed run above remains a failed validation of its original revision.

@gmh5225
gmh5225 merged commit 2bec771 into dev Oct 9, 2026
6 of 18 checks passed
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.

2 participants