Skip to content

fix(agc): complete sampled MSAA geometry after fragment sizing - #6445

Merged
oneandonlydean merged 9 commits into
boykopovar:mainfrom
Amoenus:codex/fix-msaa-surface-footprint-mainff
Oct 18, 2026
Merged

oneandonlydean merged 9 commits into
boykopovar:mainfrom
Amoenus:codex/fix-msaa-surface-footprint-mainff

Conversation

@Amoenus

@Amoenus Amoenus commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

What

This is now a dependent follow-up to #6444 by @MarcZX100, rather than a competing range implementation. It includes their exact original commit 68311f58245b40826ad9dc0ec565669873a0b435, preserving Git authorship, range arithmetic and the original PPSA99006 regression assertion. #6444 should land first.

Our production follow-up adds the fragment-aware linear size and single-mip metadata, checks unsupported inputs before using the block calculation, and retains the existing geometry path for linear descriptors. That last correction addresses @screamm's regression report. The production delta against the parent is 11 added lines and one removed line; it leaves the parent's range formula intact.

The public Sonic Unleashed Recompiled descriptor (PPSA99902, #3036 / discussion #4443) and PPSA99006 canvas remain regression inputs. This completes the CPU geometry contract; it does not implement a linear MSAA guest layout, sample upload/readback, or establish a title-startup improvement. Console equivalence and unobserved title effects are recorded in technical debt.

#6280 also changes this helper. Its exact head c80ba9e310a8a828195e273f0ca732ac6278174c has a clean complete-head merge preview with this submission. Its default single image level preserves this MSAA early return. That is a source/merge check, not combined runtime validation; there is no functional dependency.

Coordination and historical comparisons. The previous independent #6445 head is preserved on the fork at codex/archive-msaa-footprint-before-stack-91a7.

Tested

Maintainer refresh verified (2026-10-18): Dean's bb2ab91841ec453304f1bf54b74f26241f511a8f brings in main6efb7261b5. I preserved that update. Its core/ and CMake trees match the separately prepared main5bf composition; their differences are deployment workflows/progress and debt placement. Fresh builds/checks below use Dean's exact bb2 head, not just that equivalence.

Full Windows/Linux relinker/library builds pass. agc_multisample_guest_access passes3 runs on each verified RTX5080, Radeon Graphics and lavapipe; graphics CPU checks pass3 times on each OS (15 selected executions:6 physical GPU,3 lavapipe,6 CPU). Each test is below30s; no selected skips/errors. Windows Khronos1.4.363 loaded, no logged VUIDs/validation errors/warnings. Windows11 26200, NVIDIA driver32.0.16.1062, AMD32.0.21036.18. Ubuntu24.04 GCC13.3, lavapipe Mesa25.2.8/LLVM20.1.2; no Linux validation-layer claim. No new title or speed claim. Existing dependency/attribution to #6444 is retained.

Current main update requested by review

Published head cace5dcb617bf04fc57198303b9c358fb69b4f98, updated onto main c0a7468f6f666a46b1c3e2fb14bb651fed05afc5. The original #6444 commit 68311f58245b40826ad9dc0ec565669873a0b435 and previous published #6445 head 3a9240a50 remain ancestors. This uses a main merge to preserve the exact credited dependency history. The only conflict was adjacent technical-debt entries; both entries were retained. No production conflict resolution or change to the parent range formula was needed.

  • Full Release relinker + libs, graphics and recorder targets build on Windows GCC15.2 and Ubuntu24.04 WSL.
  • agc_driver_graphics and agc_multisample_guest_access each pass3/3 on NVIDIA RTX5080, AMD Radeon Graphics and Linux/llvmpipe: 18 passing fresh processes, no whole-test skips. Selected device names are verified in recorder output. Maximum individual check: 4.08s. The graphics group is CPU/mock coverage; driver caches are uncontrolled.
  • Cppcheck2.20 then clang-tidy23.1.3 on TextureTiling.cpp and GuestTextureResource.cpp: no selected diagnostics or parser/configuration failures,16.856s analysis. Conventions/diff checks pass.
  • Windows11 Enterprise26200, RTX5080 driver610.62 /32.0.16.1062 and AMD Radeon(TM) Graphics driver32.0.21036.18. Linux software driver: llvmpipe LLVM20.1.2 / Mesa25.2.8. Vulkan required; project shader cache and pipeline journal disabled. No new title/FPS/console or complete-suite claim.

The earlier negative controls and independent comparisons below remain historical evidence for the unchanged geometry correction.

Earlier validation

Submitted head 3a9240a50d8012644b20c83830b4dafb2f82d16b, based on main 2fab88d102fe494648a94c6d94f067facd983291 plus exact #6444. All production and test blobs are identical to validated 83aeed1f3e14b509854fefa5b546d1cd171f8254; the final commit only relocates the debt entry to avoid an adjacent insertion conflict with #5939. No runtime tests were repeated for that documentation move.

  • Negative control: main590b + exact fix(agc): size sampled MSAA surface footprints #6444 + our expanded tests (54d941941ca9428ac8fe15c98b4160f99565a51f). On Windows, agc_driver_graphics fails at the missing fragment-aware linear size; the existing agc_multisample_guest_access fails at GetBlockLayout does not apply to linear tiling. No production changes are in this control.
  • Positive: both groups pass three fresh processes each at validated 83aeed1f3, on Windows/NVIDIA and Linux/llvmpipe: 12 passing processes. Physical/software device names verified in the recorder output. Maximum individual time: 11.27 s. The graphics group is CPU/mock coverage. Linux omits its two heap-mirror checks because the arena is unavailable or not write-watched; those paths are excluded. No whole-test skips.
  • Added assertions cover 18 linear geometry cases (two formats, 2/4/8 fragments, three extents), 12 tiled footprints including asymmetric dimensions and a 32 GiB allocation, single-mip metadata, and unsupported-input refusals. The parent's original canvas assertion is unchanged. Earlier Addrlib range comparisons remain historical evidence for the unchanged parent calculation, not a new oracle run.
  • Full application (relinker) and libs, plus the two selected test targets, build at 83aeed1f3 on Windows GCC 15.2 r7 and Ubuntu 24.04 WSL GCC 13.3. This is not a run of the entire CTest suite. test(agc): align the indirect arguments block at run time #6452 remains the separate Windows default full-test-build alignment dependency; its code is excluded here.
  • Local source conventions, diff checks and test registration pass (915 registered test executables, none unregistered). Cppcheck 2.20 followed by clang-tidy 23.1.3 reports no selected diagnostics or parser/configuration errors in the two changed translation units; analysis time 12.063 s. No formatting or automatic fixes.

Windows 11 Enterprise 26200, NVIDIA GeForce RTX 5080, driver 610.62 / 32.0.16.1062. Linux: Mesa 25.2.8 llvmpipe, LLVM 20.1.2. Vulkan required, project shader cache disabled; driver caches uncontrolled. No fresh game replay, FPS measurement, console run or new AMD/Intel validation is claimed.

Independent stack validation

@screamm's cross-validation on main c9e6c45de + exact #6444 68311f582 + this PR 3a9240a50 agrees with the focused result: agc_driver_graphics and agc_multisample_guest_access each pass3/3, and both fail when only TextureTiling.cpp is restored to #6444. Windows11 Pro26220, RTX4070 driver596.21, GCC15.2. Their wider AGC suite reports486/490 pass,2 skipped and2 f16 denormal failures tracked by #7100 at that source pin. Neither PPSA99006 nor PPSA28319 changes its title frontier. These are attributed external results, not our runs or a fully passing suite.

Checklist

@github-actions

github-actions Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.

Pull request Shared files not compared
PR 2434 docs/dev/debt/libSceAgcDriver.md
PR 4448 docs/dev/debt/libSceAgcDriver.md
PR 4650 docs/dev/debt/libSceAgcDriver.md
PR 5058 docs/dev/debt/libSceAgcDriver.md
PR 5499 docs/dev/debt/libSceAgcDriver.md
PR 5925 docs/dev/debt/libSceAgcDriver.md
PR 6194 docs/dev/debt/libSceAgcDriver.md
PR 6223 docs/dev/debt/libSceAgcDriver.md
PR 6273 docs/dev/debt/libSceAgcDriver.md
PR 6280 core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
docs/dev/debt/libSceAgcDriver.md
PR 6300 docs/dev/debt/libSceAgcDriver.md
PR 6412 docs/dev/debt/libSceAgcDriver.md
PR 6472 docs/dev/debt/libSceAgcDriver.md
PR 6481 docs/dev/debt/libSceAgcDriver.md
PR 6529 docs/dev/debt/libSceAgcDriver.md
PR 6548 docs/dev/debt/libSceAgcDriver.md
PR 6549 docs/dev/debt/libSceAgcDriver.md
PR 6563 docs/dev/debt/libSceAgcDriver.md
PR 6741 docs/dev/debt/libSceAgcDriver.md
PR 6786 docs/dev/debt/libSceAgcDriver.md
PR 6808 docs/dev/debt/libSceAgcDriver.md
PR 6867 docs/dev/debt/libSceAgcDriver.md
PR 6868 docs/dev/debt/libSceAgcDriver.md
PR 6977 core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
docs/dev/debt/libSceAgcDriver.md
PR 7332 docs/dev/debt/libSceAgcDriver.md
PR 7390 docs/dev/debt/libSceAgcDriver.md
PR 7426 docs/dev/debt/libSceAgcDriver.md

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Oct 15, 2026
@Amoenus
Amoenus force-pushed the codex/fix-msaa-surface-footprint-mainff branch from 8a38d8c to f32f679 Compare October 15, 2026 19:16
@github-actions github-actions Bot removed the needs rebase Conflicts with main, rebase needed label Oct 15, 2026
@github-actions github-actions Bot added docs agc libSceAgc* labels Oct 16, 2026
@Amoenus
Amoenus force-pushed the codex/fix-msaa-surface-footprint-mainff branch from f32f679 to 91a7fcc Compare October 16, 2026 10:08
@Amoenus
Amoenus force-pushed the codex/fix-msaa-surface-footprint-mainff branch from 91a7fcc to 3a9240a Compare October 16, 2026 20:46
@Amoenus Amoenus changed the title fix(agc): size sampled MSAA surfaces by fragment blocks fix(agc): complete sampled MSAA geometry after fragment sizing Oct 16, 2026
@github-actions github-actions Bot added the fix error Closes an issue (Fixes #N) label Oct 17, 2026
@oneandonlydean oneandonlydean self-assigned this Oct 17, 2026
@screamm

screamm commented Oct 17, 2026

Copy link
Copy Markdown
Contributor

Cross-validated as a stack on #6444 (main c9e6c45de + 68311f582 + 3a9240a50, Windows 11 Pro 26220, RTX 4070 596.21, GCC 15.2): same result as yours. agc_driver_graphics and agc_multisample_guest_access pass 3 of 3, and both fail with TextureTiling.cpp at #6444's version. Full agc_driver_* suite: 486 of 490 pass, 2 skipped, and only the two #7100 f16 denormal tests fail. No title change on PPSA99006 or PPSA28319. Details in #6444.

Written with Claude Code assistance (validation by a subagent, reviewed in this session).

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Oct 17, 2026
@oneandonlydean

Copy link
Copy Markdown
Collaborator

This now conflicts with main (after #6875 and #4339 merged). Could you rebase onto current main? We'll re-run full CI on the new head.

@github-actions github-actions Bot removed the needs rebase Conflicts with main, rebase needed label Oct 17, 2026
@Amoenus

Amoenus commented Oct 17, 2026

Copy link
Copy Markdown
Contributor Author

@oneandonlydean Updated to cace5dcb61 on main c0a7468f6f. The only merge conflict was the debt-entry insertion; production merged cleanly. Exact #6444 authorship/commit and the previous published head are retained.

Full Windows/Linux relinker+library builds pass. Both focused checks pass3/3 each on RTX5080, AMD Radeon Graphics and lavapipe (18 processes); Cppcheck/clang-tidy and conventions pass. I updated the existing PR description with pins and scope. The new head is ready for your full-CI rerun. #6444 remains the declared dependency.

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Oct 18, 2026
@github-actions github-actions Bot removed the needs rebase Conflicts with main, rebase needed label Oct 18, 2026
@oneandonlydean
oneandonlydean merged commit 0ff8356 into boykopovar:main Oct 18, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc* docs fix error Closes an issue (Fixes #N)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AGC: sampled MSAA surface geometry omits fragment storage

4 participants