Skip to content

[FusilliPlugin] Lift and shift fusilli-plugin: shark-ai -> rocm-libraries#2252

Merged
AaronStGeorge merged 14 commits into
ROCm:developfrom
AaronStGeorge:fusilli-plugin-to-the-rock-1-of-n
Oct 24, 2025
Merged

[FusilliPlugin] Lift and shift fusilli-plugin: shark-ai -> rocm-libraries#2252
AaronStGeorge merged 14 commits into
ROCm:developfrom
AaronStGeorge:fusilli-plugin-to-the-rock-1-of-n

Conversation

@AaronStGeorge
Copy link
Copy Markdown
Contributor

@AaronStGeorge AaronStGeorge commented Oct 23, 2025

Motivation

This is a direct "lift and shift" of the hipDnn plugin for fusilli (also known as fusilli-plugin) + git history originally developed in shark-ai.

The (current) plan is to move fusilli-plugin in a few stages:

  • PR 1 (this PR) Directly move code from nod-ai/shark-ai without any edits. At this point the plugin will not build and not be running in rocm-libraries CI (it also won't be running in TheRock CI).
  • PR 2 Follow up with changes need update paths, enable CI, change how we fetch fusilli dependency + hipDnn dependencies, etc. At this point fusilli-plugin should build and run in rocm-libraries CI. Note: TheRock CI will still not be enabled.
  • PR 3 Remove fusilli-plugin from shark-ai.
  • PR 4/N Enable building fusilli plugin optionally in TheRock (see RFC0004-Fusilli-IREE-Kernel-Provider-hipDNN.md) and enable TheRock CI
  • PR N+1 disable CI added in PR 2 as things will now be tested through TheRock CI.

Technical Details

Direct lift and shift using git subtree all code has been previously reviewed in shark-ai.

Test Plan

Tests of all functionally should be current, however initially CI will not test fusilli-plugin. CI will come in follow up PR.

Test Result

Submission Checklist

@AaronStGeorge AaronStGeorge changed the title Fusilli plugin to the rock 1 of n [FusilliPlugin] Lift and shift fusilli-plugin shark-ai -> rocm-libraries Oct 23, 2025
@AaronStGeorge AaronStGeorge changed the title [FusilliPlugin] Lift and shift fusilli-plugin shark-ai -> rocm-libraries [FusilliPlugin] Lift and shift fusilli-plugin: shark-ai -> rocm-libraries Oct 23, 2025
@AaronStGeorge AaronStGeorge marked this pull request as ready for review October 23, 2025 21:24
@AaronStGeorge AaronStGeorge requested a review from a team as a code owner October 23, 2025 21:24
@jayhawk-commits jayhawk-commits added the project: none Does not target any component label Oct 23, 2025
@jayhawk-commits
Copy link
Copy Markdown
Collaborator

Added project: none label to skip Math CI check. Notifying @eidenyoshida for awareness.

@jayhawk-commits
Copy link
Copy Markdown
Collaborator

@amd-jnovotny Note that the docs team was pinged because of the *.md file included in this "lift and shift".

Copy link
Copy Markdown
Member

@sjain-stanford sjain-stanford left a comment

Choose a reason for hiding this comment

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

LGTM. The main thing is between this PR and PR 3/N (when fusilli-plugin is removed from shark-ai), how do you manage contributions to the codebase - freeze the shark-ai mirror, or cherry-pick in both?

@AaronStGeorge
Copy link
Copy Markdown
Contributor Author

I was thinking cherry-pick in both. I don't like it, but hopefully we don't have to spend a lot of time with the sate in superposition.

Copy link
Copy Markdown
Contributor

@amd-jnovotny amd-jnovotny left a comment

Choose a reason for hiding this comment

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

I'll approve to unblock this. We'll want to clean up the readme when it's ready for general release.

@amd-jnovotny
Copy link
Copy Markdown
Contributor

@jayhawk-commits sound good. I approved to unblock it. We'll worry about fixing up the read me later.

AaronStGeorge and others added 14 commits October 24, 2025 15:58
This PR adds a convenience feature for development. When switching
between `hipDNN` code and `fusilli-plugin` code it's nice to have one
location for sources.
This PR adds "all the boring bits" of the fusilli plugin. It adds a
basic engine plugin that hipDNN can load, which ensures that all of the
required API definitions are present, and those APIs called as part of
load function. The PR also tests for plugin loading, logging, and basic
functionality.
This PR implements `hipdnnEnginePluginExecuteOpGraph` enabling
graph/plan execution. We can now complete the initial plugin goal of e2e
run of single node ConvFprop graph.

Note: a simple e2e integration test is added. This should be expanded to
a parameterized matrix of test, once we're on the latest hipDNN
[example](https://github.com/ROCm/rocm-libraries/blob/develop/projects/hipdnn/plugins/miopen_legacy_plugin/integration_tests/IntegrationGpuConvForward.cpp).
Tickets: [ROCm#2363](nod-ai/amd-shark-ai#2363),
[ROCm#2375](nod-ai/amd-shark-ai#2375).
Update build to pull hipdnn from `rocm-libraries` and update clang to
version 20 from TheRock.

Co-authored-by: Sambhav Jain <sambhav.jain@amd.com>
…ld. (ROCm#2449)

This PR fixes `fusilli-plugin` build failure when fusilli benchmarking
(`FUSILLI_BUILD_BENCHMARKS`) was enabled, but fusilli testing
(`FUSILLI_BUILD_TESTS`) was disabled: [link to CI
failure](https://github.com/nod-ai/shark-ai/actions/runs/18206945208/job/51839515287?pr=2410).
Both _should_ be disabled, but ideally the build wouldn't break if one
wasn't. The issue was: both fusilli tests and fusilli benchmarks depend
on `libutils`, but the target was only defined if tests were enabled.
…_agent_enumerator (ROCm#2488)

Got this building on my SharkWorkstation with an RX 9070XT (RDNA4)
targeting the `gfx1201` arch with minimal changes. The `Backend` enum
doesn't need to be specific to the arch, and the iree-compile flag
`--iree-hip-target` can just be derived using `rocm_agent_enumerator`
(which lists the gfx arch from the GPUs visible) based on
https://iree.dev/guides/deployment-configurations/gpu-rocm/#choosing-hip-targets.
… monorepo. (ROCm#2521)

Signed-off-by: MaheshRavishankar <mravisha@amd.com>
Add Fusilli+IREE as a kernel provider and JIT engine for hipDNN
When building `hipDNN` from source it handles downloading and
configuring transitive dependencies, while an installed version requires
the consuming package to provide needed dependencies. In the plugin's
current form, the former is more convenient.
Adds support for async execution and explicit device/stream selection
and updates fusilli plugin to use new API:
- Handle creation supports device id and external HIP stream parameters.
 - Graph execution is async on AMDGPU backend.
 - Fusilli plugin now uses stream if set by user.
@AaronStGeorge AaronStGeorge force-pushed the fusilli-plugin-to-the-rock-1-of-n branch from 618b1c3 to 05f8da9 Compare October 24, 2025 16:22
@AaronStGeorge AaronStGeorge merged commit 1a50a48 into ROCm:develop Oct 24, 2025
9 checks passed
qiangpan2 pushed a commit to qiangpan2/rocm-libraries that referenced this pull request May 29, 2026
Co-authored-by: Jim <jimguo12@amd.com>

[ROCm/composable_kernel commit: 57f4974]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

organization: ROCm project: none Does not target any component

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants