Fix rocDecode test#480
Conversation
There was a problem hiding this comment.
Pull request overview
Fixes the failing video_tests_rocdecode CTest by aligning the test arguments and decoder selection logic with the documented hardware_decode_mode=0/1 contract, preventing mismatched decode configuration that could lead to hangs/timeouts.
Changes:
- Update
video_tests_rocdecodeCTest to passhardware_decode_mode=1(valid value) instead of2. - Make
video_tests.cppconsistently treatdecoder_type == 1as the only condition for HW/rocDecode mode.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| tests/cpp_api/video_tests/video_tests.cpp | Makes HW decode mode selection consistent by checking decoder_type == 1. |
| tests/cpp_api/CMakeLists.txt | Fixes the rocDecode CTest argument to use a valid hardware_decode_mode value. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
rrawther
left a comment
There was a problem hiding this comment.
please address copilot comment as well
|
Right now the CI is not running the rocDecode tests (-DCMAKE_DISABLE_FIND_PACKAGE_rocdecode=ON), as otherwise there is the follow cmake error: The /opt/rocm/share/rocdecode/utils directory does not exist in the docker image used in the CI. |
Having the CI build rocDecode from source solves this problem and provides the required source files in the /opt/rocm/share/rocdecode/utils directory. |
|
rocDecode test now enabled and succeeding on the workflow when tested locally (48a2e47) |
Motivation
Fixes #479 so that the video_tests_rocdecode ctest passes.
Technical Details
Pass in 1 as the hardware_decode_mode arg for video_tests.cpp (instead of 2), and also change video_tests.cpp to consistently check if the decoder_type == 1, rather than == 1 in one check and > 0 in another.
Test Plan
rocAL ctests.
Test Result
All 21 ctests pass.