[llvm] r321792 - [ValueTracking] Adding missed lit-test for commit r316208

Nikolai Bozhenov via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 4 02:02:50 PST 2018


Author: n.bozhenov
Date: Thu Jan  4 02:02:50 2018
New Revision: 321792

URL: http://llvm.org/viewvc/llvm-project?rev=321792&view=rev
Log:
[ValueTracking] Adding missed lit-test for commit r316208

Reviewers: reames, hfinkel

Differential Revision: https://reviews.llvm.org/D34101

Patch by: Olga Chupina <olga.chupina at intel.com>

Added:
    llvm/trunk/test/Analysis/ValueTracking/non-negative-phi-bits.ll   (with props)

Added: llvm/trunk/test/Analysis/ValueTracking/non-negative-phi-bits.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Analysis/ValueTracking/non-negative-phi-bits.ll?rev=321792&view=auto
==============================================================================
--- llvm/trunk/test/Analysis/ValueTracking/non-negative-phi-bits.ll (added)
+++ llvm/trunk/test/Analysis/ValueTracking/non-negative-phi-bits.ll Thu Jan  4 02:02:50 2018
@@ -0,0 +1,27 @@
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
+; RUN: opt -instcombine < %s -S | FileCheck %s
+
+define void @test() #0 {
+; CHECK-LABEL: @test(
+; CHECK-NEXT:  entry:
+; CHECK-NEXT:    br label [[FOR_BODY:%.*]]
+; CHECK:       for.body:
+; CHECK-NEXT:    [[INDVARS_IV:%.*]] = phi i64 [ 0, [[ENTRY:%.*]] ], [ [[INDVARS_IV_NEXT:%.*]], [[FOR_BODY]] ]
+; CHECK-NEXT:    [[INDVARS_IV_NEXT]] = add nuw nsw i64 [[INDVARS_IV]], 1
+; CHECK-NEXT:    [[EXITCOND:%.*]] = icmp ult i64 [[INDVARS_IV_NEXT]], 40
+; CHECK-NEXT:    br i1 [[EXITCOND]], label [[FOR_END:%.*]], label [[FOR_BODY]]
+; CHECK:       for.end:
+; CHECK-NEXT:    ret void
+;
+entry:
+  br label %for.body
+
+for.body:                                         ; preds = %for.body, %entry
+  %indvars.iv = phi i64 [ 0, %entry ], [ %indvars.iv.next, %for.body ]
+  %indvars.iv.next = add nsw i64 %indvars.iv, 1
+  %exitcond = icmp slt i64 %indvars.iv.next, 40
+  br i1 %exitcond, label %for.end, label %for.body
+
+for.end:                                          ; preds = %for.body
+  ret void
+}

Propchange: llvm/trunk/test/Analysis/ValueTracking/non-negative-phi-bits.ll
------------------------------------------------------------------------------
    svn:executable = *




More information about the llvm-commits mailing list