Skip to content

feat(agc): model the color memory of PS4 multisampled 2D surfaces - #25802

Merged
oneandonlydean merged 2 commits into
boykopovar:mainfrom
adam25136:feat/gcn-msaa-color-fill
Nov 27, 2026
Merged

oneandonlydean merged 2 commits into
boykopovar:mainfrom
adam25136:feat/gcn-msaa-color-fill

Conversation

@adam25136

Copy link
Copy Markdown
Contributor

What

AnyPS5 gives no PS4 tile mode a multisampled color footprint: MultisampledColorBytes (MultisampleTarget.cpp) returns 0 for every PS4 target, and the paths that need the range a multisampled target's color memory covers refuse it:

  • the first draw into a PS4 multisampled color target with no CMASK throws initial multisample color footprint is not implemented (PrepareMultisampleTargetForDraw_nid_no_patch);
  • a fill that covers such a target's base is refused at the target's next use (... of a multisampled target whose footprint is not modeled), and one that starts inside it is ignored;
  • createFilled, which builds the host target of a multisampled texture no draw rendered to from its T# and its guest memory, takes only PS5 tile modes. With feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672, which lays out PS4 multisampled color textures in the 2D tile modes, a PS4 one throws ... which no draw rendered to and whose tile mode 18 has no modeled multisampled color footprint, is not implemented (18 is AnyPS5's kGcnThin2D, GCN tile index 14); without it, DescribeSurface throws first (PS4 multisampled textures outside the depth tile modes are not implemented).

