[clang] [llvm] [NVPTX] Remove nvvm.bitcast.* intrinsics (PR #107936)
Justin Lebar via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 23 08:58:19 PDT 2024
================
@@ -599,14 +599,6 @@ TARGET_BUILTIN(__nvvm_e4m3x2_to_f16x2_rn_relu, "V2hs", "", AND(SM_89,PTX81))
TARGET_BUILTIN(__nvvm_e5m2x2_to_f16x2_rn, "V2hs", "", AND(SM_89,PTX81))
TARGET_BUILTIN(__nvvm_e5m2x2_to_f16x2_rn_relu, "V2hs", "", AND(SM_89,PTX81))
-// Bitcast
----------------
jlebar wrote:
(Thank you, past me, for the commit message.) The key in the commit message from the previous commit is
> These builtins don't need to be backfilled in clang: They're not accessible to user code from nvcc.
If they were accessible from nvcc, we could have compatibility issues where user code (or, just as likely, CUDA headers) expects the builtin to be there. In which case we might want to keep the builtin (in the same way that we auto-upgrade the llvm intrinsic).
I tried to check using cuda.godbolt.org whether these builtins exist in nvcc, but at this very moment it seems to be down, it's not compiling anything.
Assuming that something like the following does not compile in nvcc, I think this is fine.
```
__global__ void foo() {
__nvvm_bitcast_f2i(0.0);
}
```
https://github.com/llvm/llvm-project/pull/107936
More information about the llvm-commits
mailing list