aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/Utils/LoopSimplify.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-12-21 04:04:05 +0000
committerChris Lattner <sabre@nondot.org>2009-12-21 04:04:05 +0000
commitffbd02829c7beaee158cefa431a0052683caf4fa (patch)
tree0fcf8c9f42206347b7f11c4afda18b77a30e5b10 /llvm/lib/Transforms/Utils/LoopSimplify.cpp
parent900ce231f9bd32885a3ed18a2cfec81d851a12a7 (diff)
downloadllvm-ffbd02829c7beaee158cefa431a0052683caf4fa.zip
llvm-ffbd02829c7beaee158cefa431a0052683caf4fa.tar.gz
llvm-ffbd02829c7beaee158cefa431a0052683caf4fa.tar.bz2
enhance x-(-A) -> x+A to preserve NUW/NSW.
Use the presence of NSW/NUW to fold "icmp (x+cst), x" to a constant in cases where it would otherwise be undefined behavior. Surprisingly (to me at least), this triggers hundreds of the times in a few benchmarks: lencode, ldecode, and 466.h264ref seem to *really* like this. llvm-svn: 91812
Diffstat (limited to 'llvm/lib/Transforms/Utils/LoopSimplify.cpp')
0 files changed, 0 insertions, 0 deletions