[clang] [Cuda] Handle -fcuda-short-ptr even with -nocudalib (PR #111682)
Joseph Huber via cfe-commits
cfe-commits at lists.llvm.org
Wed Oct 9 07:36:13 PDT 2024
jhuber6 wrote:
> I'm not sure why we would ever want the current default if this is an option. I'm trying to see it, but I can't work out a case where a 64bit pointer would make sense, since the even tens-of-thousands of money supercomputer cards have less than 256KiB of addressable shared memory.
>
> It might be a bit of an intrusive change (albeit a relatively mechanical one), but until we see a GPU come to market that has >4GiB addressable shared memory, I think we should use the "short pointer" datalayout as default
It also applies to constant and private / local address spaces. I don't think those hit 4 GiB yet but it's more feasible than shared. Making address space 3 32-bit by default would make sense to me.
https://github.com/llvm/llvm-project/pull/111682
More information about the cfe-commits
mailing list