Skip to content

[Decode] Validate VVC LMCS APS IDs in long format - #2083

Open
XinfengZhang wants to merge 1 commit into
intel:masterfrom
XinfengZhang:fix-vvc-lmcs-id
Open

XinfengZhang wants to merge 1 commit into
intel:masterfrom
XinfengZhang:fix-vvc-lmcs-id

Conversation

@XinfengZhang

Copy link
Copy Markdown
Contributor

Validate the LMCS APS ID before the long-format slice state reads the
ready mask or clears a reshaper entry. Reject IDs outside the four-entry
APS table, and independently protect reshaper construction. This prevents
out-of-bounds array access and invalid shifts while preserving valid APS
reuse and ignoring IDs when LMCS is unused.

Validation: 131,328 boundary cases passed with AddressSanitizer and
UndefinedBehaviorSanitizer using the extracted production reshaper
function, LMCS state block, and LMCS data structures with dependency stubs.
Covered every 8-bit APS ID and ready mask, LMCS enabled/disabled, and direct
reshaper construction. git diff --check passed. Full driver build and GPU
decode were not run.

Reject out-of-range LMCS APS IDs before accessing reshaper arrays or
shifting the ready mask in long-format slice state programming. Also
guard reshaper construction directly, matching the short-format limit.

Leave unused LMCS IDs ignored and preserve reuse of valid ready tables.
@XinfengZhang
XinfengZhang marked this pull request as ready for review November 26, 2026 08:25
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