I'm guessing this was a holdover from when 0 was an invalid stack
pointer, but surprised nobody has discovered this before.
Also don't allow offset folding for -1 pointers, since it looks weird
to partially fold this.
Paths
| Differential D80564
AMDGPU: Fix wrong null value for private address space ClosedPublic Authored by arsenm on May 26 2020, 8:21 AM.
Details
Diff Detail Event TimelineThis revision is now accepted and ready to land.May 26 2020, 12:38 PM
Revision Contents
Diff 266290 llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp
llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.cpp
llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.h
llvm/test/CodeGen/AMDGPU/GlobalISel/inst-select-load-private.mir
llvm/test/CodeGen/AMDGPU/GlobalISel/legalize-addrspacecast.mir
llvm/test/CodeGen/AMDGPU/addrspacecast.ll
llvm/test/CodeGen/AMDGPU/nullptr.ll
|
Can you compare it not to a literal but to getNullPointerValue(AMDGPUAS::PRIVATE_ADDRESS) please?