[Mlir-commits] [mlir] [mlir][ptr] Add constantop convertion (PR #204846)
lonely eagle
llvmlistbot at llvm.org
Fri Jun 19 10:10:40 PDT 2026
linuxlonelyeagle wrote:
> > Thank you for your guidance! I have a question: is `ptr.constant #ptr.address<0>` equivalent to `ptr.constant #ptr.null?`🤨 If they are equivalent, I think we can implement a canonicalization pattern for `ptr.constant`.
>
> They are not, there are no guarantees that nullptr represents the 0 addr, some addr spaces encode nullptr as the max value or a different sentinel value.
This is such an eye-opening answer for me. Thank you.❤️
https://github.com/llvm/llvm-project/pull/204846
More information about the Mlir-commits
mailing list