Assign BCPack refill bytes by each lane's read count #174
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/175"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from R0Y00/Xbox2Windows. Originally posted by Vonsek on 2026-11-21T17:58:17Z.
Change
tools/bcpack_probe.pycompared a constant lane's refill bytes with the supplied rounds by round position only:--prefetch-mask;A lane that does not read in the first round but reads in the second was therefore not checked at all, although under the round model that read consumes its first refill byte. A mask that gave a lane more reads than its header budget allows (for example a bit set for a verified constant lane with zero refills, or a second read for a one-refill lane) was silently ignored.
The probe now walks the two supplied rounds per lane and gives each read the lane's next refill byte, in consumption order.
first_refill_*andsecond_refill_*keep their names and meaning (first and second byte the lane consumes). Reads past the budget are listed as packet offsets underunbudgeted_read_offsets. Results for masks that were already handled are unchanged; the existing two-refill and one-refill tests pass as before. The--next-maskhelp text and the BCPack paragraph indocs/experiments.mddescribe the rule.This remains a diagnostic for the published fixed-symbol model; it does not resolve the variable BC7 lane models.
Verification
python3 -B tests/bcpack_check.py— 6 tests OK.test_refill_follows_lane_read_countuses the source-built headers already in the suite (two-refill lanede 05 03 0c 86 4eat 25000 blocks, one-refill lanede 04 01 00 11 30at 11358 blocks, verified constant lanede 03 01 00 40 02at 2 blocks). Withtools/bcpack_probe.pyfrommainit errors (KeyError: 'first_refill_offset') because the second-round first read is not reported; with this change it passes. The negative control replaces the expected byteACwith7D(the lane's second refill byte) and requiresfirst_refill_matchesto be false.--blocks 25000 --prefetch-mask 1 --next-mask 0x11reports lane 4first_refill_offset: 50,first_refill_matches: true.ctest --preset dev --no-tests=error -R '^bcpack_prefix_and_mip_tail$' -Vatea14ed4on Windows 11 build 26200.9974, VS Build Tools 2022 17.14 (MSVC 14.44.35207), Windows SDK 10.0.26100, Python 3.12: passed (Ran 6 tests, OK). The fullctest --preset dev --no-tests=errorpassed 86/86, withbvh_wave64_hardware,bvh_wave64_warpandwave_shuffle_warpskipped.Evidence and follow-up
All inputs are synthetic headers built in the test. Only two rounds can be supplied, so a lane can be checked against at most its first two refill bytes. Whether real streams follow this per-lane round order is still a hypothesis, as before (#15).
Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-21T18:19:33Z.
Codex Review Summary: ✅ Completed
This comment shows the latest Codex review activity on this pull request.
ea14ed4ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.