cpu: verify the five Bink frame plane allocation requests #170

Manually merged
github merged 1 commit from gh-pr/170/head into gh-pr/170/base 2026-11-26 21:31:47 +00:00
Owner

@⁠Vonsek on GitHub · 2026-11-21 17:54 UTC · original
Vonsek:codex/bink-frame-plane-plan → main · +143 −7 · 7 files · 1 commits · merged 2026-11-21 18:10 UTC

Change

Trace the five requests from one iteration of BinkAllocateFrameBuffers to the grouped descriptor builder. The translated package slice and source-built fixture expose the destination address and byte count for each enabled plane. The observer also checks that the pitch store follows the request. Refs #157.

Verification

At 39d0b64 on Windows x64 with MSVC 19.44, the new check failed on the prior DLL because the frame-plane entry was absent. The native control, its translation and the translated package loop passed all 32 enable masks at each of three frame positions. With all slots enabled the five sizes were 672, 96, 96, 672 and 672 bytes. The test compares the entire frame table after every run, including inactive slots.

cmake --build --preset dev --target cpu_bink_descriptors_lifted cpu_bink_package_descriptors
ctest --preset dev --no-tests=error -R '^cpu_bink_(package_)?(frame_planes|descriptors)$'
python -B tests/cpu/bink_frame_planes_check.py out/build/dev/cpu_bink_descriptors.dll out/build/dev/cpu_bink_descriptors_lifted.dll out/build/dev/cpu_bink_package_descriptors.dll

All four CTests passed; the direct Python comparison exited zero.

Evidence and follow-up

The MASM fixture and Python plane records are original MIT-licensed source. The local comparison binds only the append calls to an observer and supplies the frame index, cursor and pitches at loop entry. The allocator and frame decoder are outside the measured region. Build options and experiment notes.

Checklist

  • One reviewable behavior.
  • Commands and results included.
  • Disabled planes, nonzero indices and pitch-store ordering covered.
  • README and experiment notes updated.
  • No game files, dumps, distribution links or secrets.

AI-assisted.

**@⁠Vonsek** on GitHub · 2026-11-21 17:54 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/170) `Vonsek:codex/bink-frame-plane-plan` → `main` · +143 −7 · 7 files · 1 commits · merged 2026-11-21 18:10 UTC ## Change Trace the five requests from one iteration of BinkAllocateFrameBuffers to the grouped descriptor builder. The translated package slice and source-built fixture expose the destination address and byte count for each enabled plane. The observer also checks that the pitch store follows the request. Refs #157. ## Verification At 39d0b64 on Windows x64 with MSVC 19.44, the new check failed on the prior DLL because the frame-plane entry was absent. The native control, its translation and the translated package loop passed all 32 enable masks at each of three frame positions. With all slots enabled the five sizes were 672, 96, 96, 672 and 672 bytes. The test compares the entire frame table after every run, including inactive slots. ```powershell cmake --build --preset dev --target cpu_bink_descriptors_lifted cpu_bink_package_descriptors ctest --preset dev --no-tests=error -R '^cpu_bink_(package_)?(frame_planes|descriptors)$' python -B tests/cpu/bink_frame_planes_check.py out/build/dev/cpu_bink_descriptors.dll out/build/dev/cpu_bink_descriptors_lifted.dll out/build/dev/cpu_bink_package_descriptors.dll ``` All four CTests passed; the direct Python comparison exited zero. ## Evidence and follow-up The MASM fixture and Python plane records are original MIT-licensed source. The local comparison binds only the append calls to an observer and supplies the frame index, cursor and pitches at loop entry. The allocator and frame decoder are outside the measured region. [Build options and experiment notes](https://github.com/Vonsek/Xbox2Windows/blob/39d0b64/docs/experiments.md#frame-plane-requests-in-binkallocateframebuffers). ## Checklist - [x] One reviewable behavior. - [x] Commands and results included. - [x] Disabled planes, nonzero indices and pitch-store ordering covered. - [x] README and experiment notes updated. - [x] No game files, dumps, distribution links or secrets. AI-assisted.
Compare the five per-frame decisions with an independent control so pitch selection, destination addresses and append order can be checked without a video file.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 21:31:46 +00:00
github manually merged commit 39d0b644bc into gh-pr/170/base 2026-11-26 21:31:47 +00:00
Author
Owner

@⁠chatgpt-codex-connector[bot] on GitHub · 2026-11-21 17:54 UTC · original · edited 2026-11-21 17:58 UTC

Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-21T17:58:38.043598Z 39d0b64 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@⁠codex review" or "@⁠codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

**@⁠chatgpt-codex-connector[bot]** on GitHub · 2026-11-21 17:54 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/170#issuecomment-7066855890) · edited 2026-11-21 17:58 UTC <!-- codex-pull-request-review-summary --> <!-- codex-review-state:v1 {"code_review":{"commit_sha":"39d0b644bc153d8c9defdce783826afa59e19fb3","has_any_findings":false,"has_unresolved_findings":false,"status":"completed"},"security_review":{"commit_sha":null,"has_any_findings":null,"has_unresolved_findings":null,"status":null}} --> <details> <summary><strong>Codex Review Summary</strong>: ✅ Completed</summary> This comment shows the latest Codex review activity on this pull request. | Review | Status | Commit | Review trigger | | --- | --- | --- | --- | | 📝 **Code Review** | ✅ **Completed** <relative-time datetime="2026-11-21T17:58:38.043598Z">2026-11-21T17:58:38.043598Z</relative-time> | `39d0b64` | PR opened | <details> <summary>ℹ️ About Codex in GitHub</summary> <br/> [Your team has set up Codex to review pull requests in this repo](https://chatgpt.com/codex/cloud/settings/general). Reviews are triggered when you - Open a pull request for review - Mark a draft as ready - Comment "@⁠codex review" or "@⁠codex security review". Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. </details> </details>
This discussion has been locked. Commenting is limited to contributors.
No description provided.