[llvm] f79ce58 - autogen a SCEV test for ease of update

Philip Reames via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 16 12:19:46 PDT 2021


Author: Philip Reames
Date: 2021-09-16T12:19:30-07:00
New Revision: f79ce5875f560528c801c404b1be1ce3e203c2e1

URL: https://github.com/llvm/llvm-project/commit/f79ce5875f560528c801c404b1be1ce3e203c2e1
DIFF: https://github.com/llvm/llvm-project/commit/f79ce5875f560528c801c404b1be1ce3e203c2e1.diff

LOG: autogen a SCEV test for ease of update

Added: 
    

Modified: 
    llvm/test/Analysis/ScalarEvolution/trip-count-implied-addrec.ll

Removed: 
    


################################################################################
diff  --git a/llvm/test/Analysis/ScalarEvolution/trip-count-implied-addrec.ll b/llvm/test/Analysis/ScalarEvolution/trip-count-implied-addrec.ll
index f75d78ee3152b..9ea26f14eb7dd 100644
--- a/llvm/test/Analysis/ScalarEvolution/trip-count-implied-addrec.ll
+++ b/llvm/test/Analysis/ScalarEvolution/trip-count-implied-addrec.ll
@@ -1,3 +1,4 @@
+; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py
 ; RUN: opt < %s -disable-output "-passes=print<scalar-evolution>"  -scalar-evolution-classify-expressions=0 2>&1 | FileCheck %s
 
 ; A collection of tests that show we can use facts about an exit test to
@@ -8,10 +9,15 @@
 
 @G = external global i8
 
-; CHECK-LABEL: Determining loop execution counts for: @nw_implies_nuw
-; CHECK: Loop %for.body: backedge-taken count is %n
-; CHECK: Loop %for.body: max backedge-taken count is -1
 define void @nw_implies_nuw(i16 %n) mustprogress {
+; CHECK-LABEL: 'nw_implies_nuw'
+; CHECK-NEXT:  Determining loop execution counts for: @nw_implies_nuw
+; CHECK-NEXT:  Loop %for.body: backedge-taken count is %n
+; CHECK-NEXT:  Loop %for.body: max backedge-taken count is -1
+; CHECK-NEXT:  Loop %for.body: Predicated backedge-taken count is %n
+; CHECK-NEXT:   Predicates:
+; CHECK:       Loop %for.body: Trip multiple is 1
+;
 entry:
   br label %for.body
 
@@ -26,10 +32,13 @@ for.end:                                          ; preds = %for.body, %entry
   ret void
 }
 
-; CHECK-LABEL: Determining loop execution counts for: @neg_nw_nuw
-; CHECK: Loop %for.body: Unpredictable backedge-taken count
-; CHECK: Loop %for.body: Unpredictable max backedge-taken count
 define void @neg_nw_nuw(i16 %n) mustprogress {
+; CHECK-LABEL: 'neg_nw_nuw'
+; CHECK-NEXT:  Determining loop execution counts for: @neg_nw_nuw
+; CHECK-NEXT:  Loop %for.body: Unpredictable backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Unpredictable max backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Unpredictable predicated backedge-taken count.
+;
 entry:
   br label %for.body
 
@@ -44,10 +53,15 @@ for.end:                                          ; preds = %for.body, %entry
   ret void
 }
 
-; CHECK-LABEL: Determining loop execution counts for: @nw_implies_nsw
-; CHECK: Loop %for.body: Unpredictable backedge-taken count
-; CHECK: Loop %for.body: Unpredictable max backedge-taken count
 define void @nw_implies_nsw(i16 %n) mustprogress {
+; CHECK-LABEL: 'nw_implies_nsw'
+; CHECK-NEXT:  Determining loop execution counts for: @nw_implies_nsw
+; CHECK-NEXT:  Loop %for.body: Unpredictable backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Unpredictable max backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Predicated backedge-taken count is (128 + (-128 smax %n))
+; CHECK-NEXT:   Predicates:
+; CHECK-NEXT:    {-128,+,1}<%for.body> Added Flags: <nssw>
+;
 entry:
   br label %for.body
 
@@ -62,10 +76,13 @@ for.end:                                          ; preds = %for.body, %entry
   ret void
 }
 
-; CHECK-LABEL: Determining loop execution counts for: @neg_nw_nsw
-; CHECK: Loop %for.body: Unpredictable backedge-taken count
-; CHECK: Loop %for.body: Unpredictable max backedge-taken count
 define void @neg_nw_nsw(i16 %n) mustprogress {
+; CHECK-LABEL: 'neg_nw_nsw'
+; CHECK-NEXT:  Determining loop execution counts for: @neg_nw_nsw
+; CHECK-NEXT:  Loop %for.body: Unpredictable backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Unpredictable max backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Unpredictable predicated backedge-taken count.
+;
 entry:
   br label %for.body
 
@@ -81,10 +98,15 @@ for.end:                                          ; preds = %for.body, %entry
 }
 
 
-; CHECK-LABEL: Determining loop execution counts for: @actually_infinite
-; CHECK: Loop %for.body: Unpredictable backedge-taken count
-; CHECK: Loop %for.body: Unpredictable max backedge-taken count
 define void @actually_infinite() {
+; CHECK-LABEL: 'actually_infinite'
+; CHECK-NEXT:  Determining loop execution counts for: @actually_infinite
+; CHECK-NEXT:  Loop %for.body: Unpredictable backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Unpredictable max backedge-taken count.
+; CHECK-NEXT:  Loop %for.body: Predicated backedge-taken count is 257
+; CHECK-NEXT:   Predicates:
+; CHECK-NEXT:    {0,+,1}<%for.body> Added Flags: <nusw>
+;
 entry:
   br label %for.body
 


        


More information about the llvm-commits mailing list