[clang] [NVPTX][AMDGPU][CodeGen] Fix `local_space nullptr` handling for NVPTX and local/private `nullptr` value for AMDGPU. (PR #78759)
Matt Arsenault via cfe-commits
cfe-commits at lists.llvm.org
Thu Jan 25 07:34:13 PST 2024
================
@@ -418,8 +418,10 @@ class LLVM_LIBRARY_VISIBILITY AMDGPUTargetInfo final : public TargetInfo {
// value ~0.
uint64_t getNullPointerValue(LangAS AS) const override {
// FIXME: Also should handle region.
- return (AS == LangAS::opencl_local || AS == LangAS::opencl_private)
- ? ~0 : 0;
+ return (AS == LangAS::opencl_local || AS == LangAS::opencl_private ||
+ AS == LangAS::sycl_local || AS == LangAS::sycl_private)
----------------
arsenm wrote:
Is there a point to having separate LangAS enums for these?
https://github.com/llvm/llvm-project/pull/78759
More information about the cfe-commits
mailing list