X86: Make sure we account for the FMA4 register immediate value, otherwise rip-rel...
[oota-llvm.git] / test / Analysis / ScalarEvolution / 2008-07-29-SMinExpr.ll
index a90c8049027d27e0b712d26329a4faa086022a7d..3542ad2a41e07ebca0077d7f0e4ed0e191e1b7f7 100644 (file)
@@ -1,9 +1,8 @@
-; RUN: llvm-as < %s | opt -analyze -scalar-evolution -disable-output \
-; RUN:   -scalar-evolution-max-iterations=0 | \
-; RUN: grep -F "backedge-taken count is (-2147483632 + (2147483632 smax (-1 + (-1 * %x)) smax (-1 + (-1 * %y))))"
+; RUN: opt < %s -analyze -scalar-evolution \
+; RUN:   -scalar-evolution-max-iterations=0 | FileCheck %s
 ; PR2607
 
-define i32 @b(i32 %x, i32 %y) {
+define i32 @b(i32 %x, i32 %y) nounwind {
 entry:
        %cmp2 = icmp slt i32 %y, %x
        %cond3 = select i1 %cmp2, i32 %y, i32 %x
@@ -22,3 +21,6 @@ afterfor:             ; preds = %forinc, %entry
        %j.0.lcssa = phi i32 [ -2147483632, %entry ], [ %dec, %forinc ]
        ret i32 %j.0.lcssa
 }
+
+; CHECK: backedge-taken count is (-2147483632 + ((-1 + (-1 * %{{[xy]}})) smax (-1 + (-1 * %{{[xy]}}))))
+