summaryrefslogtreecommitdiffstats
path: root/llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2008-02-20 06:48:22 +0000
committerNick Lewycky <nicholas@mxc.ca>2008-02-20 06:48:22 +0000
commit1c44ebcf8645a68b3f01161ed94eea43bcd79aae (patch)
tree67effed190a40f32d7387c1efee70852a6639440 /llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll
parent2a8037b5f536ae3ec9f69be63599f65a471f9846 (diff)
downloadbcm5719-llvm-1c44ebcf8645a68b3f01161ed94eea43bcd79aae.tar.gz
bcm5719-llvm-1c44ebcf8645a68b3f01161ed94eea43bcd79aae.zip
Add 'umax' similar to 'smax' SCEV. Closes PR2003.
Parse reversed smax and umax as smin and umin and express them with negative or binary-not SCEVs (which are really just subtract under the hood). Parse 'xor %x, -1' as (-1 - %x). Remove dead code (ConstantInt::get always returns a ConstantInt). Don't use getIntegerSCEV(-1, Ty). The first value is an int, then it gets passed into a uint64_t. Instead, create the -1 directly from ConstantInt::getAllOnesValue(). llvm-svn: 47360
Diffstat (limited to 'llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll')
-rw-r--r--llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll b/llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll
index e725852cea1..23ffc650b0d 100644
--- a/llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll
+++ b/llvm/test/Analysis/ScalarEvolution/2007-08-06-Unsigned.ll
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | opt -scalar-evolution -analyze | grep {Loop bb: ( -1 + ( -1 \\* %x) + %y) iterations!}
+; RUN: llvm-as < %s | opt -scalar-evolution -analyze | grep {Loop bb: ( -1 + ( -1 \\* %x) + (( 1 + %x) umax %y)) iterations!}
; PR1597
define i32 @f(i32 %x, i32 %y) {
OpenPOWER on IntegriCloud