Repository navigation
test: respect LEONIDA_HOST_ADAPTER and layer LUID in d3d12_texture_tiles (RT-TEXTURE-TILES-HOST-ADAPTER) - #1941
Merged
aslan2142 merged 1 commit intoNov 25, 2026
Conversation
…les (RT-TEXTURE-TILES-HOST-ADAPTER) runtime/test/d3d12_texture_tiles_test.cpp previously used an unguided native_device() adapter loop that ignored LEONIDA_HOST_ADAPTER and the layer's Vulkan device LUID, defaulting to an integrated GPU (e.g. Intel UHD) on dual-GPU laptops even when configured for discrete GPU testing. Pass vulkan->GetAdapterLuid() to native_device() and query LEONIDA_HOST_ADAPTER matching the pattern in d3d12_buffer_tiles_test.cpp, skipping the native reference comparison cleanly when the requested adapter lacks tier 2 tiled resources instead of failing on the wrong hardware. AI-assisted (Claude Code)
Collaborator
|
Merged, thanks! It mirrors
AI-assisted (Claude Code, Claude Opus 5.5). |
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.
Item ID:
RT-TEXTURE-TILES-HOST-ADAPTER(claimed in Issue #1608: #1608 (comment))Addresses Finding #623 by @efeekrb (Issue #1608):
runtime/test/d3d12_texture_tiles_test.cpp:251previously used an unguidednative_device()adapter enumeration loop that completely ignoredLEONIDA_HOST_ADAPTERand the layer's Vulkan device LUID. On dual-GPU systems (such as laptops with integrated Intel UHD and discrete NVIDIA RTX), the native D3D12 reference device defaulted to the iGPU and failed on Intel CopyTiles offset rounding quirks even whenLEONIDA_HOST_ADAPTERwas explicitly pointed to the NVIDIA GPU.Changes
<cctype>and<string>includes inruntime/test/d3d12_texture_tiles_test.cpp.tiled_device(IDXGIFactory4&, LUID, bool)andnative_device(LUID layer_luid)matching the verified pattern inruntime/test/d3d12_buffer_tiles_test.cpp.LEONIDA_HOST_ADAPTER(case-insensitive substring match or"warp"). When unset, default to the adapter matching the layer Vulkan device LUID (vulkan->GetAdapterLuid()).main(), ensure that whenLEONIDA_HOST_ADAPTERis unset and the layer's adapter supports Tier 2 tiled resources, the native reference device runs on the exact same adapter.Verification
g++ -std=c++20 -fsyntax-only.python -I scripts/check_no_game_data.py runtime/test/d3d12_texture_tiles_test.cpp.python -I tests/test_text_write_line_endings.py.AI-assisted (Claude Code)