docs(exe_fail_fast): move shimmed VirtualFree and ReadFile into shims section #2426

Merged
leonida/mandy
Andretuta merged 1 commit from docs/exe-fail-fast-shims-sync into main 2026-11-28 18:29:53 +00:00

Pull request successfully merged and closed

Andretuta commented 2026-11-27 03:17:33 +00:00

Claimed in the coordination issue as: DOC-EXE-FAIL-FAST-SHIMS (https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7208856827)

What and why

  • Update docs/exe_fail_fast.md from d0da7dad to d1dff7949: VirtualFree is shimmed by TitleVirtualFree in runtime/shims/xmem.cpp and ReadFile is shimmed by read_file in runtime/shims/file_system.cpp.
  • Move both imports from Host and CRT to Shims: results to keep (15 shimmed imports, 12 host/CRT imports; all 27 fatal-checked imports and 78 call sites preserved).

Tested

  • Verified directly against runtime/shims/xmem.cpp and runtime/shims/file_system.cpp.
  • python -I tests/test_import_fail_fast.py (10/10 OK), all tests/test_docs_*.py + tests/test_text_write_line_endings.py (OK).
  • python -I scripts/check_no_game_data.py docs/exe_fail_fast.md: exit 0.

GPUs tested: n/a

AI-assisted: yes (Antigravity gemini-4-neon)

Checklist

  • Based on current main and merges cleanly (a conflicting pull request is labeled needs rebase).
  • One topic; follow-up work goes in a new pull request.
  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed. (n/a — not a translator rule)
Claimed in the coordination issue as: DOC-EXE-FAIL-FAST-SHIMS (https://github.com/ubiquitarianism/leonida/issues/1608#issuecomment-7208856827) ### What and why - Update `docs/exe_fail_fast.md` from `d0da7dad` to `d1dff7949`: `VirtualFree` is shimmed by `TitleVirtualFree` in `runtime/shims/xmem.cpp` and `ReadFile` is shimmed by `read_file` in `runtime/shims/file_system.cpp`. - Move both imports from *Host and CRT* to *Shims: results to keep* (15 shimmed imports, 12 host/CRT imports; all 27 fatal-checked imports and 78 call sites preserved). ### Tested - Verified directly against `runtime/shims/xmem.cpp` and `runtime/shims/file_system.cpp`. - `python -I tests/test_import_fail_fast.py` (10/10 OK), all `tests/test_docs_*.py` + `tests/test_text_write_line_endings.py` (OK). - `python -I scripts/check_no_game_data.py docs/exe_fail_fast.md`: exit 0. GPUs tested: n/a AI-assisted: yes (Antigravity gemini-4-neon) ### Checklist - [x] Based on current `main` and merges cleanly (a conflicting pull request is labeled `needs rebase`). - [x] One topic; follow-up work goes in a new pull request. - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here. - [ ] A new translator rule is in the contract table of `docs/design.md`, with how it was confirmed. *(n/a — not a translator rule)*
tiguan26 approved these changes 2026-11-27 06:03:19 +00:00
tiguan26 left a comment

Approving. Merged onto current main together with the other doc PRs of this batch: no conflicts, and the doc validators (tests/ -k doc: 95 passed, 207 subtests) pass. Checked against main: kernel32!VirtualFree is shimmed (TitleVirtualFree in xmem.cpp, bound through TITLE_VIRTUAL_MEMORY on the api-ms memory sets), and ReadFile is bound to file_system.cpp's read_file, including the api-ms-win-core-file-* sets, so the old "Host (not shimmed)" rows were stale. I recounted the table: 15 shimmed rows (with CreateFileW) and 12 host/CRT if _Getcat's two facets count separately, which matches the new totals.

Approving. Merged onto current main together with the other doc PRs of this batch: no conflicts, and the doc validators (`tests/` -k doc: 95 passed, 207 subtests) pass. Checked against main: `kernel32!VirtualFree` is shimmed (`TitleVirtualFree` in `xmem.cpp`, bound through `TITLE_VIRTUAL_MEMORY` on the api-ms memory sets), and `ReadFile` is bound to `file_system.cpp`'s `read_file`, including the `api-ms-win-core-file-*` sets, so the old "Host (not shimmed)" rows were stale. I recounted the table: 15 shimmed rows (with `CreateFileW`) and 12 host/CRT if `_Getcat`'s two facets count separately, which matches the new totals.
MoonEyes commented 2026-11-28 18:29:51 +00:00

Red/green: Docs only: Moves VirtualFree and ReadFile from the host table to the shims table in docs/exe_fail_fast.md, matching the shims bound on main.
Targeted batch (PR tests, tests importing the changed modules, docs tests, translator when touched) merged on main 7daa4a4a5 in GitHub Actions: no new failure. Docs checked by a separate reviewer against the code on main.
AI-assisted (Claude Code, Claude Opus 5.5)

Red/green: Docs only: Moves VirtualFree and ReadFile from the host table to the shims table in docs/exe_fail_fast.md, matching the shims bound on main. Targeted batch (PR tests, tests importing the changed modules, docs tests, translator when touched) merged on main 7daa4a4a5 in GitHub Actions: no new failure. Docs checked by a separate reviewer against the code on main. AI-assisted (Claude Code, Claude Opus 5.5)
Sign in to join this conversation.
No description provided.