Repository navigation
d3d12: name invalid_predication in the ExecuteCommandLists log - #9132
Open
sgonzalez-glitch wants to merge 1 commit into
Open
sgonzalez-glitch wants to merge 1 commit into
sgonzalez-glitch wants to merge 1 commit into
Conversation
name() had no case for ReplayResult::invalid_predication, which vulkan_replay.h returns for a SetPredication buffer offset outside its buffer, so a refused batch was logged as "ExecuteCommandLists failed: ?". Close already refuses an out-of-range offset, so this is the replay-time path (the binding seen at execution), but the log should still say why. A missing enumerator in that switch is now a compile error (MSVC C4062, clang -Wswitch), so the next ReplayResult can't fall through to "?". Checked by removing the new case: MSVC stops with C4062 on the switch. Tested on Windows 11, NVIDIA GeForce RTX 2080 (621.24), MSVC 19.44 RelWithDebInfo: builds without new warnings; full runtime ctest 261/264, 11 skipped, the 3 failures are the ones main has on this machine.
abnalstlll-byte
approved these changes
Nov 23, 2026
abnalstlll-byte
left a comment
Contributor
There was a problem hiding this comment.
Independent Windows review (commit 332327c50caa6eb337ed23a9829dcf2511a69e55)
What changed:
runtime/shims/d3d12_com.cpp:- Adds explicit case mapping for
ReplayResult::invalid_predication: returns"invalid predication buffer or offset". - Fixes unhandled enum falling through to
"?"inExecuteCommandListsreplay diagnostics. - Enforces compiler switch exhaustiveness warnings/errors (
-Wswitch/#pragma warning(error: 4062)).
- Adds explicit case mapping for
Verification:
- Clean diff: correct diagnostic string mapping.
- No game data.
LGTM!
This was referenced Nov 23, 2026
|
Tested
|
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.
Claimed in the coordination issue as: #8868 (comment) (new item)
What and why
name()inruntime/shims/d3d12_com.cpphad no case forReplayResult::invalid_predication, whichruntime/src/vulkan_replay.hreturns for aSetPredicationbuffer offset outside its buffer. A batch refused for that reason was logged asExecuteCommandLists failed: ?.Closealready refuses an out-of-range offset (d3d12_close_parity, "SetPredication at offset 4"), so this is the replay-time path, where the check runs against the binding seen at execution. It is not a common case, but the log should still say why the batch was refused.A missing enumerator in that switch is now a compile error: MSVC C4062 and clang
-Wswitch, scoped with push/pop to this one function. The next value added toReplayResultthen can't fall through to"?"again.Tested
Windows 11, NVIDIA GeForce RTX 2080, driver 621.24 (32.0.16.2124), MSVC 19.44 RelWithDebInfo, on main
867d922f0:error C4062: enumerator 'leonida::ReplayResult::invalid_predication' in switch of enum 'leonida::ReplayResult' is not handled. With the case in, it builds with no new warnings.d3d12_vulkan_device(tiles == 1, d3d12_vulkan_device: check PC CreateReservedResource2 behind the Xbox proxy, not through slot 78 #7125),d3d12_indirect_rt(d3d12: an ARRAY_OF_POINTERS entry below the arena is not an overflow (d3d12_indirect_rt on NVIDIA) #6010) andd3d12_depth_resolve(d3d12_depth_resolve: check refused resolves against a destination cleared in its own list (#6610 follow-up) #7905 / d3d12_depth_resolve: read a refused resolve's destination through a list of its own #7930 / d3d12_depth_resolve_test: run a refused resolve as clears, refused list, copy (red since #6610) #7985).AI-assisted: yes
Checklist
docs/design.md, with how it was confirmed. (Not a translator change.)