[PR #1389] runtime tests: compare heaps on a resource heap tier 1 host (TEST-HEAP-TIER1-HOST) #1419

Open
opened 2026-11-26 20:21:11 +01:00 by 4ld0 · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ubiquitarianism/leonida/pull/1389
Author: @qhukz13
Created: 11/25/2026
Status: 🔄 Open

Base: main ← Head: cont/heap-tier1-tests


📝 Commits (2)

  • 81c9340 runtime tests: handle resource heap tier 1 hosts in heap comparisons
  • d964980 Merge main into cont/heap-tier1-tests

📊 Changes

3 files changed (+104 additions, -37 deletions)

View changed files

📝 docs/testing.md (+1 -0)
📝 runtime/test/d3d12_heap_properties_test.cpp (+31 -7)
📝 runtime/test/d3d12_vulkan_device_test.cpp (+72 -30)

📄 Description

Claimed in the coordination issue as: TEST-HEAP-TIER1-HOST (claim)

Depends on: #1364 for d3d12_vulkan_device and d3d12_heap_properties to pass in full on NVIDIA Pascal (without it
both stop earlier on that card, on the CPU-heap textures). The change here is independent of it.

What and why

The layer accepts heaps without two DENY flags (D3D12_HEAP_FLAG_NONE, ALLOW_ALL_BUFFERS_AND_TEXTURES), as the
console does. A D3D12 host of resource heap tier 1 refuses them with E_INVALIDARG; measured on a GeForce GTX 1050
Ti (Pascal) with Windows 10, whose native D3D12 reports D3D12_RESOURCE_HEAP_TIER_1. So three host comparisons
report mismatches that are the host's tier, not the layer:

  • d3d12_heap_properties: placed buffer, DEFAULT heap, ALLOW_ALL and placed texture, DEFAULT heap, ALLOW_ALL
    (ours 0x0 host 0x80070057);
  • d3d12_vulkan_device, compare_heap_neighbours: the NONE-flag heaps (alignment 0 / 64 KiB / 4 MiB, size 1000,
    upload, readback, custom write-combine L0) fail heap_mismatches <= 0;
  • d3d12_vulkan_device, compare_placed_reserved: every placed case on the default NONE-flag heap gets
    E_UNEXPECTED from the host's CreateHeap (reached once the check above passes).

Each test now asks the host for ResourceHeapTier. On a tier-1 host only:

  • d3d12_heap_properties prints the mixed-heap cases as not comparable on this host (resource heap tier 1 host),
    the way it already prints the MEMORY_POOL_L1 cases on a UMA host, and the host line names the tier;
  • d3d12_vulkan_device creates the NONE-flag heaps as ALLOW_ONLY_BUFFERS in compare_heap_neighbours, and as the
    ALLOW_ONLY_* heap that matches the resource in compare_placed_reserved, on both devices, so the alignment,
    size, heap-type and placement argument checks are still compared; one line says so. Cases that set their heap
    flags on purpose are not touched.

On a tier-2 host nothing changes. docs/testing.md gets one row in its known-problems table.

Tested

GeForce GTX 1050 Ti, NVIDIA 582.66, Windows 10 19045, MSVC RelWithDebInfo, main 0f98d193c + this branch +
#1364, ctest -R "^(d3d12_heap_properties|d3d12_vulkan_device)$" three times: both pass every time
(d3d12_heap_properties: 527 values compared, 0 mismatches). With LEONIDA_HOST_ADAPTER=warp (WARP is tier 2) the
ALLOW_ALL cases are compared again (544 values compared, 0 mismatches). Without this branch the same build fails
d3d12_heap_properties on the two ALLOW_ALL cases and d3d12_vulkan_device at heap_mismatches <= 0.

#1094 (TEST-METHOD-VARIANTS-HEAP-TIER1) does the same for d3d12_method_variants.

GPUs tested: NVIDIA GeForce GTX 1050 Ti, driver 582.66, Windows 10 19045. No game files.

AI-assisted: yes (Claude Code, with Antigravity for the implementation and the runs)

