Repository navigation
fix(rocfft): fix plan creation for multi-kernel Bluestein with scale factor - #13098
Merged
Merged
Conversation
Result scaling on 1D multi-kernel Bluestein plans (PAD_MUL ... RES_MUL) fails in rocfft_plan_create. Add length 196597, which uses that path regardless of architecture or precision, to the callback/scaling sizes.
The multi-kernel Bluestein generator declared its own scale_factor kernel parameter, which the launcher never passes and the kernel never reads. When a scale factor is set, store ops append another scale_factor parameter to the RES_MUL kernel, and runtime compilation fails with "redefinition of parameter 'scale_factor'". Remove the redundant declaration; store ops already add and pass it as needed.
✅ 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. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #13098 +/- ##
===========================================
- Coverage 71.93% 70.92% -1.01%
===========================================
Files 2863 2944 +81
Lines 472701 485345 +12644
Branches 69827 70075 +248
===========================================
+ Hits 340000 344209 +4209
- Misses 109118 117236 +8118
- Partials 23583 23900 +317
*This pull request uses carry forward flags. Click here to find out more.
🚀 New features to boost your workflow:
|
regan-amd
marked this pull request as ready for review
October 6, 2026 19:05
evetsso
approved these changes
Oct 6, 2026
Contributor
TheRock Submodule Bump ActivityNewest first
|
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.
Motivation
JIRA ID: AIFFT-554
rocfft_plan_createfails when a non-unit scale factor is set on a transform whose last kernel writing user output is the multi-kernel BluesteinCS_KERNEL_RES_MUL(e.g., 1D complex transforms of large prime lengths such as 196597 or 1000003). Runtime compilation of that kernel fails witherror: redefinition of parameter 'scale_factor'.Technical Details
bluestein_multi_rtc()(rtc_bluestein_gen.cpp) declared its ownscale_factorkernel parameter. The kernel never reads it, andRTCKernelBluesteinMulti::get_launch_argsnever passes it.scale_factorparameter to the store node (StoreOpsVisitor::visit_Function), apply it to every global store, and pass its value at launch (StoreOps::append_args). The kernel therefore ended up with two parameters of the same name.Test Plan
callback_sizesinaccuracy_test_callback.cpp. On gfx1201 it takes the multi-kernel Bluestein path (PAD_MUL...RES_MUL) in single and double precision. Because thescalingandcallbacksuites share this size list, the change covers:Test Result
On gfx1201 (RX 9070):
scalingcases fail (all complex ones) withrocfft_plan_create failed.scalingandcallback,--test_prob 1).--scalefactoron length 1000003: all transform types, interleaved and planar, single and double, and JIT callback + scale.Submission Checklist