[llvm-branch-commits] [llvm] [AMDGPU][SDAG] Add ISD::PTRADD DAG combines (PR #142739)
Jessica Clarke via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Wed Jun 4 09:24:00 PDT 2025
jrtc27 wrote:
> isNullConstant(X), since there are address spaces where 0 is a perfectly
normal value that shouldn't be treated specially,
I don't know if it's important for CHERI to have this or if the IR-level optimisations render it not so needed. But `NULL + int` is how we represent an integer as a pointer, so `NULL + x + y` is something that can legitimately turn up, and we want to be able to fold the x and y together as just integer arithmetic, only converting to a capability at the very end when needed.
https://github.com/llvm/llvm-project/pull/142739
More information about the llvm-branch-commits
mailing list