Checklist

  • Based on current main and merges cleanly.
  • One topic.
  • No game data, keys or decryption (CONTRIBUTING.md).
  • A new translator rule is in the contract table of docs/design.md. (Tests only.)

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ubiquitarianism/leonida/pull/1389 **Author:** [@qhukz13](https://github.com/qhukz13) **Created:** 11/25/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `cont/heap-tier1-tests` --- ### 📝 Commits (2) - [`81c9340`](https://github.com/ubiquitarianism/leonida/commit/81c93402fa7edd8a9fd8394a090f630ae06c1dd1) runtime tests: handle resource heap tier 1 hosts in heap comparisons - [`d964980`](https://github.com/ubiquitarianism/leonida/commit/d9649803b1f0c219450f94ae55a137387b486e6c) Merge main into cont/heap-tier1-tests ### 📊 Changes **3 files changed** (+104 additions, -37 deletions) <details> <summary>View changed files</summary> 📝 `docs/testing.md` (+1 -0) 📝 `runtime/test/d3d12_heap_properties_test.cpp` (+31 -7) 📝 `runtime/test/d3d12_vulkan_device_test.cpp` (+72 -30) </details> ### 📄 Description Claimed in the coordination issue as: TEST-HEAP-TIER1-HOST ([claim](https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7147012332)) Depends on: #1364 for `d3d12_vulkan_device` and `d3d12_heap_properties` to pass in full on NVIDIA Pascal (without it both stop earlier on that card, on the CPU-heap textures). The change here is independent of it. ### What and why The layer accepts heaps without two DENY flags (`D3D12_HEAP_FLAG_NONE`, `ALLOW_ALL_BUFFERS_AND_TEXTURES`), as the console does. A D3D12 host of resource heap tier 1 refuses them with `E_INVALIDARG`; measured on a GeForce GTX 1050 Ti (Pascal) with Windows 10, whose native D3D12 reports `D3D12_RESOURCE_HEAP_TIER_1`. So three host comparisons report mismatches that are the host's tier, not the layer: - `d3d12_heap_properties`: `placed buffer, DEFAULT heap, ALLOW_ALL` and `placed texture, DEFAULT heap, ALLOW_ALL` (`ours 0x0 host 0x80070057`); - `d3d12_vulkan_device`, `compare_heap_neighbours`: the NONE-flag heaps (alignment 0 / 64 KiB / 4 MiB, size 1000, upload, readback, custom write-combine L0) fail `heap_mismatches <= 0`; - `d3d12_vulkan_device`, `compare_placed_reserved`: every placed case on the default NONE-flag heap gets `E_UNEXPECTED` from the host's `CreateHeap` (reached once the check above passes). Each test now asks the host for `ResourceHeapTier`. On a tier-1 host only: - `d3d12_heap_properties` prints the mixed-heap cases as `not comparable on this host (resource heap tier 1 host)`, the way it already prints the `MEMORY_POOL_L1` cases on a UMA host, and the host line names the tier; - `d3d12_vulkan_device` creates the NONE-flag heaps as `ALLOW_ONLY_BUFFERS` in `compare_heap_neighbours`, and as the `ALLOW_ONLY_*` heap that matches the resource in `compare_placed_reserved`, on both devices, so the alignment, size, heap-type and placement argument checks are still compared; one line says so. Cases that set their heap flags on purpose are not touched. On a tier-2 host nothing changes. `docs/testing.md` gets one row in its known-problems table. ### Tested GeForce GTX 1050 Ti, NVIDIA 582.66, Windows 10 19045, MSVC RelWithDebInfo, `main` `0f98d193c` + this branch + #1364, `ctest -R "^(d3d12_heap_properties|d3d12_vulkan_device)$"` three times: both pass every time (`d3d12_heap_properties`: 527 values compared, 0 mismatches). With `LEONIDA_HOST_ADAPTER=warp` (WARP is tier 2) the `ALLOW_ALL` cases are compared again (544 values compared, 0 mismatches). Without this branch the same build fails `d3d12_heap_properties` on the two `ALLOW_ALL` cases and `d3d12_vulkan_device` at `heap_mismatches <= 0`. #1094 (TEST-METHOD-VARIANTS-HEAP-TIER1) does the same for `d3d12_method_variants`. GPUs tested: NVIDIA GeForce GTX 1050 Ti, driver 582.66, Windows 10 19045. No game files. AI-assisted: yes (Claude Code, with Antigravity for the implementation and the runs) ### Checklist - [x] Based on current `main` and merges cleanly. - [x] One topic. - [x] No game data, keys or decryption (CONTRIBUTING.md). - [ ] A new translator rule is in the contract table of `docs/design.md`. (Tests only.) 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Sign in to join this conversation.
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
starred/leonida#1419
No description provided.