Skip to content

feat(agc): truncate exports into 4_4_4_4 unorm targets with ROUND_MODE set - #23258

Open
Colewiz7 wants to merge 2 commits into
boykopovar:mainfrom
Colewiz7:fix/agc-4-4-4-4-truncation
Open

Colewiz7 wants to merge 2 commits into
boykopovar:mainfrom
Colewiz7:fix/agc-4-4-4-4-truncation

Conversation

@Colewiz7

Copy link
Copy Markdown
Contributor

What

A 4_4_4_4 UNORM color target with CB_COLOR_INFO.ROUND_MODE set is drawn with truncated exports instead of refused (truncating (ROUND_MODE) 4_4_4_4 unorm color targets are unsupported).

State.cpp gives such a target the new packing Unorm4_4_4_4Truncated. Its exports and partial-write merges pack each component as floor(clamp(v, 0, 1) * 15), with NaN to 0. That is NormStoreBits without its rounding step. Without ROUND_MODE, packing still rounds to nearest even, as before.

Measured on a 7800X3D iGPU (gfx1036) with a local Mesa 26.0.6 RADV patched for RB+ off (gfx1013 has none) and 32_ABGR exports, into VK_FORMAT_R4G4B4A4_UNORM_PACK16:

export ROUND_MODE 0 ROUND_MODE 1
262,144 components, half of them within 0.001/15 of a midpoint nearest, all truncated, all
0x3d888888 / 0x3d888889 (either side of 1/15) 1 / 1 0 / 1
0x3f7fffff (0.99999994) 15 14
NaN (any payload), -inf, -1, -0 0 0
+inf, 1.00000012, 2 15 15

