[PATCH] D46732: [Split GEP] handle trunc() in separate-const-offset-from-gep pass.

Artem Belevich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 10 15:47:17 PDT 2018


tra created this revision.
tra added reviewers: jingyue, jlebar.
Herald added subscribers: bixia, hiraditya, sanjoy, jholewinski.

Let separate-const-offset-from-gep pass handle trunc() when it calculates
constant offset relative to base. The pass itself may insert trunc()
instructions when it canonicalises array indices to pointer-size integers
and needs to handle trunc() in order to evaluate the offset.


https://reviews.llvm.org/D46732

Files:
  llvm/lib/Transforms/Scalar/SeparateConstOffsetFromGEP.cpp
  llvm/test/Transforms/SeparateConstOffsetFromGEP/NVPTX/split-gep-and-gvn.ll
  llvm/test/Transforms/SeparateConstOffsetFromGEP/NVPTX/split-gep.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D46732.146246.patch
Type: text/x-patch
Size: 5228 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180510/a9821efd/attachment.bin>


More information about the llvm-commits mailing list