================ @@ -170,6 +170,8 @@ class LLVM_LIBRARY_VISIBILITY NVPTXTargetInfo : public TargetInfo { Opts["cl_khr_global_int32_extended_atomics"] = true; Opts["cl_khr_local_int32_base_atomics"] = true; Opts["cl_khr_local_int32_extended_atomics"] = true; + + Opts["__opencl_c_generic_address_space"] = true; ---------------- Artem-B wrote:
Does it have to be added here? If I read Clang docs correctly it's supposed to be added in clang/lib/Headers/opencl-c-base.h https://github.com/llvm/llvm-project/blob/050e49a93a41909e1f80d6e1d66917f53e4ba016/clang/docs/OpenCLSupport.rst?plain=1#L251-L257 E.g. SPIR-V defines it there: https://github.com/llvm/llvm-project/blob/c5191905a8b0ec0e10a8f72138571871ab1e99e9/clang/lib/Headers/opencl-c-base.h#L62 https://github.com/llvm/llvm-project/pull/137940 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits