Repository navigation
fix(hip-kernel-provider): build the kernel ingestor without rocKE (ALMIOPEN-2643) - #12659
Merged
BrianHarrisonAMD merged 21 commits intoOct 7, 2026
Merged
Conversation
HIPDNN_ENABLE_KERNEL_INGESTOR=ON with HIPKERNELPROVIDER_ENABLE_ROCKE=OFF failed at configure: the provider hard-errored on the combination, and descriptor packaging treated the rocKE wheels, comgr probe and private wheel interpreter as mandatory for every pack root. Gate every rocKE-specific piece of descriptor packaging on HIPKERNELPROVIDER_ENABLE_ROCKE: - hkp_wire_pack_target takes a required ENABLE_ROCKE. OFF runs the pack under the base Python3 interpreter with no rocKE environment, wheel edge or PYTHONPATH prepend, and passes --no-rocke to hkp_pack.py. - hkp_pack.py --no-rocke makes any rocke UKD selected for a packed arch a hard pack error naming the flag; arch-pruned rocke UKDs are left alone. - The wheel-supply assertions, comgr resolution and wheel install run only with rocKE enabled. - With rocKE disabled, the rocKE-only pytest files are not registered and rocKE tests in shared files (marked `rocke`) are deselected. With rocKE enabled the pack commands and pytest registrations are unchanged.
✅ All Checks Passed — Ready for Review
📖 Need help? See the Policy FAQ for details on every check and how to fix failures. |
|
🎉 All checks passed! This PR is ready for review. |
…rocke Every descriptor-packaging test that needs rocKE (the rocke/kernels packages, comgr, the rocKE wheels, the rocKE example corpus, all-rocke fixtures, or the rocke producer) lives under tests/rocke/, with its own conftest owning the rocke import path and the rocke_available / rocke_importable gates. No shared test file carries rocKE tests. With HIPKERNELPROVIDER_ENABLE_ROCKE=OFF, hkp_register_tests passes a single --ignore for tests/rocke; with it ON the pytest commands are unchanged from develop. The per-test `rocke` marker, its conftest hook and the marker deselection are removed. Producer-agnostic coverage that previously came only from rocKE corpora is backfilled with hip-driven tests: desk-check invariants 2/3 and CLI verdicts on a real hip pack, the pre-pack toc_key NOT-APPLICABLE report, same-filename folders both shipping, the hip example tree packing end to end, hipcc provenance, and the pool naming the first failure in walk order. The synthesised ELF/msgpack helpers move to synthesised_objects.py so both conftest levels can share them.
- The arch-pruned --no-rocke gate test now packs a KDP that survives the
requested arch through a hip UKD while carrying a rocke UKD scoped to
another arch, inline and as a standalone .ukd.json, so it reaches the
gate; a gate that ignored per-UKD arch fails it.
- Add test_hkp_pack_wiring.py: sub-configures HkpPackaging.cmake with
rocKE OFF and a pip-less interpreter, asserting the pack runs with
--no-rocke and no rocKE env, PYTHONPATH prepend or wheel stamp; that any
ROCKE_* keyword (including an empty value) and a missing ENABLE_ROCKE fail
configure; and that only the OFF suites ignore tests/rocke.
- The --no-rocke gate raises inside the per-arch error handling, naming
every offending arch and dropping each failing shard.
- _hkp_pack_producer reads the caller's parsed arguments instead of
re-parsing ${ARGV}, so an empty ROCKE_* value is rejected under OFF.
- rocKE configure errors attribute the requirement to rocKE being enabled
and offer -DHIPKERNELPROVIDER_ENABLE_ROCKE=OFF; the kpack runtime check no
longer demands pip, which only the rocKE wheel install needs.
- test_worker_inherits_parent_sys_path checks a conftest-only path so it
can fail again; the desk-check packed variant set models the real
post-pack shape (spec under provenance.spec) and gains a drift case.
- Helpers shared across test modules move to plain modules
(pack_helpers.py, cmake_harness.py); no test imports another test
module's private names.
- Building.md and the ingestor/superbuild skill docs describe the
rocKE-optional ingestor.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #12659 +/- ##
===========================================
- Coverage 71.93% 70.46% -1.46%
===========================================
Files 2863 2936 +73
Lines 472676 483327 +10651
Branches 69824 69675 -149
===========================================
+ Hits 339975 340566 +591
- Misses 109118 118839 +9721
- Partials 23583 23922 +339
*This pull request uses carry forward flags. Click here to find out more. 🚀 New features to boost your workflow:
|
…platform-independent - cmake_harness strips the rocKE runtime environment (ROCKE_*) from the child build's environment alongside PYTHON*/PIP_*/CMAKE_*. A rocKE-ON ctest entry exports ROCKE_COMGR_LIB into pytest, which leaked into the rocKE-OFF wiring test's recorded environment and failed its no-rocKE-env assertion. - The arch-pruned --no-rocke gate test no longer asserts the missing hipcc's name appears in the failure: Windows' FileNotFoundError text omits the filename. It still asserts the failure is the hip compile for the arch and not the rocKE gate.
…-ingestor-without-rocke
…dormant without rocKE Since #12311 the default production root holds only the rocKE gfx950 attention_dense bundle, so an ingestor-ON, rocKE-OFF build targeting gfx950 failed the product pack on the --no-rocke gate. With rocKE disabled, the default root now goes dormant when every UKD the packer selects for the build's arches is kind rocke, decided by the packer's own selection (pipeline.selects_only_rocke) at configure. A named root, or a default root that selects any hip UKD, stays wired and still fails on a selected rocke UKD.
…d kinds, skip empty packs Replace the rocKE-specific --no-rocke gate and default-root special case with two generic filters and one dormancy rule: - HKP_DESCRIPTOR_FAMILIES maps a top-level family folder to the option that enables it (rocKE=HIPKERNELPROVIDER_ENABLE_ROCKE); a disabled family's folder is excluded under every root (--exclude-folder). - A kernel_source kind the build has no producer for is pruned like an arch-pruned UKD (--disable-kind); a KDP left empty does not ship. Unknown kinds remain a validation error. - A root with nothing to pack is skipped, not failed. Configure asks the packer (pipeline.shipped_engines) what each arch would ship, leaves the production root dormant when nothing, named or default, and derives Gfx950AttentionDense availability from the same answer, replacing the CMake JSON mirrors.
…g every filter drop, one arch-selection rule
…ite on the bundle the product root carries
…sers/bharriso/hkp-ingestor-without-rocke
…t roots and the arch-agnostic knobs gate
…-ingestor-without-rocke # Conflicts: # dnn-providers/hip-kernel-provider/descriptor-packaging/examples/descriptors/README.md # dnn-providers/hip-kernel-provider/descriptor-packaging/tests/test_desk_check_invariants.py # projects/hipdnn/tools/ai/skills/hipdnn-ingestor-engine/RUNBOOK.md
BrianHarrisonAMD
marked this pull request as ready for review
October 4, 2026 19:36
…acker CLI, invariant 4 on hip packs, and the no-archive guard
…-ingestor-without-rocke # Conflicts: # dnn-providers/hip-kernel-provider/descriptor-packaging/python/hkp_pack/pipeline.py # projects/hipdnn/tools/ai/skills/hipdnn-superbuild/SKILL.md
CMiservaAMD
approved these changes
Oct 6, 2026
CMiservaAMD
left a comment
Contributor
There was a problem hiding this comment.
It appears to do what is claimed. I'm unsure if the benefit of having the ingestor enabled with ROCKE disabled is enough to offset all the extra complexity. Maybe something to discuss further. Approving for now as I don't see any blockers.
… users/bharriso/hkp-ingestor-without-rocke
Reject unrecognised hkp_wire_pack_target arguments, quote the ENABLE_ROCKE values, match --exclude-folder case-insensitively in the packer and CMake, and document exclude_folders / disabled_kinds on load_flat_input.
BradPepersAMD
added a commit
that referenced
this pull request
Oct 6, 2026
The kernel ingestor builds without rocKE; FlyDSL packs on the ingestor gate. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
BradPepersAMD
added a commit
that referenced
this pull request
Oct 6, 2026
The kernel ingestor builds without rocKE; FlyDSL packs on the ingestor gate. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
TheRock Submodule Bump ActivityNewest first
|
yassinsolim
added a commit
that referenced
this pull request
Oct 9, 2026
Four conflicts, all between develop's descriptor-packaging rework (#12950, #12943, #12729, #12659) and this branch's field-test tooling. DescriptorLoader.hpp: both conflicts are comment only. Kept develop's streaming KDP parse and its statement of where the packager puts provenance (inline on a KDP header, sidecar for a packed UKD, anywhere in unpacked or authored trees), and kept this branch's behaviour that provenance is ignored without a warning. The code (PROVENANCE_KEY, isExtensionKey, the skip in requireKnownKeys) merged clean. IngestorGenerator/README.md: merged the verify_variant_sets row, keeping develop's --provenance-root synopsis and sentence and this branch's rocm_kpack fallback and exit 3 sentence. Took develop's variant_reachability row. tests/test_mine_shapes.py: both sides append to the end of the file. Kept both, develop's TestAnEmittedBenchmarkShapeListIsMinable after this branch's dtype-exclusion and node-inputs classes. No helper names collide. RUNBOOK.md stage 4: kept this branch's clang-tidy pointer and took develop's rewritten HIPKERNELPROVIDER_ENABLE_ROCKE paragraph, which no longer claims the option is unconditional.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Configuring hip-kernel-provider with
HIPDNN_ENABLE_KERNEL_INGESTOR=ONandHIPKERNELPROVIDER_ENABLE_ROCKE=OFFfails ondevelop. There are two causes:FATAL_ERRORrejects that combination outright.This PR puts every rocKE-specific piece of descriptor packaging behind
HIPKERNELPROVIDER_ENABLE_ROCKE, so the ingestor builds, packs and tests with the hip producer alone when rocKE is off.JIRA ID : ALMIOPEN-2643
Risk Assessment
Risk level 3. This touches the provider's build and test wiring: CMake packaging functions, the packer CLI, and pytest registration. The rocKE-ON configuration is unchanged. In a configure of each tree (compared before merging the current
develop), the generated pack commands inbuild.ninjaand the pytestCTestTestfile.cmakeare byte-identical todevelop. The new behaviour only applies to a configuration that could not be configured before.ASIC Coverage
Architecture-independent. The change is build and packaging wiring, with no kernel, dispatch or default-selection change. Passing PR CI is sufficient. The pointwise packs were exercised end to end on gfx90a (below) as a smoke test of the rocKE-OFF path.
Testing Summary
develop, configuring with ingestor ON / rocKE OFF fails atdnn-providers/hip-kernel-provider/CMakeLists.txt:414. The same configuration succeeds with this branch, and a full build packs all five test descriptor roots with the rocKE filters (on an earlier revision of this branch).descriptor-packaging/tests/rocke/, and the rocKE-OFF build excludes that one directory. New tests pin the OFF filters:--exclude-folder rocKEremoves therocKE/family folder from a root without reading it, and--disable-kind rockeprunes rocke UKDs elsewhere like arch-pruned ones, drops a KDP left with none, and keeps hip content in a mixed KDP. Hip-driven tests now provide the producer-agnostic coverage that previously came only from rocKE corpora: desk-check invariants on a real pack, hipcc provenance, the hip example tree, and pool failure ordering.developapart from the behaviour changes listed under Technical Changes, andtests/rocke/runs in the same ctest entries as before. Not run end to end here: a provider-level configure or build, a real GPU run, and the Windows comgr derivation. The Windows lane names no production root, so product packing is dormant there (the default engine root holds nothing for gfx1151) and is not verified by that lane.test_hkp_pack_wiring.pysub-configures the packaging module with rocKE OFF and an interpreter with no pip. It asserts that the pack step runs with--exclude-folder rocKE --disable-kind rockeand no rocKE environment,PYTHONPATHprepend or wheel stamp. It also asserts that a strayROCKE_*keyword (including an empty value) or a missingENABLE_ROCKEfails configure, and that only the rocKE-OFF suites ignoretests/rocke/. No CI lane builds the ingestor-ON / rocKE-OFF combination end to end; the full build was verified locally on an earlier revision of this branch and not repeated after merging currentdevelop.test_hkp_pack_layout.pyruns the realtools/hkp_pack.pyfor--exclude-folderand--disable-kind(including an unknown kind, which fails naming it) and fails ifmain()drops either flag; the desk-check suite asserts symbol distinctness on a real hip pack; a stubbed producer that writes no archive for a compiling UKD fails the pack.HIPKERNELPROVIDER_PRODUCTION_SOURCE_ROOTwhose KDPs prune on every build arch is dormant (one STATUS line) rather than a configure failure, and a compiling UKD whose arch list is mistyped (a baregfx94forgfx942) is pruned like content authored for another arch. If a pass-through UKD keeps its KDP alive and no shard writes an archive, the pack succeeds with the compiled kernel missing and no error.developraised there because it asked whether the root held compiling source regardless of pruning; that check also fails legitimately arch-restricted content, and the packer cannot tell the two apart. With rocKE OFF, rocke content outsiderocKE/and rocKE-only named roots are pruned or left dormant rather than raising an error.Testing Checklist
cmake --preset hip-kernel-provider -DHIPDNN_ENABLE_KERNEL_INGESTOR=ON -DHIPKERNELPROVIDER_ENABLE_ROCKE=OFF && ninja- Status: Passed (earlier revision of this branch; not repeated after merging currentdevelop)pytest descriptor-packaging/tests --ignore=tests/rocke(what the rocKE-OFF ctest entries run) - Status: Passed (373 passed, 1 skipped; measured after merging currentdevelop, with rocm_kpack supplied; the skip is a named reason: the in-tree engine root carries no hip bundle)ctest -R 'hip_kernel_provider_tests_quick_suite|hip_kernel_provider_integration_tests_quick_suite|hkp-census'- Devices: gfx90a (MI210) - Status: Passed (earlier revision of this branch; not repeated after merging currentdevelop)develop- generated pack commands compared per root in scratch configures of the packaging module after merging currentdevelop- Status: Passed for all six wired roots, apart from hidden paths no longer being inputs of the pack step; not a provider-level configure or buildpytest descriptor-packaging/tests- Status: Passed (471 passed, 1 skipped, includingtests/rocke/; measured after merging currentdevelop). CI runs both pytest entries (quick and standard) overtests/on the Linux and Windows lanes, both configured with ingestor ON / rocKE ONpre-commit run --files <changed files>- Status: Passed on the feature and test-coverage commits. The merge ofdevelopand the follow-up RUNBOOK edit were committed without hooks (the large-files hook hung locally on I/O); their files are covered by PR CITechnical Changes
CMakeLists.txt: remove theFATAL_ERRORfor ingestor ON with rocKE OFF.HkpPackaging.cmake:hkp_wire_pack_targettakes a requiredENABLE_ROCKE <bool>.ROCKE_*keyword and runs the pack under the basePython3_EXECUTABLEwith no rocKE environment,PYTHONPATHprepend or wheel dependency. It passes--exclude-folder rocKEand--disable-kind rocke.--ignorefortests/rocke/. With it enabled, the commands are unchanged.hkp_pack.py/pipeline.py/descriptors.py: new repeatable--exclude-folder NAME(a top-level family folder of the root that this build does not pack, matched case-insensitively; a name that matches no folder is ignored) and--disable-kind KIND(akernel_sourcekind with no producer in this build; its UKDs are pruned like arch-pruned ones and a KDP left with none is dropped; an unknown kind is an error). CMake passesrocKEandrockewhen rocKE is OFF, so rocKE content is skipped rather than compiled. Without the flags the packer still compiles rocke, so ON behaviour of the CLI is unchanged.run_pipelinerather than aHkpPackError, and configure leaves such a root dormant with one STATUS line, including a root named byHIPKERNELPROVIDER_PRODUCTION_SOURCE_ROOT(previously a hard failure). The "descriptors but no archive" invariant is checked per shipped shard rather than per root: it names the offending arch and UKD, and catches an archive-less shard next to a healthy one. It keys on what survives arch pruning, so it no longer fires for a compiling UKD that pruning removed (see Known limits). Hidden paths are no longer inputs of the pack step.descriptor-packaging/tests/rocke/, which has its ownconftest.pyowning the in-tree rocke import path and therocke_available/rocke_importablegates. No shared test file contains rocKE tests.synthesised_objects.py, so both conftest levels can share them..ukd.jsonforms), a KDP left with no enabled kind does not ship, an excluded folder is never read, and a mixed KDP keeps its hip UKDs.test_hkp_pack_wiring.pycovers the rocKE-OFF CMake wiring and its misuse errors.synthesised_objects.py,pack_helpers.py,cmake_harness.py).descriptor-packaging/README.md,projects/hipdnn/docs/Building.mdand the hipDNN ingestor/superbuild skill docs describe the rocKE-ON and rocKE-OFF packaging modes.