2 ; RUN: opt < %s -passes='loop-unroll' -S | FileCheck %s -check-prefixes=ENABLE,COMMON
5 ; RUN: opt < %s -passes='loop-unroll<full-unroll-max=0>' -S | FileCheck %s -check-prefixes=DISABLE,COMMON
6 ; RUN: opt < %s -passes='loop-unroll<full-unroll-max=30>' -S | FileCheck %s -check-prefixes=DISABLE,COMMON
7 ; RUN: opt < %s -passes='loop-unroll<full-unroll-max=36>' -S | FileCheck %s -check-prefixes=ENABLE,COMMON
10 ; RUN: opt < %s -passes='loop-unroll' -unroll-full-max-count=0 -S | FileCheck %s -check-prefixes=DISABLE,COMMON
11 ; RUN: opt < %s -passes='loop-unroll' -unroll-full-max-count=30 -S | FileCheck %s -check-prefixes=DISABLE,COMMON
12 ; RUN: opt < %s -passes='loop-unroll' -unroll-full-max-count=36 -S | FileCheck %s -check-prefixes=ENABLE,COMMON
14 ; Pass option has a priority over cl::opt
15 ; RUN: opt < %s -passes='loop-unroll<full-unroll-max=30>' -unroll-full-max-count=36 -S | FileCheck %s -check-prefixes=DISABLE,COMMON
16 ; RUN: opt < %s -passes='loop-unroll<full-unroll-max=36>' -unroll-full-max-count=30 -S | FileCheck %s -check-prefixes=ENABLE,COMMON
19 ; COMMON-LABEL: @test(
24 %idx = phi i32 [ 0, %entry ], [ %idx.inc, %loop ]
25 %idx.inc = add i32 %idx, 1
26 %be = icmp slt i32 %idx, 32
27 br i1 %be, label %loop, label %exit
30 ; DISABLE: %be = icmp slt i32 %idx, 32
31 ; ENABLE-NOT: %be = icmp slt i32 %idx, 32