Initial support for anti-dependence breaking. Currently this code does not
[oota-llvm.git] / test / CodeGen / X86 / break-anti-dependencies.ll
1 ; RUN: llvm-as < %s | llc -march=x86-64 -disable-post-RA-scheduler=false > %t
2 ; RUN:   grep {%xmm0} %t | count 14
3 ; RUN:   not grep {%xmm1} %t
4 ; RUN: llvm-as < %s | llc -march=x86-64 -disable-post-RA-scheduler=false -break-anti-dependencies > %t
5 ; RUN:   grep {%xmm0} %t | count 7
6 ; RUN:   grep {%xmm1} %t | count 7
7
8 define void @goo(double* %r, double* %p, double* %q) nounwind {
9 entry:
10         %0 = load double* %p, align 8
11         %1 = add double %0, 1.100000e+00
12         %2 = mul double %1, 1.200000e+00
13         %3 = add double %2, 1.300000e+00
14         %4 = mul double %3, 1.400000e+00
15         %5 = add double %4, 1.500000e+00
16         %6 = fptosi double %5 to i32
17         %7 = load double* %r, align 8
18         %8 = add double %7, 7.100000e+00
19         %9 = mul double %8, 7.200000e+00
20         %10 = add double %9, 7.300000e+00
21         %11 = mul double %10, 7.400000e+00
22         %12 = add double %11, 7.500000e+00
23         %13 = fptosi double %12 to i32
24         %14 = icmp slt i32 %6, %13
25         br i1 %14, label %bb, label %return
26
27 bb:
28         store double 9.300000e+00, double* %q, align 8
29         ret void
30
31 return:
32         ret void
33 }