This PR, for the PS4 thin and display 2D modes:

  • MultisampledColorBytes returns the padded one-sample size times the stored fragments (bytes times its fragments): the slice size addrlib gives a macro-tiled surface, padded pitch times padded height times bytes per element times samples (egbaddrlib.cpp L619-L620, ComputeSurfaceInfoMacroTiled), with fragments in place of samples for EQAA (L95-L98), and the range guardedColorBytes already guards. So the first draw into a PS4 multisampled target with no CMASK starts from the value its color memory repeats (other contents throw nonuniform initial multisample color tiling is not implemented); a fill over the whole of it clears it, and an exact uniform one is absorbed by the host target instead of being stored to guest memory, as for a PS5 target; a fill over part of it, from its base or from inside it, is refused at its next use (partly covers). PS4 1D and linear targets keep no footprint: feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672 lays out PS4 multisampled color only in the 2D modes, and addrlib's linear path notes "No linear MSAA on real H/W" (egbaddrlib.cpp L211, Mesa 25.0.7's addrlib).
  • createFilled takes those two modes and sizes the surface with DescribeSurface, that is with feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672's layout. Samples interleave inside each micro tile there, so samples times one padded sample is the size, not the layout. As for a PS5 texture, memory that repeats one 32-bit value gives every sample that value. Other PS4 contents are refused in createFilled itself, with the range: whose PS4 color memory 0x...+0x... does not repeat one 32-bit value.
  • A PS4 target over a texture's host target it does not match (size, format or samples) is refused when a draw, a CB clear pass, a resolve or a sample-order read would create it (requireNoTextureHost, called from acquire and from PrepareMultisampleTargetForDraw_nid_no_patch): the WxH PS4 multisampled color target 0x... over the WxH host target a texture built at 0x..., which it does not match in size, format or samples, is not implemented. A PS4 T# gives the texture's size and a PS4 CB its padded pitch and height, which differ whenever the texture is padded (inFAMOUS's texture is 1600x1800 in a surface padded to 1664x1856): without this, a fast-cleared draw would make a second host target over the same memory, and a later read through the T# would get the texture's old samples. A target that matches still reuses the texture's host target.
  • Not changed: non-uniform PS4 contents; PS4 1D, linear and PRT multisampled color; and T# word 6, which AnyPS5 reads for no PS4 texture: its PS4 Pro alt_tile_mode and compression_en bits (shadPS4 resource.h), so an alternate-tiled or compressed surface is sized and checked over the base layout's footprint (feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672's alternate tiling entry).
  • Technical debt: a fragment adds PS4 multisampled color memory (the range and what uses it, the absorbed fills, that an undrawn PS4 surface holding its samples in its memory is inferred, word 6, the refused target) and changes Multisampled texture no draw rendered to (PS4 thin and display 2D textures, non-uniform PS4 memory throws).

It depends on #23672, whose DescribeSurface layout createFilled uses; this branch carries #23672's commit, so its diff includes that change until #23672 is merged.

Tested

Windows 10 Pro 22H2 (19045), NVIDIA GeForce RTX 5080 (driver 621.14), WinLibs GCC 15.2.0 (r7), Release. The selected tests and the validation-layer runs ran on this change on main 35067f305f; the breaks and the inFAMOUS starts on it before a rebase, on 9facbf1309; it is now on 11f95ea8f6. None of the main commits in between change a file this PR changes, and its changed lines are the same.

  • agc_driver_gcn_multisample_color_fill (new): it calls the driver functions ShaderResources.cpp calls for a multisampled T#, MultisampleTargetFirstSample (a 2D image binding) and, once, MultisampleTargetTexture (a multisampled view), and reads every sample back. It does not dispatch a PS4 compute shader: on main the recompiler offers a PS4 image load no 2D MSAA mode (our feat(shader): offer a 2D MSAA mode to GCN image loads #21961 adds one). The texture cases are PS4 T#s of 2-sample 32-bit float textures, thin 2D unless named:
    • 128x64, one macro tile: zeroed memory holds 0 in every sample and memory that repeats 1.5 over the footprint holds 1.5; a second value in the second word or in the last word of the footprint is refused, one just past it is not; a display 2D texture whose memory repeats 1.5 holds 1.5;
    • 100x60 of pitch 512, padded past its 60 rows: memory that repeats 1.5 over the padded footprint holds 1.5, a second value in its last word is refused and one just past it is not; a fill of 1.5 over exactly that footprint is absorbed by the host target and one over half of it is not;
    • first draws into a 128x64 2-sample thin 2D CB target (PrepareMultisampleTargetForDraw_nid_no_patch): over zeroed memory and over memory that repeats 1.5 every sample starts from that value, and a second value halfway through its color memory is refused;
    • after a 128x64 texture of the same memory was read, the draw reuses its host target; after a 120x60 texture of pitch 128 was read, a draw into the 128x64 target is refused, with FAST_CLEAR and without, and so is materializing its fast clear with no draw (MaterializeMultisampleTargetClear).
  • agc_gcn_color_target (new MultisampledFootprintsAndFills): a 1D-tiled 4x target has no footprint; the color memory of thin 2D 2x and 4x, display 2D 2x and thin 2D 4-sample 2-fragment targets is 2, 4, 2 and 2 times the size CB_COLOR_SLICE gives; a fill of all of a 4x target is taken as a clear, and fills of its first quarter or from inside it are refused (partly covers).
  • Both pass, and each of 11 deliberate breaks fails at least one of them: the thin or the display 2D mode not mapped, the footprint not computed (as on main), the per-sample size taken as the whole surface, halved, or from ColorTargetLayout of the T# size, the footprint one sample instead of one per fragment, the non-uniform PS4 refusal removed, the refusal over a texture's host target removed from the draw preparation or from acquire, and the footprint given to every PS4 tile mode. With main's MultisampledColorBytes, the first-draw case throws initial multisample color footprint is not implemented.
  • The 3,418 tests tools/select_tests.py selects for the 8 changed files (ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1), on this branch and on main 35067f305f (3,417, without the new test): agc_driver_bda_device fails on both; agc_driver_frame_replay_rewind_store and pad_timeline failed only on the branch, and in 10 reruns each passed 9 times on the branch and 9 and 8 times on main; the same 24 tests are skipped on both.
  • With VK_LAYER_KHRONOS_validation 1.4.367 (VK_ADD_LAYER_PATH=<the layer's folder> VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_LOADER_DEBUG=layer VK_LOADER_LAYERS_DISABLE=~implicit~ ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1), the tests matching gcn|Gcn|multisample|msaa|color_target|agc_driver_graphics$|agc_driver_recorder$|alpha_to_coverage, ctest -V: 84 on the branch and 83 on main, all pass; the logs have 82 and 81 Insert instance layer lines (tests that open no Vulkan instance, such as agc_gcn_color_target, have none), no was not found and no VUID.
  • inFAMOUS Second Son (CUSA00223 01.07, my own dump; it runs in PS4 Pro mode): eboot, libc.prx and libSceFios2.prx unwrapped with our local PS4 variant of tools/unwrap_self.py, converted with each build's relinker (--windows --registry --trace-imports), two starts of up to 60 s per build, no input. Both builds are main 9facbf1309 with fix(libSceSysmodule): accept four PS4-only module ids in a PS4 process #18184, feat(shader): offer a 2D MSAA mode to GCN image loads #21961, feat(agc): sample and publish PS4 multisampled depth targets #25557, fix(shader): read the tenth opcode bit of PS4 VOP3 instructions #25598 and feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672 merged locally (feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672 and feat(agc): sample and publish PS4 multisampled depth targets #25557 conflict in TextureTiling.cpp; resolved by keeping feat(agc): sample and publish PS4 multisampled depth targets #25557's depth tile split and feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672's color tile split) and one local relinker change in no PR: a title that needs libSceGnmDriver.prx also loads libSceGnmDriverForNeoMode.prx, so the Neo-mode GNM exports it imports resolve (see libSceGnmDriver: inFAMOUS Second Son (CUSA00223) stops at load on 47 imports that only libSceGnmDriverForNeoMode exports #17581).
    • without this change: both starts stop after 21.9 s and 21.5 s, after presenting a frame, in compute shader 0x2f2fb2100 with sampling the 1600x1800 multisampled texture 0x3075c0000 of 2 samples, which no draw rendered to and whose tile mode 18 has no modeled multisampled color footprint, is not implemented;
    • with it: both get past that shader and instead stop after 21.6 s and 21.5 s at a draw with a one-sample depth target under a multisampled rasterizer without MSAA_ENABLE is unsupported for points or lines and with alpha-to-coverage, ..., which is outside this PR. The time to the stop is about the same; what changes is where they stop.
    • Builds of the same stack with local debug prints (on main 7eb79b0c48, and for the T# on 9facbf1309) showed that no draw binds a multisampled PS4 color target before that stop, that the texture's 23.6 MiB footprint (pitch 1664, height padded to 1856, 4 bytes, 2 samples) and the 8 MiB after it hold only zeros, so the zeros reach 2,486 rows at that pitch, past any padding of 1,800 rows, and that its T# is 03075c00 10400000 71c1c63f e4e10204 00cfe000 00000000 01000000 00000000: 1600x1800 of pitch 1664, 2 samples, tile index 14, a 32-bit format, and word 6 0x01000000, so alt_tile_mode is set and compression_en is clear. The texture is alternate-tiled, like the color targets feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672's entry records for this title, and not compressed, so its zeros are its samples whichever of the two footprints applies.
  • python tools/check_conventions.py --base origin/main with this title and description: all checks passed.
  • python tools/pr_overlap.py --branch feat/gcn-msaa-color-fill (2,372 open pull requests probed): 2 that merge with main conflict with this branch on nearby lines: feat(agc): draw PS4 color targets in the PRT tile modes #22514 (PS4 color targets in the PRT tile modes) in tests/GcnColorTarget.cpp, next to the new test function, and my feat(agc): sample and publish PS4 multisampled depth targets #25557 in TextureTiling.cpp, the conflict it has with feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672; feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672 itself, whose commit this branch carries, is listed for the new debt fragment both add. Of the 13 that conflict with main and were not compared, 2 change lines inside this branch's hunks: feat(agc): reuse a native multisample colour target and honour guest HTILE clears #6808 (it adds the PS5 Z_X and D_X cases to createFilled, which main already has) and feat(libSceAgcDriver): support PS4 2D thick tile mode 20 for volumes #20786 (PS4 2D thick volumes, in feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672's TextureTiling.cpp hunk). None of them sizes PS4 multisampled color.

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 and the licence notice of code adapted from upstream (see AGENTS.md)
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • 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: feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672
  • Fixes: none
  • Unblocks: CUSA00223 inFAMOUS Second Son (CUSA00223) #8214
  • GPUs tested: NVIDIA GeForce RTX 5080, driver 621.14, Windows 10 22H2
  • AI-assisted: yes

AI-assisted: Claude Code found the cause, wrote the change and its tests, ran the tests and the inFAMOUS starts, and drafted this description; separate review agents checked it.

🤖 Generated with Claude Code

adam25136 and others added 2 commits November 22, 2026 19:58
A 2D multisampled T# in a 2D color tile mode (display or thin) follows
addrlib's color sample order: the 64 elements of each sample are stored
together in the micro tile, after the pixel bits. A color mode's tile
split is the sample split times the single-sample micro tile, with
shadPS4's sample split of 2. PRT, linear and 1D color modes still throw.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
MultisampledColorBytes gave no PS4 tile mode a multisampled color
footprint, so the first draw into a PS4 multisampled color target with
no CMASK threw ("initial multisample color footprint is not
implemented") and a fill over one was refused at its next use. And
createFilled, which builds the host target of a multisampled texture no
draw rendered to from its guest memory, took only PS5 tile modes. With
boykopovar#23672's PS4 multisampled color layout, inFAMOUS Second Son (CUSA00223)
stops there on a 1600x1800 2-sample texture whose memory is all zero.

For the PS4 thin and display 2D modes, MultisampledColorBytes now
returns the padded one-sample size times the stored fragments, the
slice size addrlib gives a macro-tiled surface
(ComputeSurfaceInfoMacroTiled; with EQAA it counts fragments), and
createFilled takes those modes, sized by the PS4 multisampled layout
(DescribeSurface). Memory that repeats one 32-bit value gives every
sample that value; createFilled refuses other PS4 contents itself.

A PS4 T# gives a texture's size and a PS4 CB its padded size. Over
memory a padded texture was built from, a fast-cleared draw, a CB clear
pass, a resolve or a sample-order read would not reuse that host target
and would make a second one, and a later read through the T# would get
the old samples. A PS4 target over a texture's host target it does not
match (size, format or samples) is therefore refused. PS4 1D and linear
targets keep no footprint.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed — looks good

The inspected changes consistently model PS4 2D multisampled color footprints and reject the unsupported cases; the reported checks are author-reported and were not run in this review.

What I ran

Reviewed head 2e00b7e399b088b3f98140fb7272f3c1459880db; no commands or tests were run. Read all seven changed files listed as included in manifest.json: MultisampleTarget.cpp, TextureTiling.cpp, GcnColorTarget.cpp, tests/TextureTiling.cpp, GcnMultisampleColorFill.cpp, and the three docs/dev/debt/changes/*.md files. No changed files were excluded.

Results

Check Result Note
Source review passed All included changed files read
Automated checks not run Description reports author-run results
Console behavior not run PS4 hardware behavior remains unconfirmed

Findings

Blocking

None.

Non-blocking

None.

Not verified

The reported test runs and inFAMOUS starts were not independently verified. No PS4/PS4 Pro measurement was performed; the documentation identifies the undrawn-surface sample interpretation and PS4 color layout as unverified on console. files.json was not available as a review document, but the review folder listing and manifest enumerate seven changed files, all included.

To get this to a good state

Nothing is required.

@github-actions github-actions Bot added unblocks title Names a title ID on the Unblocks line docs agc libSceAgc* labels Nov 22, 2026
@JJenkx

JJenkx commented Nov 22, 2026

Copy link
Copy Markdown
Contributor

Windows AMD run of head 2e00b7e399, merged onto main 07336cc200 (83285e3ea8, clean merge).

Setup: Windows 11 Enterprise 22621, WinLibs GCC 15.2 UCRT, Release, AMD Radeon RX 6700 XT, driver 32.0.21045.29003. ANYPS5_REQUIRE_VULKAN=1 (no fallback to a software device), ANYPS5_NO_SHADER_CACHE=1.

  • agc_driver_gcn_multisample_color_fill, agc_gcn_color_target: all 2 pass in each of 3 runs (6 of 6), none skipped.

AI-assisted: yes.

@Helldiverr

Copy link
Copy Markdown
Contributor

Head 2e00b7e399 merged onto upstream/main 90b6de9c18: looks correct to me. The focused tests pass 3/3 on gfx1201 with the Khronos validation layer loaded, and they log no VUID-. All three tests this PR touches fail on main.

Code. I found no problem.

  • MultisampledColorBytes (Graphics/src/MultisampleTarget.cpp) gives kGcnThin2D and kGcnDisplay2D the padded one-sample size times the stored fragments. PS4 1D, linear and PRT modes keep no footprint and still throw where they did.
  • createFilled sizes a PS4 surface from DescribeSurface().guestBytes / samples. It refuses memory that does not repeat one 32-bit value, with the range in the message.
  • requireNoTextureHost runs both in acquire and in PrepareMultisampleTargetForDraw_nid_no_patch. So a PS4 target over a texture host target it does not match is refused on each creating path, not only on a draw.
  • In TextureTiling.cpp the tile split for colour, min(1024, max(256, 2 * 64 * bpe)), is the same as before for one sample, and the depth modes keep their own.
  • Repo rules: no code comments, no made-up success and no title-specific values. The debt changes go through fragments (feat-gcn-msaa-color-fill.md, feat-gcn-msaa-color-layout.md, fix-gcn-msaa-depth-layout.md).
  • The diff still carries feat(agc): lay out PS4 multisampled color textures in 2D tile modes #23672's commit, as the body says.

Negative control. On main the five existing tests pass. I copied the PR's tests/GcnColorTarget.cpp, tests/TextureTiling.cpp and tests/execution/GcnMultisampleColorFill.cpp onto main. All of them build, and all three affected tests fail:

  • agc_driver_gcn_multisample_color_fill fails in 1.10 s: PS4 multisampled textures outside the depth tile modes are not implemented.
  • agc_driver_graphics fails in 8.97 s: PS4 multisampled tiling is only modeled for 2, 4 or 8 samples in a depth tile mode.
  • agc_gcn_color_target fails in 0.03 s. It reports that thin 2D 2x/4x, display 2D 2x and 4-sample 2-fragment targets are not the expected multiple of CB_COLOR_SLICE, then ... covers the color memory ... of a multisampled target whose footprint is not modeled.

GPU.

ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_LOADER_DEBUG=layer ctest --test-dir build -R "^(agc_driver_gcn_multisample_color_fill|agc_gcn_color_target|agc_driver_graphics|agc_driver_multisample_fill_host_only|agc_driver_sample_multisample_target|agc_driver_cached_image_multisample_guard)$" -V
run gcn_multisample_color_fill agc_gcn_color_target graphics multisample_fill_host_only sample_multisample_target cached_image_multisample_guard
main not on main Passed 0.03 s Passed 11.50 s Passed 1.21 s Passed 2.27 s Passed 1.04 s
main + PR tests Failed 1.10 s Failed 0.03 s Failed 8.97 s
head 1 Passed 0.37 s Passed 0.03 s Passed 13.33 s Passed 0.54 s Passed 1.45 s Passed 0.30 s
head 2 Passed 0.36 s Passed 0.03 s Passed 12.27 s Passed 0.46 s Passed 1.23 s Passed 0.30 s
head 3 Passed 0.28 s Passed 0.03 s Passed 11.99 s Passed 0.47 s Passed 1.20 s Passed 0.27 s

The main times include the first start after the build. No test skipped. In particular, gcn_multisample_color_fill found a guest block below the 40-bit range and ran every case. Every log shows the AMD Radeon AI PRO R9700 as the device.

Validation.

  • Insert instance layer "VK_LAYER_KHRONOS_validation" count: 4 on main, 1 on the negative control and 5 on each head run. agc_gcn_color_target opens no Vulkan instance.
  • was not found but was requested by env var VK_INSTANCE_LAYERS appears in none of them.
  • VUID- lines: 0 on main, 0 on the negative control and 0 on each head run.

Host:

  • GPU: AMD Radeon AI PRO R9700 (gfx1201, 1002:7551), driver 32.0.31044.16, Vulkan 1.4.349
  • Validation layer: Khronos 1.4.363 (LunarG SDK)
  • CPU: Ryzen 9 9950X3D
  • OS: Windows 11 Pro 26300
  • Toolchain: WinLibs GCC 15.2, Release
  • Commits measured: main 90b6de9c18; head 93a2368547 (2e00b7e399 merged onto 90b6de9c18)

AI-assisted: yes

@github-actions

github-actions Bot commented Nov 23, 2026 •

Copy link
Copy Markdown

Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.

Pull request Conflicting files (lines on main) Same exports Same new files
PR 22514 core/libs/prx/libSceAgcDriver/tests/GcnColorTarget.cpp L231, L255
PR 25684 core/libs/prx/libSceAgcDriver/tests/GcnColorTarget.cpp L231, L255

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 6280 core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
PR 6808 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 7642 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 9318 core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
core/libs/prx/libSceAgcDriver/tests/TextureTiling.cpp
PR 9508 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 10193 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 13863 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 13920 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 13928 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 13929 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 19557 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 20786 core/libs/prx/libSceAgcDriver/Graphics/src/TextureTiling.cpp
core/libs/prx/libSceAgcDriver/tests/TextureTiling.cpp
PR 21155 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 23252 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp
PR 24049 core/libs/prx/libSceAgcDriver/Graphics/src/MultisampleTarget.cpp

@nexus1692

Copy link
Copy Markdown
Contributor

Independent NVIDIA Blackwell validation of agc_driver_gcn_multisample_color_fill

The PR's Tested block is filled in and covers Windows 10 22H2 with an NVIDIA GeForce RTX 5080 (driver 621.14). This run is Windows 11 on a desktop Blackwell part one tier below, with the implementation-revert control the body does not include for this test.

Hardware and toolchain

OS Windows 11 (x86-64)
Compiler WinLibs GCC 16.2.0 (MinGW-w64 x86_64-ucrt-posix-seh, built by Brecht Sanders, r3)
CMake / Ninja 4.4.4 / 1.13.2, CMAKE_BUILD_TYPE=Release, BUILD_TESTING=ON
GPU NVIDIA GeForce RTX 5070 Ti 16 GB, vendor=0x10de device=0x2c05, driver 621.24
Validation layer VK_LAYER_KHRONOS_validation 1.4.363 (Vulkan SDK 1.4.363)
Environment ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, APS5_NO_PIPELINE_JOURNAL=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation, VK_LOADER_DEBUG=layer
Head 2e00b7e399
Base for the control 11f95ea8f6 (the merge base, the same one the PR body names)

Build

cmake -S . -B build      # exit 0, the new tests/execution/GcnMultisampleColorFill.cpp is picked up by the glob
ninja -C build agc_driver_gcn_multisample_color_fill_tests

Exit 0, with the usual MinGW .rsrc merge failure: multiple non-default manifests link warning.

Results

ctest --test-dir build -R '^agc_driver_gcn_multisample_color_fill$' -V, 3 consecutive runs:

Run Result Device Instance layer Device layer VUID-
1 Passed, 1.18 s device=0x2c05 1 1 0
2 Passed, 0.42 s device=0x2c05 1 1 0
3 Passed, 0.43 s device=0x2c05 1 1 0
implementation reverted Failed (exit 1) device=0x2c05 1 1 0

No was not found but was requested by env var VK_INSTANCE_LAYERS line, no skip: the suite prints its verdict and the multisample grid it measured on this device:

[gpu] largest sample location grids (vkGetPhysicalDeviceMultisamplePropertiesEXT): 1 samples 4x4, 2 samples 2x4, 4 samples 2x2, 8 samples 1x2; maxSampleLocationGridSize for every count 1x1
PS4 multisampled color fill tests passed: 2-sample 32-bit float 2D-tiled textures no draw rendered to (128x64, and 100x60 of pitch 512 whose 262144-byte footprint is padded) hold, in every sample, the value their footprint repeats, and a second value inside it is refused; a 2-sample PS4 target's first draw starts from the value its color memory repeats, reuses a texture's host target of its size and is refused over one of another size

Negative control (implementation reverted, test kept)

Keep the PR's test and revert only Graphics/src/MultisampleTarget.cpp and Graphics/src/TextureTiling.cpp to 11f95ea8f6. Rebuild is clean and the suite fails with the base behaviour:

1/1 Test #1857: agc_driver_gcn_multisample_color_fill ... ***Failed
AGC graphics: PS4 multisampled textures outside the depth tile modes are not implemented

So the new expectations are bound to the colour-memory model this PR adds, and not to pre-existing tile-mode support.

What this does and does not establish

Establishes, on native Windows 11 with GCC 16.2.0/UCRT in Release on an RTX 5070 Ti:

  • agc_driver_gcn_multisample_color_fill builds and passes on Windows 11 / desktop Blackwell with driver 621.24, 3/3 runs, validation layer inserted at instance and device, zero VUID- lines;
  • the suite creates a real device and runs the fill/footprint/host-target-reuse expectations there (it prints this GPU's actual sample-location grids), rather than returning 77;
  • reverting only the two implementation files makes it fail with the base "not implemented" message.

Does not establish:

  • console behaviour: the repeat-value fill model is the PR's reading of PS4 colour memory, not a PS5 capture;
  • the title runs (inFAMOUS starts, the breaks) mentioned in the PR body are not reproduced here: no title content on this machine;
  • other tile modes or formats: the suite covers 2-sample 32-bit float 2D-tiled, and the base message for everything outside the depth tile modes is what the control hits;
  • no AMD/Intel GPU, no Windows 10 comparison: the PR's own Windows 10 / RTX 5080 result and this Windows 11 / 5070 Ti result agree, but both are NVIDIA.

Workspace cleaned up afterwards: temporary branch deleted, main left at origin/main, no local changes.

@upipibi

upipibi commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

NVIDIA Ampere run of the Tested selection: no regression.

Setup: NVIDIA GeForce RTX 3070, driver 616.56, Windows 11 Pro 10.0.26100, WinLibs GCC 15.2.0 r7, Release, Vulkan validation layer 1.4.363. Base main 61f7f5925c; head 2e00b7e399 merged onto it with --no-ff. Env: ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_LOADER_DEBUG=layer, ctest -R '^(agc_driver_bda_device|agc_driver_frame_replay_rewind_store|agc_driver_gcn_multisample_color_fill.*|agc_gcn_color_target.*)$' -V, 3 runs each.

  • main: 3 of 3 passed in 3 of 3 runs.
  • this PR: 4 of 4 passed in 3 of 3 runs (the extra one is the new test).
  • 0 VUID- messages on either side; the loader inserted the validation layer in every run.

AI-assisted (Claude Code).

@github-actions github-actions Bot added the review queue Next in the maintainer review queue: checks pass, no open change request, no conflict label Nov 24, 2026
@oneandonlydean
oneandonlydean merged commit efe1deb into boykopovar:main Nov 27, 2026
14 checks passed
@github-actions github-actions Bot removed the review queue Next in the maintainer review queue: checks pass, no open change request, no conflict label Nov 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc* docs unblocks title Names a title ID on the Unblocks line

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants