llvm-project
fc5ca839 - [mlir][LLVM] Add support for `ptrtoaddr` (#185104)

Commit
43 days ago
[mlir][LLVM] Add support for `ptrtoaddr` (#185104) The `ptrtoaddr` op is akin to `ptrtoint` with some important differences: * It does not capture the provenance of the pointer, meaning a pointer does not escape and subsequent `inttoptr` don't make a legal pointer. LLVM can then assume the pointer never escaped, which helps alias analysis. * It does not support arbitrary integer types, but only exactly the integer type that is equal in width to the pointer type as specified by the data layout. This PR adds the op the MLIR dialect and adds the corresponding verification for the datalayout property.
Author
Parents
Loading