add a cl::opt override for TargetLoweringBase's JumpIsExpensive
[oota-llvm.git] / test / CodeGen / X86 / or-branch.ll
1 ; RUN: llc < %s -mtriple=i386-unknown-unknown -jump-is-expensive=0 | FileCheck %s --check-prefix=JUMP2
2 ; RUN: llc < %s -mtriple=i386-unknown-unknown -jump-is-expensive=1 | FileCheck %s --check-prefix=JUMP1
3
4 define void @foo(i32 %X, i32 %Y, i32 %Z) nounwind {
5 ; JUMP2-LABEL: foo:
6 ; JUMP2-DAG:     jl
7 ; JUMP2-DAG:     je
8 ;
9 ; JUMP1-LABEL: foo:
10 ; JUMP1-DAG:     sete
11 ; JUMP1-DAG:     setl
12 ; JUMP1:         orb
13 ; JUMP1:         jne
14 entry:
15   %tmp1 = icmp eq i32 %X, 0
16   %tmp3 = icmp slt i32 %Y, 5
17   %tmp4 = or i1 %tmp3, %tmp1
18   br i1 %tmp4, label %cond_true, label %UnifiedReturnBlock
19
20 cond_true:
21   %tmp5 = tail call i32 (...) @bar( )
22   ret void
23
24 UnifiedReturnBlock:
25   ret void
26 }
27
28 declare i32 @bar(...)