diff options
Diffstat (limited to 'llvm/test/CodeGen/X86/cmov-into-branch.ll')
-rw-r--r-- | llvm/test/CodeGen/X86/cmov-into-branch.ll | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/llvm/test/CodeGen/X86/cmov-into-branch.ll b/llvm/test/CodeGen/X86/cmov-into-branch.ll index 909440800a5..0fb3d76a15b 100644 --- a/llvm/test/CodeGen/X86/cmov-into-branch.ll +++ b/llvm/test/CodeGen/X86/cmov-into-branch.ll @@ -1,6 +1,6 @@ ; RUN: llc -march=x86-64 -mcpu=core2 < %s | FileCheck %s -; cmp with single-use load, should not form cmov. +; cmp with single-use load, should not form branch. define i32 @test1(double %a, double* nocapture %b, i32 %x, i32 %y) { %load = load double, double* %b, align 8 %cmp = fcmp olt double %load, %a @@ -8,9 +8,7 @@ define i32 @test1(double %a, double* nocapture %b, i32 %x, i32 %y) { ret i32 %cond ; CHECK-LABEL: test1: ; CHECK: ucomisd -; CHECK-NOT: cmov -; CHECK: j -; CHECK-NOT: cmov +; CHECK: cmovbel } ; Sanity check: no load. @@ -23,19 +21,6 @@ define i32 @test2(double %a, double %b, i32 %x, i32 %y) { ; CHECK: cmov } -; Multiple uses of %a, should not form cmov. -define i32 @test3(i32 %a, i32* nocapture %b, i32 %x) { - %load = load i32, i32* %b, align 4 - %cmp = icmp ult i32 %load, %a - %cond = select i1 %cmp, i32 %a, i32 %x - ret i32 %cond -; CHECK-LABEL: test3: -; CHECK: cmpl -; CHECK-NOT: cmov -; CHECK: j -; CHECK-NOT: cmov -} - ; Multiple uses of the load. define i32 @test4(i32 %a, i32* nocapture %b, i32 %x, i32 %y) { %load = load i32, i32* %b, align 4 |