draft: VkVideoEncoderAV1: fix VUID-vkCmdEncodeVideoKHR- predictionMode-10331#216
Open
dabrain34 wants to merge 1 commit into
Open
draft: VkVideoEncoderAV1: fix VUID-vkCmdEncodeVideoKHR- predictionMode-10331#216dabrain34 wants to merge 1 commit into
dabrain34 wants to merge 1 commit into
Conversation
The previous selection did not match VUID-vkCmdEncodeVideoKHR-
predictionMode-10331: the two references for unidirectional compound
must form a valid pair from {(0,1),(0,2),(0,3),(4,6)}, both present in
referenceNameSlotIndices, both in
unidirectionalCompoundReferenceNameMask, and neither used only as the
CDF reference.
Check only (4,6) out of four spec pairs against the driver's capability
mask as the other pairs are failing.
Also clear primaryReferenceCdfOnly when primary_ref_frame is
PRIMARY_REF_NONE to prevent an out-of-bounds read on
m_refName2DpbIdx[] that would corrupt the CDF-only reference index.
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.
Description
The previous selection did not match VUID-vkCmdEncodeVideoKHR- predictionMode-10331: the two references for unidirectional compound must form a valid pair from {(0,1),(0,2),(0,3),(4,6)}, both present in referenceNameSlotIndices, both in unidirectionalCompoundReferenceNameMask, and neither used only as the CDF reference.
Restrict selection to the BWDREF+ALTREF pair (4,6) — the only pair this encoder sets up coherently. The forward pairs are rejected by the validation layer on tested drivers. Apply the same guard to the bidirectional→unidirectional fallback path; otherwise fall back to single reference.
Also clear primaryReferenceCdfOnly when primary_ref_frame is PRIMARY_REF_NONE to prevent an out-of-bounds read on m_refName2DpbIdx[] that would corrupt the CDF-only reference index.
Type of change
VVL bug fix
Issue (optional)
Tests
NVIDIA GeForce RTX 4060 / NVIDIA 595.44.00 / Ubuntu 24.04.4 LTS
Total Tests: 83
Passed: 72
Crashed: 0
Failed: 0
Not Supported: 10
Skipped: 1 (in skip list)
Success Rate: 100.0%
Additional Details (optional)