Skip to content

test(recompiler): cover BDA store boundary faults and written pages - #3513

Merged
adriadam10 merged 1 commit into
boykopovar:mainfrom
jweidenh:codex/test-bda-store-boundaries
Oct 11, 2026
Merged

adriadam10 merged 1 commit into
boykopovar:mainfrom
jweidenh:codex/test-bda-store-boundaries

Conversation

@jweidenh

@jweidenh jweidenh commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

What

Replaces #2447, which was closed during the earlier intake pause. GitHub rejects reopening that PR after the branch rebase, including after restoring its recorded head.

Extend agc_driver_bda_device with 16 single-invocation byte, halfword and dword store cases that exercise the production BDA emitter. They check final bytes, unchanged surrounding bytes in the fixture buffers, first-fault address/width/PC/stage/reason, exact written-page sets and unique written-chunk claim counts. Both coherent and noncoherent stores are covered.

Cases cross mapped-range, page and chunk boundaries at a high guest address, including writable-to-read-only transitions, an unmapped byte between mapped ranges, and an aligned dword whose whole-span lookup must fail without partial writes. The fixture uses the current chunk-key, page-mask and claim-list ABI and validates generated SPIR-V when SPIRV-Tools is enabled.

The new cases run on CPU Vulkan. Existing upstream read and multi-dword write cases retain their explicit CPU skip, so this does not claim those subtests executed on lavapipe. The merged #2305 span/multi-dword fixtures and written-range decoder checks are preserved. Four test files change; production code and instruction semantics are unchanged.

Rebased onto main 0f863c102207dae4b77b1a2bad16c3aedec34691, with candidate 6199661506b8ca0265fe17e86a5ef814d53930fe. Open #2837 adds adjacent read cases and #3472 changes production written-page bookkeeping; neither supplies these boundary-store tests, and this PR does not depend on either.

Tested

Private validation run 38137044665 passed on locally managed runner lab-github-actions-runner, with source pinned to 6199661506b8ca0265fe17e86a5ef814d53930fe and workflow commit fce46875d092f3e6672b012fa1e17de8e1c903ba.

  • Ubuntu 24.04, Linux x86-64, GCC 13.3, Release, SPIRV-Tools enabled, Mesa 25.2.8 lavapipe / LLVM 20.1.2.
  • The BDA test executable and its dependencies, plus patched libraries, built successfully. This was a focused build and test run, not a full-suite run.
  • agc_driver_bda_device: 1/1 passed in 4.43 s, zero CTest skips, with all 16 new store cases executing. The existing read/multi-dword CPU subtest skips are reported inside that executable.
  • Two isolated negative controls proved the assertions detect their intended regressions: reversing byte visitation failed first-fault metadata in 1.77 s; suppressing written-page notifications failed the written-page set in 0.16 s.
  • Original production source was restored exactly, recorded clean, rebuilt, and passed again in 4.24 s. Fresh cache directories were used per control, and the existing 30-second test timeout was retained.
  • Source conventions and independent source/artifact review passed.

The historical full-suite results for the old #1265/#1280 integration branches apply to their earlier base, not this rebased test-only head. No title, Windows or physical-GPU testing is claimed. Existing CPU read/multi-dword skips remain explicit.

Upstream automatic CI on base 2220effbe42c850d7f8df56dbac52e3cdea54009 currently fails during checkout, before the conventions checker or build: 3rdparty/imgui is a gitlink without a URL in .gitmodules. Upstream #3511 addresses that base-branch issue. The independent pinned lab results above passed.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • AI-assisted: yes

@adriadam10

Copy link
Copy Markdown
Collaborator

Re-triggering CI: the base checkout failed on a stray gitlink in main, removed by #3511 (a rerun keeps the old base).

@adriadam10 adriadam10 closed this Oct 11, 2026
@adriadam10 adriadam10 reopened this Oct 11, 2026
@adriadam10

Copy link
Copy Markdown
Collaborator

Re-triggering CI: the base checkout failed on a stray gitlink in main, removed by #3511 (a rerun keeps the old base).

@adriadam10 adriadam10 closed this Oct 11, 2026
@adriadam10 adriadam10 reopened this Oct 11, 2026
@adriadam10

Copy link
Copy Markdown
Collaborator

Checked on Linux (scoped build + ctest of libSceAgcDriver): agc_driver_bda_device passes and the 16 new store cases run on CPU Vulkan. Test-only change, template filled. The red checks are the 3rdparty/imgui checkout failure on main (#3511), not this PR; merging once CI is green.

@adriadam10
adriadam10 merged commit 9c75aa8 into boykopovar:main Oct 11, 2026
41 of 60 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc*

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants