Skip to content

Handle OpVectorShuffle with differing vector sizes #2391

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 6, 2024

Conversation

svenvh
Copy link
Member

@svenvh svenvh commented Mar 1, 2024

The SPIR-V to LLVM conversion would bail out when encountering an OpVectorShuffle whose vector operands differ in size. SPIR-V allows differing vector sizes, but LLVM's shufflevector does not.

Remove the assert and insert an additional shufflevector to align the vector operands when needed.

@svenvh svenvh requested a review from MrSidims March 1, 2024 09:51
The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.
@svenvh
Copy link
Member Author

svenvh commented Mar 4, 2024

I'll ignore the 'CI' is confusable with 'C1' clang-tidy error.

Copy link
Contributor

@LU-JOHN LU-JOHN left a comment

Choose a reason for hiding this comment

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

LGTM

@svenvh svenvh merged commit 3df5e38 into KhronosGroup:main Mar 6, 2024
@svenvh svenvh deleted the vectorshuffle branch March 6, 2024 10:30
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit that referenced this pull request Mar 6, 2024
…2391) (#2409)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit that referenced this pull request Mar 6, 2024
…2391) (#2410)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit to svenvh/SPIRV-LLVM-Translator that referenced this pull request Mar 6, 2024
…hronosGroup#2391)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit that referenced this pull request Mar 6, 2024
…2391) (#2413)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit that referenced this pull request Mar 6, 2024
…2391) (#2411)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
svenvh added a commit that referenced this pull request Mar 6, 2024
…2391) (#2412)

The SPIR-V to LLVM conversion would bail out when encountering an
`OpVectorShuffle` whose vector operands differ in size.  SPIR-V
allows differing vector sizes, but LLVM's `shufflevector` does not.

Remove the assert and insert an additional `shufflevector` to align
the vector operands when needed.

(cherry picked from commit 3df5e38)
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