Skip to content

[NFC][Codegen] Move distribution pattern infrastructure to VectorExt#23669

Merged
Groverkss merged 1 commit intoiree-org:mainfrom
Groverkss:nfc-reorganize-distribution-patterns
Mar 6, 2026
Merged

[NFC][Codegen] Move distribution pattern infrastructure to VectorExt#23669
Groverkss merged 1 commit intoiree-org:mainfrom
Groverkss:nfc-reorganize-distribution-patterns

Conversation

@Groverkss
Copy link
Copy Markdown
Contributor

Move DistributionPattern, VectorLayoutOptions, DistributionSignature, and related signature utility functions from Codegen/Common/GPU/ into Codegen/Dialect/VectorExt/Transforms/DistributionPatterns.{h,cpp}.

The concrete NestedLayout distribution patterns remain in Common/GPU/ to avoid pulling Codegen-level dependencies into the VectorExt dialect layer.

This change allows us to define distribution patterns outside of Common/GPU without having a dependency on Common/GPU. This allows us to define new patterns by only taking a dependency on VectorExtTransforms.

…Transforms

Move DistributionPattern, VectorLayoutOptions, DistributionSignature,
and related signature utility functions from Codegen/Common/GPU/ into
Codegen/Dialect/VectorExt/Transforms/DistributionPatterns.{h,cpp}.

The concrete NestedLayout distribution patterns remain in Common/GPU/
to avoid pulling Codegen-level dependencies into the VectorExt dialect
layer.

This change allows us to define distribution patterns outside of
Common/GPU without having a dependency on Common/GPU. This allows us to
define new patterns by only taking a dependency on VectorExtTransforms.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copy link
Copy Markdown
Contributor

@AGindinson AGindinson left a comment

Choose a reason for hiding this comment

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

LGTM

Do I understand correctly that the original infra in GPUVectorDistribution.cpp has not been unit-tested so far? Or am I missing some LITs that could also be converted into VectorExt dialect tests?

@Groverkss
Copy link
Copy Markdown
Contributor Author

LGTM

Do I understand correctly that the original infra in GPUVectorDistribution.cpp has not been unit-tested so far? Or am I missing some LITs that could also be converted into VectorExt dialect tests?

There are unit tests, they live in Common/GPU/test/gpu_nested...

@Groverkss Groverkss enabled auto-merge (squash) March 6, 2026 11:08
@Groverkss Groverkss merged commit 7de2750 into iree-org:main Mar 6, 2026
123 of 140 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants