mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-19 11:02:59 +02:00
[Test] Auto-update checks in a test
This commit is contained in:
parent
78b3f55aa0
commit
39c3beff62
@ -1,9 +1,28 @@
|
||||
; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py
|
||||
; RUN: opt -analyze -enable-new-pm=0 -scalar-evolution %s | FileCheck %s
|
||||
; RUN: opt -disable-output "-passes=print<scalar-evolution>" %s 2>&1 | FileCheck %s
|
||||
|
||||
target triple = "x86_64-unknown-linux-gnu"
|
||||
|
||||
define void @test_and(i16 %in) {
|
||||
; CHECK-LABEL: 'test_and'
|
||||
; CHECK-NEXT: Classifying expressions for: @test_and
|
||||
; CHECK-NEXT: %_tmp25.i = phi i16 [ %in, %bb2 ], [ %_tmp6.i, %bb1.i ]
|
||||
; CHECK-NEXT: --> {%in,+,1}<nsw><%bb1.i> U: full-set S: full-set Exits: 1 LoopDispositions: { %bb1.i: Computable, %bb2: Variant }
|
||||
; CHECK-NEXT: %_tmp6.i = add nsw i16 %_tmp25.i, 1
|
||||
; CHECK-NEXT: --> {(1 + %in),+,1}<nsw><%bb1.i> U: full-set S: full-set Exits: 2 LoopDispositions: { %bb1.i: Computable, %bb2: Variant }
|
||||
; CHECK-NEXT: %or.cond = and i1 %_tmp10.i, %exitcond.i
|
||||
; CHECK-NEXT: --> %or.cond U: full-set S: full-set Exits: true LoopDispositions: { %bb1.i: Variant, %bb2: Variant }
|
||||
; CHECK-NEXT: Determining loop execution counts for: @test_and
|
||||
; CHECK-NEXT: Loop %bb1.i: backedge-taken count is (1 + (-1 * %in))
|
||||
; CHECK-NEXT: Loop %bb1.i: max backedge-taken count is -1
|
||||
; CHECK-NEXT: Loop %bb1.i: Predicated backedge-taken count is (1 + (-1 * %in))
|
||||
; CHECK-NEXT: Predicates:
|
||||
; CHECK: Loop %bb1.i: Trip multiple is 1
|
||||
; CHECK-NEXT: Loop %bb2: <multiple exits> Unpredictable backedge-taken count.
|
||||
; CHECK-NEXT: Loop %bb2: Unpredictable max backedge-taken count.
|
||||
; CHECK-NEXT: Loop %bb2: Unpredictable predicated backedge-taken count.
|
||||
;
|
||||
br label %bb2
|
||||
|
||||
bb2: ; preds = %bb1.i, %bb2, %0
|
||||
@ -19,13 +38,28 @@ bb1.i: ; preds = %bb1.i, %bb2
|
||||
br i1 %or.cond, label %bb2, label %bb1.i
|
||||
}
|
||||
|
||||
; CHECK-LABEL: Determining loop execution counts for: @test_and
|
||||
; CHECK-NEXT: Loop %bb1.i: backedge-taken count is (1 + (-1 * %in))
|
||||
; CHECK-NEXT: Loop %bb1.i: max backedge-taken count is -1
|
||||
; CHECK-NEXT: Loop %bb1.i: Predicated backedge-taken count is (1 + (-1 * %in))
|
||||
|
||||
|
||||
define void @test_or() {
|
||||
; CHECK-LABEL: 'test_or'
|
||||
; CHECK-NEXT: Classifying expressions for: @test_or
|
||||
; CHECK-NEXT: %indvars.iv = phi i64 [ -1, %BB ], [ -1, %0 ]
|
||||
; CHECK-NEXT: --> -1 U: [-1,0) S: [-1,0) Exits: -1 LoopDispositions: { %BB: Invariant }
|
||||
; CHECK-NEXT: %sum.01 = phi i32 [ %2, %BB ], [ undef, %0 ]
|
||||
; CHECK-NEXT: --> {undef,+,-1}<%BB> U: full-set S: full-set Exits: 0 LoopDispositions: { %BB: Computable }
|
||||
; CHECK-NEXT: %1 = trunc i64 %indvars.iv to i32
|
||||
; CHECK-NEXT: --> -1 U: [-1,0) S: [-1,0) Exits: -1 LoopDispositions: { %BB: Invariant }
|
||||
; CHECK-NEXT: %2 = add nsw i32 %1, %sum.01
|
||||
; CHECK-NEXT: --> {(-1 + undef),+,-1}<%BB> U: full-set S: full-set Exits: -1 LoopDispositions: { %BB: Computable }
|
||||
; CHECK-NEXT: %B3 = add i32 %1, %2
|
||||
; CHECK-NEXT: --> {(-2 + undef),+,-1}<%BB> U: full-set S: full-set Exits: -2 LoopDispositions: { %BB: Computable }
|
||||
; CHECK-NEXT: %B = or i1 %C5, %C11
|
||||
; CHECK-NEXT: --> %B U: full-set S: full-set Exits: false LoopDispositions: { %BB: Variant }
|
||||
; CHECK-NEXT: Determining loop execution counts for: @test_or
|
||||
; CHECK-NEXT: Loop %BB: backedge-taken count is undef
|
||||
; CHECK-NEXT: Loop %BB: max backedge-taken count is -1
|
||||
; CHECK-NEXT: Loop %BB: Predicated backedge-taken count is undef
|
||||
; CHECK-NEXT: Predicates:
|
||||
; CHECK: Loop %BB: Trip multiple is 1
|
||||
;
|
||||
%C10 = icmp slt i1 undef, undef
|
||||
br i1 %C10, label %BB, label %exit
|
||||
|
||||
@ -43,8 +77,3 @@ BB: ; preds = %BB, %0
|
||||
exit: ; preds = %BB, %0
|
||||
ret void
|
||||
}
|
||||
|
||||
; CHECK-LABEL: Determining loop execution counts for: @test_or
|
||||
; CHECK-NEXT: Loop %BB: backedge-taken count is undef
|
||||
; CHECK-NEXT: Loop %BB: max backedge-taken count is -1
|
||||
; CHECK-NEXT: Loop %BB: Predicated backedge-taken count is undef
|
||||
|
Loading…
Reference in New Issue
Block a user