mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 23:25:53 +01:00
[PR #964] test: texture tiles NOTE only for the measured CopyTiles offset rounding on AMD and Intel (D3D-TILES-AMD-BYTE-OFFSET) #1001
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#1001
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/964
Author: @adrianmjim
Created: 11/24/2026
Status: 🔄 Open
Base:
main← Head:fix/texture-tiles-row-major-offset📝 Commits (4)
0e76c73test: texture tiles NOTE only for AMD's rounded CopyTiles offset (D3D-TILES-AMD-BYTE-OFFSET)e4f0403test: texture tiles review follow-ups (D3D-TILES-AMD-BYTE-OFFSET)83aea69test: texture tiles also accepts Intel's readback-only CopyTiles rounding (D3D-TILES-AMD-BYTE-OFFSET)07a204aMerge remote-tracking branch 'cont/main' into fix/texture-tiles-row-major-offset📊 Changes
3 files changed (+245 additions, -47 deletions)
View changed files
📝
docs/d3d12_vulkan.md(+10 -1)📝
docs/testing.md(+1 -0)📝
runtime/test/d3d12_texture_tiles_test.cpp(+234 -46)📄 Description
Claimed in the coordination issue as: D3D-TILES-AMD-BYTE-OFFSET
What and why
d3d12_texture_tilesfails on AMD Windows (RX 7900 XT, AMD 26.11.2 / 32.0.32029.2010):row-major alias tile 0 at (0,0): got 0x20000cc, expected 0xcc020000. It is one of the fivectestfailures #787 lists for RDNA3 on Windows.The half that fails is native D3D12, not the Vulkan layer. The layer's
256 x 240, linear offset 1replay had already passed. Buffered stdout printed its progress line after the native failure on stderr, which made it look like the layer's failure.AMD's driver behaves as if
CopyTilesroundedBufferStartOffsetInBytesdown to a multiple of 4, in both directions:0x020000cc, which is the bytes at offset 0 instead of offset 1, and the texels that straddle a tile seam.The other implementations disagree with AMD:
CopyTilesdocuments no alignment for that offset.This is inferred from the texel values. I did not run the D3D12 debug layer (not installed on this machine).
Update: an Intel Iris Xe host (Intel 32.0.101.7092), measured in this PR by @MalexAson, rounds the offset only in the tiles-to-buffer copies; its upload honours the offset. The test now accepts that pattern as a second model.
Change (test and docs only, no runtime change):
CopyTilesfrommodelled_readback(). Both round the offset down to a multiple of 4: AMD's in both directions, Intel's only in the tiles-to-buffer copies. The NOTE names the model, and every diverging case on a device must match the same one. Any other divergence still fails and prints, for each model, how many reads it leaves unexplained and the first one. Every byte-offset case first checks that the model with the true offset reproduces the test's expectations. The precedent for a NOTE on a measured driver divergence isd3d12_bundle_test.256x240and240x240at offset 4: native stays strict on clipped tiles on every GPU.host_wine.h), as in the other host-comparison tests. stdout is unbuffered.docs/testing.md: new Known problems row.docs/d3d12_vulkan.md: describes the driver behaviour.Tested
AMD Radeon RX 7900 XT, driver 32.0.32029.2010, Windows 11, MSVC (VS 2022), Vulkan SDK 1.4.363.0, base
23c459644.LEONIDA_VK_VALIDATION=1and 3 without. After: passed 6/6 in a row, with no validation messages, and a passing run prints nogot ... expectedlines. The one exception is the handoff case described below.83aea690a: pass, with the tiles-to-buffer-only NOTE at offsets 1 and 3 (https://github.com/ubiquitarianism/leonida/pull/964#issuecomment-7144284362).ctest: only the 4 failuresmainalready has on this GPU (vk_queue_query_sync,d3d12_execute_indirect_validation#504,d3d12_clear#516/#787,d3d12_pipeline_library_host).Still intermittent on AMD, separate issue: the native half of the COPY-to-DIRECT case (offset 4) sometimes reads zeros through the aliased tiles on this GPU. It failed 5 of 30 runs under a parallel
ctestand once in 3 single-test runs.mainthis case is never reached on AMD, because the offset-1 case fails first. This PR therefore turns a deterministic red into an occasional one on AMD.GPUs tested: AMD Radeon RX 7900 XT (RDNA3), AMD driver 26.11.2 (32.0.32029.2010), Windows 11; Intel Iris Xe (Raptor Lake-P), Intel 32.0.101.7092, Windows 11 24H2 (by @MalexAson)
AI-assisted: yes (Claude Code; the change went through three independent review passes before opening)
Checklist
mainand merges cleanly (written on23c459644, merges cleanly ontoa28927849).docs/design.md, with how it was confirmed. (n/a: no translator change)🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.