The same runs on 11_11_10 float show the bit has no effect there (#23206).

Tested

Linux 7.3.4, GCC 16.2.1 Release, Mesa 26.2.6 RADV, main 67d3465feb. The branch carries #23206's commit first, since both change PackExport.

  • agc_driver_packed_unorm4444_color_target runs its goldens again on a target with ROUND_MODE set, plus a case of 0x3d888888, 0x3d888889, 0x3f088888 and 0x3f088889 (0x1188 rounded, 0x0178 truncated). agc_driver_packed_unorm4444_partial_write replays its nine merges on a truncating target. agc_graphics_profile_draw decodes the target as Unorm4_4_4_4Truncated, and its invalid-packing check now uses the value after the last one.
  • With main's State.cpp, emitter and converter, both new passes fail on both GPUs with truncating (ROUND_MODE) 4_4_4_4 unorm color targets are unsupported. With only the truncation step removed, they fail with holds 0xf804, expected 0xf703 (export) and holds 0x3f84, expected 0x3f73 (partial write).
  • The three agc_driver_packed_unorm4444_* tests, agc_driver_packed_float_color_target, agc_driver_packed_float_blend and agc_graphics_profile_draw, run with ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_LOADER_DEBUG=layer and ctest -V: 6/6 on both GPUs, layer 1.4.363.1 inserted, 0 VUID- lines.
  • ctest -R '^agc' (1936 tests): the failures match main's on each GPU.

Not tested: gfx1013, Windows, NVIDIA. PS4 (GCN) targets don't read ROUND_MODE, which the debt entry records.

Overlap: #22609 also appends ColorExportPacking values, so whichever merges second renumbers the range checks.

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: fix(agc): match the measured CB conversion of 11_11_10 float color targets #23206
  • Fixes: none
  • Unblocks: none
  • GPUs tested: AMD Radeon RX 7900 XT (RADV NAVI31) and AMD Ryzen 7 7800X3D iGPU (RADV RAPHAEL_MENDOCINO), Mesa 26.2.6, Linux 7.3.4
  • AI-assisted: yes

@Lyrnc

Lyrnc commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

Independent Windows run of PR head 24b6c250e4, including its #23206 prerequisite. Windows 11 build 26200, WinLibs GCC 15.2.0, Release. Vulkan required, shader cache disabled.

GPU Driver Focused CTest run
NVIDIA GeForce RTX 5080 610.88 6/6, each passed three consecutive runs
AMD Radeon Graphics (Ryzen 7 9800X3D iGPU) 32.0.21042.62 6/6, each passed three consecutive runs

Test selection: ^(agc_driver_packed_unorm4444_.*|agc_driver_packed_float_color_target|agc_driver_packed_float_blend|agc_graphics_profile_draw)$. The Vulkan device-selection logs confirmed the GPU for each run. This covers the focused tests without the Khronos validation layer.

AI-assisted: yes

@Colewiz7
Colewiz7 force-pushed the fix/agc-4-4-4-4-truncation branch from 24b6c25 to 4636f21 Compare November 19, 2026 01:29
@github-actions

github-actions Bot commented Nov 19, 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 1395 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 5609 core/shader/recompiler/Recompiler.hpp
PR 5925 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 6188 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/shader/recompiler/Recompiler.hpp
PR 6280 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 6412 core/shader/recompiler/Recompiler.hpp
PR 6808 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 7085 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 7256 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 7642 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 7668 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 7689 core/shader/recompiler/Recompiler.hpp
PR 8246 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 9356 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 9387 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 9508 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 9712 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 9748 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 9852 core/shader/recompiler/Recompiler.hpp
PR 9895 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 9897 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 9915 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 10193 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 10351 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 10359 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
PR 11483 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 11551 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 11825 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 12828 core/shader/recompiler/Recompiler.hpp
PR 12944 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 13928 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 13929 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 14032 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 14217 core/shader/recompiler/Recompiler.hpp
PR 14218 core/shader/recompiler/Recompiler.hpp
PR 14473 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 14871 core/shader/recompiler/Recompiler.hpp
PR 14944 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 15343 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
PR 15548 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 15570 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 16391 core/shader/recompiler/Recompiler.hpp
PR 16935 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 17022 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 17056 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
PR 17611 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 18177 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
PR 19620 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 19710 core/shader/recompiler/Recompiler.hpp
PR 19821 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 19852 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 20010 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 20030 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
PR 20111 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 20130 core/shader/recompiler/Recompiler.hpp
PR 20153 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 20248 core/shader/recompiler/Recompiler.hpp
PR 20518 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 20519 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 20728 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 21948 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 22071 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
PR 22140 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
PR 22251 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 22328 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 22424 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 22439 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 22514 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
PR 22628 core/shader/recompiler/Recompiler.hpp
PR 22647 core/shader/recompiler/Recompiler.hpp
PR 22690 core/shader/recompiler/Recompiler.hpp
PR 22692 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 22697 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 22703 core/shader/recompiler/Recompiler.hpp
PR 23242 core/shader/recompiler/Recompiler.hpp
PR 23244 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 23252 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 23553 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 23811 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 23818 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 24083 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 24294 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 24327 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 24523 core/shader/recompiler/Recompiler.hpp
PR 24704 core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 24714 core/shader/recompiler/Recompiler.hpp
PR 24781 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 25010 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 25374 core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 25422 core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 25489 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 25534 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 25557 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 25684 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
PR 25978 core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
PR 26040 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 26084 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 26100 core/shader/recompiler/Recompiler.hpp
PR 26365 core/shader/recompiler/Recompiler.hpp
PR 26630 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 26686 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 26691 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 26802 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 27670 core/shader/recompiler/Recompiler.hpp
PR 27672 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 27698 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 27744 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
PR 27811 core/shader/recompiler/Recompiler.hpp
PR 27847 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
PR 27887 core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 27966 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
PR 28059 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28077 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 28090 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28102 core/shader/recompiler/FragmentOutputSpecialization.hpp
core/shader/recompiler/Recompiler.hpp
PR 28118 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28142 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 28166 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28176 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 28186 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28197 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 28209 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28229 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28250 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28279 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
PR 28280 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
PR 28289 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
PR 28295 core/shader/recompiler/FragmentOutputSpecialization.hpp
core/shader/recompiler/Recompiler.hpp
PR 28296 core/shader/recompiler/Recompiler.hpp
PR 28311 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
PR 28350 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 28376 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
PR 28387 core/shader/recompiler/Recompiler.hpp
PR 28390 core/shader/recompiler/Recompiler.hpp
PR 28396 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28400 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 28411 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28469 core/shader/recompiler/SpirvBackend/src/SpirvMemory/SpirvFormatConvert.cpp
PR 28470 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 28487 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 28488 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 28490 core/shader/recompiler/Recompiler.hpp
PR 28520 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28564 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28586 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 28590 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 28605 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28638 core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 28668 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 28673 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 28808 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/Recompiler.hpp
PR 28865 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28925 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28934 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28936 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 28945 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
PR 28956 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29000 core/shader/recompiler/FragmentOutputSpecialization.hpp
core/shader/recompiler/Recompiler.hpp
PR 29032 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29033 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29042 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29058 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29060 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29066 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29067 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29069 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29076 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29084 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29085 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29087 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29089 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29095 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29098 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29101 core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29103 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29104 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29105 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29106 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29107 core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29110 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29113 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29115 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29116 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29117 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29118 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29119 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 29120 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 29121 core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
PR 29123 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444ColorTarget.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PackedUnorm4444PartialWrite.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/include/SpirvBackend/SpirvEmitterHelpers.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp
PR 29200 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
PR 29280 core/libs/prx/libSceAgcDriver/Graphics/src/State.cpp
core/libs/prx/libSceAgcDriver/tests/Graphics.cpp
core/shader/recompiler/ControlFlow/src/RequestSerializer.cpp
core/shader/recompiler/Recompiler.hpp
core/shader/recompiler/SpirvBackend/src/SpirvModuleEmitter.cpp
core/shader/recompiler/Translation/src/ShaderInputInfoBuilder.cpp

@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 implementation supports truncating 4_4_4_4 UNORM exports and partial writes when ROUND_MODE is set; no blocking defect was verified at head 4636f218a153a2d470ae2c5dc8fd7edbbb6b1b5d.

What I ran

No commands or tests were run. I read the prepared diff and manifest, then inspected targeted source ranges through repo_read.py at the pinned head.

Results

Check Result Note
Diff and manifest review passed Prepared review inputs read
Targeted code inspection passed Packing, state decode, merge, and serializer paths
Tests not run Execution results in the description are author-reported

Findings

Blocking

None verified in the inspected code.

Non-blocking

None.

Not verified

I read all changed files marked included: true in the manifest. core/libs/prx/libSceAgcDriver/tests/Graphics.cpp was excluded from review/files/ because it was too large for the review folder; I inspected its changed lines at the pinned head. Its full text was not read. Tests were not run; the reported GPU and ctest results were not independently verified. Graphics behavior on gfx1013, Windows, NVIDIA, and PS4 hardware was not verified.

To get this to a good state

Nothing is required.

@zarmstrong

Copy link
Copy Markdown
Contributor

Ran it on NVIDIA and Windows, which the description lists as not tested: head 4636f218a1 (with #23206's commit) merged onto main 3ead3ea870, with main itself as the baseline. NVIDIA GeForce RTX 5090, driver 621.01, Windows 11 Pro 26200, WinLibs GCC 15.2.0 r7, Ninja, Release, with ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation (1.4.363) and VK_LOADER_DEBUG=layer.

  • agc_driver_packed_unorm4444_color_target, agc_driver_packed_unorm4444_partial_write, agc_driver_packed_unorm4444_multisample_partial_write, agc_driver_packed_float_color_target, agc_driver_packed_float_blend and agc_graphics_profile_draw pass on both sides, and 3/3 on this PR with --repeat until-fail:3.
  • Red check: with only the truncation step removed (truncate ? quotient : in NormStoreBits), both new passes fail with the values in the description: ... into a linear ROUND_MODE 1 4_4_4_4 unorm target: pixel (0, 0) inside the scissor holds 0xf804, expected 0xf703 and ... CB_TARGET_MASK 0xe write ... into a tiled ROUND_MODE 1 4_4_4_4 unorm target: pixel (0, 0) inside the scissor holds 0x3f84, expected 0x3f73. Restored, all three pass again.
  • The layer was inserted in every Vulkan test, there were no was not found but was requested lines, and neither side logged VUID- or SYNC-HAZARD-.

AI-assisted: yes (Claude Code)

@domx4q

domx4q commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

Ran the six tests from the Tested section with the Khronos validation layer on Linux and an NVIDIA GPU, which the description lists as not tested.

Setup: Arch Linux (kernel 7.3.4), GCC 16.2.1, Release, NVIDIA GeForce RTX 4090 (vendor 0x10de, device 0x2684, Ada), proprietary driver 620.70.06, Vulkan 1.4.357, Khronos validation layer 1.4.363.1. Head 4636f218a1 (with #23206's commit 21dfbfff13 under it) merged onto main ded746ea12 with --no-ff, clean merge. Main baseline is a Release build of ded746ea12 on the same machine.

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_packed_unorm4444_.*|driver_packed_float_color_target|driver_packed_float_blend|graphics_profile_draw)$' -V
main ded746ea12 this PR
Result 6 of 6 passed 6 of 6 passed
Insert instance layer "VK_LAYER_KHRONOS_validation" 5 5
was not found but was requested by env var VK_INSTANCE_LAYERS 0 0
VUID- none none

All five execution tests select the 4090 (Selected GPU name=NVIDIA GeForce RTX 4090 vendor=0x10de device=0x2684 subgroup=32); agc_graphics_profile_draw creates no device, so it inserts no layer on either side. The new ROUND_MODE passes of agc_driver_packed_unorm4444_color_target (including the 0x1188/0x0178 rounding case) and agc_driver_packed_unorm4444_partial_write pass on the 4090.

Negative control: this PR's tests with State.cpp from #23206's commit (no truncating decode) fail 0 of 2:

AGC graphics: truncating (ROUND_MODE) 4_4_4_4 unorm color targets are unsupported

No new VUID- errors; all focused tests pass on Ada.

AI-assisted: yes (Claude Code)

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Nov 19, 2026
…rgets

Measured on RDNA2 (gfx1036 under RADV, COLOR_11_11_10, RB+ off, 32_ABGR
exports), the CB truncates an 11_11_10 float export toward zero whether
CB_COLOR_INFO.ROUND_MODE is set or clear, and writes 0x3f0 or 0x7e0 for
every NaN whatever its payload. ROUND_MODE 0 targets are no longer
refused, and the packed export writes those NaN fields instead of the
payload's top bits.
…E set

Measured on RDNA2 (gfx1036 under RADV, RB+ off, 32_ABGR exports), the
CB truncates an export into a 4_4_4_4 UNORM target with
CB_COLOR_INFO.ROUND_MODE set to floor(clamp(v, 0, 1) * 15), NaN to 0,
and rounds to nearest with the bit clear. Such a target now decodes
with the Unorm4_4_4_4Truncated packing, whose exports and partial-write
merges pack without the rounding step, instead of being refused.
@Colewiz7
Colewiz7 force-pushed the fix/agc-4-4-4-4-truncation branch from 4636f21 to ba9b824 Compare November 20, 2026 02:15
@Colewiz7

Copy link
Copy Markdown
Contributor Author

Rebased onto main d50640e264 after #23225 merged. The one conflict was in PackedFloatColorTarget.cpp: DecodeTarget now takes both the ROUND_MODE flag from this stack and #23225's sample count, and the test runs both ResolveTests and the ROUND_MODE 0 pass.

At the new heads, on the RX 7900 XT and the 7800X3D iGPU:

  • agc_driver_packed_float_color_target, agc_driver_packed_unorm4444_color_target, agc_driver_packed_unorm_color_target and agc_graphics_profile_draw, plus the resolve tests, pass with the Khronos validation layer, 0 VUID- lines.
  • ctest -R '^agc' (1965 tests): the only failure is agc_driver_image_table_packed_guards, which fails on main too.

AI-assisted: yes

@github-actions github-actions Bot removed the needs rebase Conflicts with main, rebase needed label Nov 20, 2026

@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 changed packing path and its serialization and merge handling look consistent in the inspected code; hardware test results are author-reported and were not run in this review.

What I ran

Reviewed head ba9b82437dff18c5720b2e624d3e970858a142b1 using the prepared diff and repo_read.py at the pinned head. No commands or tests were run.

Read: description.md, commits.md, manifest.json, diff.patch; changed repository files State.cpp, Graphics.cpp (lines 12500–12600), PackedFloatColorTarget.cpp, PackedUnorm4444ColorTarget.cpp, PackedUnorm4444PartialWrite.cpp, RequestSerializer.cpp, FragmentOutputSpecialization.hpp, Recompiler.hpp, SpirvEmitterHelpers.hpp, SpirvFormatConvert.cpp, SpirvModuleEmitter.cpp, ShaderInputInfoBuilder.cpp, and both added debt notes. The full Graphics.cpp was excluded from the review folder; I read only the relevant region through the reader. No other changed files were excluded.

Results

Check Result Note
Change inspection passed Relevant changed paths inspected
Tests not run No local checks performed
Hardware claims not run Reported runs not independently verified

Findings

Blocking

None.

Non-blocking

None.

Not verified

The reported GPU test runs and their environments were not independently verified. The full Graphics.cpp was not read; only the modified target test region was inspected. The implementation was not built or tested here, and behavior on gfx1013, Windows, and NVIDIA was not confirmed.

To get this to a good state

Nothing is required.

@ligmaSec ligmaSec left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

The current head conflicts with main 63db72fb61 in the graphics tests and shader-format declarations and serializer. Please preserve both the full-write and masked merge routes to 4_4_4_4 truncation when reconciling #23206. The paired cases should keep ties-to-even as the clear ROUND_MODE control, since the partial-write path can otherwise mask a regression in the packing choice.

AI-assisted: yes.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agc libSceAgc* docs needs rebase Conflicts with main, rebase needed shader core/shader

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants