Skip to content

draft: VkVideoEncoderAV1: fix VUID-vkCmdEncodeVideoKHR- predictionMode-10331#216

Open
dabrain34 wants to merge 1 commit into
KhronosGroup:mainfrom
dabrain34:dab_vvl_av1
Open

draft: VkVideoEncoderAV1: fix VUID-vkCmdEncodeVideoKHR- predictionMode-10331#216
dabrain34 wants to merge 1 commit into
KhronosGroup:mainfrom
dabrain34:dab_vvl_av1

Conversation

@dabrain34

Copy link
Copy Markdown
Contributor

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)

@dabrain34 dabrain34 changed the title VkVideoEncoderAV1: fix UNIDIRECTIONAL_COMPOUND reference-pair selection VkVideoEncoderAV1: fix VUID-vkCmdEncodeVideoKHR- predictionMode-10331 Jun 16, 2026
@dabrain34 dabrain34 changed the title VkVideoEncoderAV1: fix VUID-vkCmdEncodeVideoKHR- predictionMode-10331 draft: VkVideoEncoderAV1: fix VUID-vkCmdEncodeVideoKHR- predictionMode-10331 Jun 16, 2026
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.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant