Repository navigation
Track counter-report hazards by byte range - #2121
thehobbit85 wants to merge 1 commit into
Conversation
Keep report records live through their submission fence without refusing unrelated uniform bytes on the same page. Retain conservative page tracking when capacity is exhausted and for actual GPU writes. Refs: seedds#1660 Co-authored-by: Zatteo <64840342+zatteogit@users.noreply.github.com>
|
Closing as superseded by current main ( Commit 4c574a6 already tracks completion-written counter records by their own 16 bytes and submission fences, with conservative page fallback when the live ring cannot accept a submission. Both uniform-shadow and CPU-source-read hazard checks use the exact records; actual GPU writes still retain page hazards. It also covers samples-passed reports. This provides the PR’s intended fix for issue #1660 without adding a second report ledger. Fresh native t_ubp_running validation passed all 25 checks on a9005a5; those native sources are identical at the main revision cited here. This is synthetic regression evidence, not a new gameplay or performance claim. The PR branch is preserved. |
What and why
Addresses the false uniform-shadow refusals described in issue #1660. Ori and the Will of the Wisps puts two 16-byte counter reports on a page shared with unrelated uniform blocks. Treating each unfinished report as an unknown write to the entire 4 KB page needlessly refuses those partial shadows and ends render passes.
Track the exact report ranges and their submission fences. Both GPU-write ledgers consult them, including CPU copy-source reads of the timestamp bytes. Overlapping bytes remain unavailable until the report writes have landed and the completion fence advances. Actual GPU writes keep page hazards. Per-submission overflow and a full live ring retain the previous conservative behavior; no unfinished record is overwritten.
The issue's copied-program identity bug is already fixed on main by #1521. This PR addresses its remaining counter-report tracking defect; it does not claim the game's reported frame-rate improvement or close the whole gameplay report. Credit to Zatteo for the diagnosis and exact-range approach.
Checked
Apple M2 Max, macOS 26.6 (25G5028f), Xcode 27.2 (27B52), Python 3.14.6; native arm64 builds. No game files, keys or extracted data.
t_ubp_running: both report records, timestamp-source reads, touching boundaries, cross-page reports, independent fences, mixed real writes, submission overflow, full ring fallback and reuse only after retirement.make -C dm/gfx/tests -j2 GAME=010015100B514000 run: full native graphics suite PASS (641.6 seconds).make -C dm/host -j2 GAME=010015100B514000 dmhost: PASS.lint_c.py tidy --against 6c676444c6991967cad8164d09ea041f6c8efbaa -j2 dm/gfx/nvn/nvn_mtl.m dm/gfx/tests/t_ubp_running.m: PASS, zero file/check pairs above the existing baseline.nvn_mtl.m,'?'count 2→3), reproduced independently on pristine base; existing test_dmsh_abi's ratchet no longer counts "?": the unknown binding kind is also what log lines write for a name they do not have, and the third such placeholder in nvn_mtl.m fails the Tool tests on main (issue #1656) #1981 addresses it. Documentation tests pass.IntegerPassThrougherrors. Python lint: the same three inheriteddmsh_build.py:166–167type findings. Both groups reproduce on pristine base; existing Fix shader-tool lint and stale shader test fixtures #2111 addresses them.git diff --check: PASS. No shader-chain tool or version changes.regress.py check --games 01008DD013200000,0100A6301214E000,01007EF00011E000,0400380020056000,0400486024DEC000: exit 2, becauseREGRESS_ROOT,REGRESS_GAMESand game files are unavailable. Ori is the reported layout (no profile yet), Engage exercises reports sharing uniform memory, Breath of the Wild exercises partial uniform shadows, Splatoon Raiders exercises report-heavy submissions, and Ocarina of Time exercises timestamp reads. None was run; there is no gameplay, visual or frame-rate validation claim.Fresh main
6c676444and all 1,472 open/draft/closed/merged PR descriptions plus the issue timeline were checked again before publication. Existing counter-clock/frequency and write-ledger PRs address different defects; no existing solution to report-page widening was found.Docs
docs/reference/rendering.md, current behavior indocs/development.md, symptom index regenerated.