[PATCH] D12016: [SeparateConstOffsetFromGEP] sext(a)+sext(b) => sext(a+b) when a+b can't sign-overflow.
Jingyue Wu via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 13 10:50:59 PDT 2015
jingyue created this revision.
jingyue added a reviewer: broune.
jingyue added a subscriber: llvm-commits.
Herald added subscribers: sanjoy, jholewinski.
This patch implements my promised optimization to reunites certain sexts from
operands after we extract the constant offset. See the header comment of
reuniteExts for its motivation.
One key building block that enables this optimization is Bjarke's poison value
analysis (D11212). That helps to prove "a +nsw b" can't overflow.
http://reviews.llvm.org/D12016
Files:
lib/Transforms/Scalar/SeparateConstOffsetFromGEP.cpp
test/Transforms/SeparateConstOffsetFromGEP/NVPTX/split-gep-and-gvn.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D12016.32080.patch
Type: text/x-patch
Size: 7984 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150813/0d57cd56/attachment.bin>
More information about the llvm-commits
mailing list