[Codegen][LLVM] Remove cast to i8* in builtin::address_of#14563
[Codegen][LLVM] Remove cast to i8* in builtin::address_of#14563kparzysz-quic merged 2 commits intoapache:mainfrom
Conversation
This cast was initially added when `CreateBufferPtr` did not include the cast to the appropriate address space, and is no longer necessary. Removing the cast will not harm LLVM configurations with opaque pointers ([default in LLVM 15+](https://github.com/llvm/llvm-project/blob/main/llvm/docs/OpaquePointers.rst)), and avoids type mismatches when using LLVM configurations that use typed pointers.
|
Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment.
Generated by tvm-bot |
1 similar comment
|
Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment.
Generated by tvm-bot |
|
This caused failures in |
For compatibility with earlier versions of LLVM. Newer versions have an overloaded prefetch intrinsic, and the pointer cast is unnecessary.
This cast was initially added when
CreateBufferPtrdid not include the cast to the appropriate address space, and should no longer be necessary. Removing the cast will not harm LLVM configurations with opaque pointers (default in LLVM15+), and avoids type mismatches when using LLVM configurations that use typed pointers.