Repository navigation
fix(agc): accept the standard component order for 11_11_10 float color targets - #9084
Conversation
|
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.
|
724c1e6 to
2a63e64
Compare
jotitadev
left a comment
There was a problem hiding this comment.
Confirmed red→green on Linux on two vendors (the PR's runs are both Windows: RTX 4080 SUPER and RX 6400).
Tested
Ubuntu 26.04, i7-8700, GCC 15.2.0, Release, BUILD_TESTING=ON, ANYPS5_NO_SHADER_CACHE=1, device selected with VK_ICD_FILENAMES, run as ./agc_driver_packed_float_color_target_tests and ./agc_driver_graphics_tests, on main a6dcea927 (this PR applies cleanly on it).
| test | NVIDIA RTX 3070 (595.99.02) | lavapipe (Mesa, LLVM 21.1.8) |
|---|---|---|
main a6dcea927 + the PR's tests only (State.cpp reverted) |
fail | fail |
| this PR | pass | pass |
With State.cpp reverted and the PR's tests kept, both agc_driver_packed_float_color_target and agc_driver_graphics fail on both devices with AGC graphics: unsupported color format 7 number type 7 component swap 0 — the throw this PR removes for COMP_SWAP 0 on COLOR_10_11_11. With the full PR both pass on both devices.
GPUs tested: NVIDIA GeForce RTX 3070 (595.99.02, Linux) and lavapipe (Mesa, LLVM 21.1.8), Ubuntu 26.04.
Written with AI assistance (Claude Code). I ran the builds and tests above on my machine.
|
Title data point for this PR (data only). Title: PPSA12361, 600 s per run through the runner, Windows 10 Pro 10.0.19045, WinLibs GCC 15.2.0, Release, relinker and all libs built from one tree per state. The Without the change (libs from
With this PR's commit (
So with the change the title gets past the 11_11_10 float target on both cards and stops at the alpha-to-coverage setting Not run: other GPUs, other platforms, the console. AI-assisted (Claude Code). |
…r targets PPSA12361 binds color format 7 (COLOR_11_11_10, float) with COMP_SWAP 0 and stops on "unsupported color format 7 number type 7 component swap 0". Only the reversed order (COMP_SWAP 2) was accepted. The format keeps its 10-bit component in the low bits. The standard swap puts red in the first slot, as Mesa pairs SWAP_STD with COLOR_10_11_11 for R11G11B10_FLOAT, so COMP_SWAP 0 puts red there and COMP_SWAP 2 blue. Swap 0 now decodes with the identity export mapping 0xe4 and the same packing; the other swaps still throw. The decode test accepts swap 0 and keeps refusing swaps 1 and 3. The execution test renders both orders into tiled and linear targets and compares each stored word with the packing of the order. Its program pool grows to fit the second pass. The debt entry names the accepted orders and says the swap 0 layout is derived, not measured. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2a63e64 to
7e2cc7e
Compare
|
Checked the swap 0 layout (red in the low 10 bits, matching Mesa's |
What
PPSA12361 stops on
mainwithAGC graphics: unsupported color format 7 number type 7 component swap 0. Color format 7 (COLOR_11_11_10, float) was accepted only with the reversed component order (COMP_SWAP 2, #7207); the title binds the standard order.The format keeps its 10-bit component in the low bits. COMP_SWAP 2 puts blue there (#7207). The standard swap puts red in the first slot, as Mesa pairs SWAP_STD with COLOR_10_11_11 for R11G11B10_FLOAT (
src/amd/common/ac_formats.c), so COMP_SWAP 0 puts red in the low 10 bits and blue in the high 11.DecodeColorFormatnow accepts swap 0 with the identity export mapping 0xe4 and the same packing as before; swaps 1 and 3 still throw. The 11_11_10 debt entry names the accepted orders and says the swap 0 layout follows from the format and Mesa's swap, not from a console measurement.Tests: the decode test in
agc_driver_graphicsaccepts swap 0 (mapping 0xe4) and keeps refusing swaps 1 and 3;agc_driver_packed_float_color_targetrenders both orders into tiled and linear targets and compares every stored word with the packing of its order (its program pool grows from 32 to 64 for the second pass).Tested
Windows 10 (19045), MinGW-w64 (WinLibs GCC 15.2.0), Release; branch
724c1e6b76onupstream/main3e91c8edf5, merge-tree clean,check_conventionspassed.ctest -R '^agc_driver_graphics$|^agc_driver_packed_float_color_target$': passes 3/3 on NVIDIA GeForce RTX 4080 SUPER and 3/3 on AMD Radeon RX 6400 (theSelected GPUlines of both logs name them). With onlyGraphics/src/State.cpptaken frommainand the PR's tests kept, both tests fail 3/3 on each GPU.agc_shader_memory,agc_driver_image_converted_unorm,agc_driver_image_tablepass.dithered or rounded alpha-to-coverage is unsupported (register 0x2dc = 0x0001aa01)(lines 2662-2663), which this PR does not touch.ImageArrayWindowPastLayerLimit, does not compile with MinGW onmain, test(agc): align the array window test's texels at run time #8310).Checklist
main; no other open PR implements the same functions (feat(agc): render 4_4_4_4 UNORM color targets through packed R16_UINT exports #8563 is 4_4_4_4; feat(agc): blend into 11_11_10 float color targets in the pixel shader #9020 and fix(agc): write a replace blend into a packed color target without blending #7243 change other parts ofState.cppand the 11_11_10 tests, andgit merge-treeof this branch with each head shows no code conflict; with feat(agc): blend into 11_11_10 float color targets in the pixel shader #9020 only the neighbouring lines of the 11_11_10 debt entry conflict).mdfiles or images addedAI-assisted (Claude Code).