Repository navigation
Conversation
Add clean-room GFX10 texture tiling and detiling runtime in src/startup_stubs/: - Implement src/startup_stubs/gfx10_texture.h using AMD GFX10 addrlib micro-tile equations (SPDX-License-Identifier: MIT, derived from Mesa src/amd/addrlib). - Support Thin S and Thin D 256-byte micro-tiles across 1B, 2B, 4B, 8B, and 16B elements (BC1-BC7, R8, R16, R32, RG8, RGBA8, BGRA8, RGBA16, RGBA32, D16, D24S8, D32F). - Support non-XOR swizzle modes: SW_64KB_S, SW_64KB_D, SW_4KB_S, SW_4KB_D, SW_256B_S, SW_256B_D, and SW_LINEAR. - Implement mip tail packing, origin placement, and linear<->tiled subresource transfers (copy_subresource<into>). - Wire TextureComputer slots in xg_xs.dll (slots 2, 3, 4, 5, 6, 8, 9, 10), including functional slot 9 (CopyFromSubresource detile). - Integrate general GFX10 detiling into D3D12 runtime upload_texture and publish_tiled_texture. - Add synthetic verification test suite tests/startup_xg_gfx10_check.py covering 12 texture shapes, formats, and swizzle configurations. Verification: ctest --preset dev --no-tests=error -R '^(startup_xg_|bc7_|texture_bc|bcpack)' -V 19/19 tests passed (100%)
…t RbPlus hypothesis
Resolve the CMakePresets.json conflict by keeping upstream's new pr targets and filter entries alongside this branch's XG targets and tests. Co-Authored-By: Claude Code <noreply@anthropic.com>
Add BC7 81x69 4m 4KB_S and BC7 129x129 4m 4KB_S to the GFX10 addrlib oracle. The 81x69 shape alone does not discriminate: at 4 KB BC7 the tile is 16x16 blocks, so the ShiftCeil extents (11x9 at mip 1) and the rounded-down ones (10x9) still fit one tile. 129x129 crosses the tile boundary at mip 1 (17 vs 16 blocks), so reverting the tiled mip_start loop to columns/rows fails it: surf=61440 vs 49152. Verified against Mesa 25.1.0 addrlib (navi21); the mutation was applied locally, run, and reverted. Co-Authored-By: Claude Code <noreply@anthropic.com>
The nine-mip BC5/BC7 section reads as if XG slots 2/3/6/8/9/10 handled layout 0x109 only. Note the general computer in the next section and keep the pins specific to the earlier shape. In startup-runtime.md, name the scope of Gfx10Texture after R0Y00#1469 instead of describing it as future work. Co-Authored-By: Claude Code <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Depends on #1469
Aligns the 4-byte
_D/displayswizzle row with GFX10.3 / RDNA2 RbPlus (----x0x1y0y1x2y2) across bothsrc/startup_stubs/gfx10_texture.handsrc/startup_stubs/gfx10_layout.h, and restores the corresponding Mesa 25.1.0 AddrLib (supportRbPlus = 1) pins.Changes
src/startup_stubs/gfx10_texture.handsrc/startup_stubs/gfx10_layout.h: update 4-byte_D/displaypattern to----x0x1y0y1x2y2.tests/startup_gfx10_layout_check.cpp: update 4-byte display equations (0x102,0x106,0x10a) to... Y0 Y1 X2 Y2 ....tests/startup_xg_gfx10_check.pyandtests/xg_swizzle_select_check.cpp: restore RbPlus pins (R32 64x64 1m 256B_DAddrLib comparison).docs/startup-runtime.mdanddocs/experiments.md: document that the 4-byte display row uses GFX10.3 RbPlusx2y2and differs from the 4-byte standard rowy2x2.Verification (
release)ctest --preset release --no-tests=error -R ^(startup_xg_.*|xg_.*|startup_gfx10_layout.*)$ -V: 20/20 passeddocs_links_check.py,bidi_controls_check.py,gfx10_texture_roundtrip_check.py: PASSBackground & Rationale
src/amd/addrlib/src/gfx10/gfx10SwizzlePattern.h), GFX10.3 / RDNA2 hardware withsupportRbPlus = 1selectsGFX10_SW_256_D_RBPLUS_PATINFO(andSW_4K_D_RBPLUS/SW_64K_D_RBPLUS), which uses pattern index 39 (----x0x1y0y1x2y2: bit 6 =x2, bit 7 =y2) for 4-byte elements, whereas non-RbPlus Navi1x uses pattern index 2 (----x0x1y0y1y2x2).#3787lets#1469merge first with a single consistent equation acrossgfx10_texture.handgfx10_layout.h, while updating both headers, pins, and docs atomically here once @R0Y00 confirms the GFX10.3 RbPlus row.mainand marked ready for review right after#1469lands.