[PATCH] D61607: Introduce an option to stripPointerCasts to force the same bit pattern
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat May 18 08:42:15 PDT 2019
arsenm added a comment.
In D61607#1507580 <https://reviews.llvm.org/D61607#1507580>, @aykevl wrote:
> To me (someone from outside LLVM), the "keep bit pattern" argument looks confusing. Pointer casts do not necessarily change the bit pattern? In fact, it seems to me that most pointer casts preserve the bit pattern but change the meaning of the pointer (example: address space 1 on AVR which points into flash instead of RAM - no bits are changed with an `addrspacecast`).
This isn't how the IR is defined. addrspacecast is explicitly allowed to change the bit pattern of the pointer, and it does for some addrspace combinations on some targets (like AMDGPU). It has to be assumed it could have changed the bitpattern without specific target information.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D61607/new/
https://reviews.llvm.org/D61607
More information about the llvm-commits
mailing list