Skip to content

media_softlet: hevc encode: include codechal_debug.h in reference - #2036

Open
kumarsac wants to merge 1 commit into
intel:masterfrom
kumarsac:fix_linker
Open

kumarsac wants to merge 1 commit into
intel:masterfrom
kumarsac:fix_linker

Conversation

@kumarsac

Copy link
Copy Markdown
Contributor

encode_hevc_reference_frames.h guards DumpReferences() with USE_CODECHAL_DEBUG_TOOL but never included codechal_debug.h, which is the only header that defines that macro. Depending on include order, the macro could be undefined (treated as 0) in the TU that compiles encode_hevc_reference_frames.cpp while being 1 in callers that reach codechal_debug.h transitively (e.g. the new Xe3P_LPM_base HEVC vdenc packet), causing DumpReferences() to be omitted from the object file and producing an undefined symbol at link time with strict linkers (-Wl,--no-undefined).

Include codechal_debug.h directly, matching the existing pattern in encode_avc_reference_frames.h, so the macro is always consistently defined for this header/TU regardless of include order.

Change-Id: I3e2c3eebcb4cde47e0def137571b6e7196443e88

…mes header

encode_hevc_reference_frames.h guards DumpReferences() with
USE_CODECHAL_DEBUG_TOOL but never included codechal_debug.h, which is
the only header that defines that macro. Depending on include order,
the macro could be undefined (treated as 0) in the TU that compiles
encode_hevc_reference_frames.cpp while being 1 in callers that reach
codechal_debug.h transitively (e.g. the new Xe3P_LPM_base HEVC vdenc
packet), causing DumpReferences() to be omitted from the object file
and producing an undefined symbol at link time with strict linkers
(-Wl,--no-undefined).

Include codechal_debug.h directly, matching the existing pattern in
encode_avc_reference_frames.h, so the macro is always consistently
defined for this header/TU regardless of include order.

Change-Id: I3e2c3eebcb4cde47e0def137571b6e7196443e88

@XinfengZhang XinfengZhang left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but I am wondering why it was not captured by quick build @Sherry-Lin

@XinfengZhang XinfengZhang added the verifying PR: fix ready and verifying with build/test label Sep 28, 2026
@kumarsac

kumarsac commented Oct 4, 2026

Copy link
Copy Markdown
Contributor Author

@XinfengZhang can we land this as All checks have passed.

Do let me know if any comments, Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

verifying PR: fix ready and verifying with build/test

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants