Repository navigation
fix(hrr): regenerate sources for hipKernelSetCacheConfig - #14241
Conversation
#12628 appended hipKernelSetCacheConfig to HipDispatchTable without regenerating the HRR sources, so the checked-in capture and playback dispatch, hrr_api_args.h and the API matrix expectations no longer match the headers and ctest hrr-generator-rules fails on develop. Capture records it through a generated shim. Playback is a no-op: its hipKernel_t argument cannot be translated back into a live kernel, the same reason hipKernelSetAttributeForDevice is a no-op. The SDK headers the matrix workloads build against do not declare it, so the matrix lists it as unreachable with the other APIs absent from them. The new runtime slot takes the first compiler API ID and shifts the compiler IDs up by one, so HRR_VERSION goes from 10 to 11. The enable-recording inspector gets the v11 ID of __hipRegisterFatBinary.
✅ All Policy Checks Passed
📖 Need help? See the Policy FAQ for details on every check and how to fix failures. |
There was a problem hiding this comment.
🟢 Approval recommended
The generated changes, version bump, matrix expectations, and inspector mapping are consistent, with no blocking issues identified.
No open issues 🎉
What changed in this PR
Regenerates HIP record-and-replay (HRR) sources to match the dispatch-table addition of hipKernelSetCacheConfig, resolving the generated-source drift introduced by #12628.
Changes:
- Adds generated capture support and a warning-once no-op playback handler.
- Updates API matrix classifications, counts, and integration expectations.
- Bumps the archive format to v11 for shifted compiler API IDs and aligns the inspector and documentation.
| File | Description |
|---|---|
projects/hrr/tools/gen_hrr_api_args.py |
Updates the generated format version and history to v11. |
projects/hrr/tools/api-matrix/api_matrix.yaml |
Classifies the API as absent from SDK headers. |
projects/hrr/tools/api-matrix/api_classes_baseline.json |
Updates API and classification counts. |
projects/hrr/tests/integration/hrr_api_matrix_expectations.h |
Adds the new API’s matrix expectations. |
projects/hrr/skills/enable-recording/SKILL.md |
Documents inspector support through v11. |
projects/hrr/skills/enable-recording/scripts/inspect_archive.py |
Maps v11 fat-binary registration to API ID 551. |
projects/hrr/playback/hip_playback_generated.cpp |
Adds no-op playback and updates dispatch tables. |
projects/hrr/include/hrr/hrr_api_args.h |
Adds the payload structure and updates API IDs and version. |
projects/hrr/DESIGN.md |
Documents v11 and the compiler API ID shift. |
projects/clr/hipamd/src/hrr/hip_capture_generated.cpp |
Adds and registers the generated capture shim. |
Review effort: Balanced
danielbolsson
left a comment
There was a problem hiding this comment.
Checked 0030787: I regenerated the same change independently on a clean develop, and the generated sources, hrr_api_args.h and the baseline numbers (557 to 558 APIs) are identical to this PR. Capture shim, playback NOOP, the unreachable matrix entry next to hipKernelSetAttributeForDevice and the v11 bump with inspector id 551 are consistent with #13472. Nothing blocking.
TheRock Submodule Bump ActivityNewest first
|
JIRA ID : AIRUNTIME-3080
Motivation
#12628 appended
hipKernelSetCacheConfigtoHipDispatchTableondevelopwithout regenerating the HRR sources. The checked-in capture and playback dispatch sources,hrr_api_args.hand the API matrix expectations no longer match the HIP headers, so ctesthrr-generator-rulesfails ondevelopintest_generated_files_current. This PR regenerates them.Technical Details
gen_hrr_api_args.py. Nothing in them is edited by hand.hipKernel_targument is one of the opaque types playback cannot turn back into a live object (_UNTRANSLATED_PLAYBACK_TYPES), soplayback_defaults_to_noopapplies.hipKernelSetAttributeForDeviceis a no-op for the same reason.unreachable, groupabsent-from-sdk-headers, next tohipKernelSetAttributeForDevice. The SDK headers the matrix workloads compile against declare neither, so no workload can call it.derive_manifest.py --update-baseline, thencheck_matrix.py --emit-cxx. The baseline gains one runtime API, one generated capture and one no-op replay.HRR_VERSIONgoes from 10 to 11. The new runtime slot takes the first compiler API ID and shifts the nine compiler IDs up by one, so a v10 reader would decode those events as the wrong API. The version history inDESIGN.mdand the generator's header comment record v11.__hipRegisterFatBinaryat ID 551 in a v11 archive, and itsSKILL.mdnames v8 to v11 as the versions it scans. Without the new entry,tools/tests/test_skill_api_ids.pyfails.Issue Tracking
Fixes the
hrr-generator-rulesfailure that #12628 left ondevelop. #13700 and #9098 also moveHRR_VERSIONfrom 10 to 11; whichever of them lands after this PR moves to 12.Test Plan
projects/hrr:python -m unittest discover -s tools/testsandpytest tests/scripts, plus the enable-recording skill tests.check_hrr_api_compat.pyagainst thedevelopheader, on this tree and withHRR_VERSIONleft at 10.lkcc2-d16655aran this tree on top of develop d16655a458. The baselinegdevd16655is that develop on the same runner and scripts.Test Result
hrr-generator-rules, the generated sources and the API classification have driftedEvery case has the same status as on develop. The 31 hidden cases that do not pass also fail or skip on develop.
tools/tests: 31 tests pass, including the twotest_generated_files_currentchecks that fail on develop.tests/scripts: 150 passed.check_hrr_api_compat.py: passes for 10 to 11. WithHRR_VERSIONleft at 10 it fails, because the compiler API IDs moved.Submission Checklist