Skip to content

[Backport to 19] handle OpBitcast between pointers and non-pointers#2959

Merged
svenvh merged 1 commit intoKhronosGroup:llvm_release_190from
svenvh:backport-to-19
Jan 13, 2025
Merged

[Backport to 19] handle OpBitcast between pointers and non-pointers#2959
svenvh merged 1 commit intoKhronosGroup:llvm_release_190from
svenvh:backport-to-19

Conversation

@svenvh
Copy link
Copy Markdown
Member

@svenvh svenvh commented Jan 10, 2025

Adds support for SPIR-V OpBitcast instructions where the source is a pointer and the destination is not a pointer, and where the source is not a pointer and the destination is a pointer. This needs to be handled as a special case because the LLVM bitcast instruction does not support this.

Handles bitcasts between pointers and scalar integers, which is supported by all SPIR-V versions, and pointers and vectors of integers, which is supported by SPIR-V 1.5 (though only for vectors of 32-bit integers).

(cherry picked from commit aafca81)

…hronosGroup#2948)

Adds support for SPIR-V OpBitcast instructions where the source is a pointer and the destination is not a pointer, and where the source is not a pointer and the destination is a pointer. This needs to be handled as a special case because the LLVM bitcast instruction does not support this.

Handles bitcasts between pointers and scalar integers, which is supported by all SPIR-V versions, and pointers and vectors of integers, which is supported by SPIR-V 1.5 (though only for vectors of 32-bit integers).

(cherry picked from commit aafca81)
Copy link
Copy Markdown
Contributor

@MrSidims MrSidims left a comment

Choose a reason for hiding this comment

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

The backports are fine with me

@svenvh svenvh merged commit 46004f6 into KhronosGroup:llvm_release_190 Jan 13, 2025
@svenvh svenvh deleted the backport-to-19 branch January 13, 2025 10:23
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