1; RUN: llc -march=hexagon -mcpu=hexagonv5  < %s | FileCheck %s
2; Check that we generate floating point compare in V5
3
4; CHECK: p{{[0-2]+}} = sfcmp.{{.}}
5
6define i32 @foo(float %y) nounwind {
7entry:
8  %retval = alloca i32, align 4
9  %y.addr = alloca float, align 4
10  store float %y, float* %y.addr, align 4
11  %0 = load float, float* %y.addr, align 4
12  %cmp = fcmp ogt float %0, 0x406AD7EFA0000000
13  br i1 %cmp, label %if.then, label %if.else
14
15if.then:                                          ; preds = %entry
16  store i32 1, i32* %retval
17  br label %return
18
19if.else:                                          ; preds = %entry
20  store i32 2, i32* %retval
21  br label %return
22
23return:                                           ; preds = %if.else, %if.then
24  %1 = load i32, i32* %retval
25  ret i32 %1
26}
27
28define i32 @main() nounwind {
29entry:
30  %retval = alloca i32, align 4
31  %a = alloca float, align 4
32  store i32 0, i32* %retval
33  store float 0x40012E0A00000000, float* %a, align 4
34  %0 = load float, float* %a, align 4
35  %call = call i32 @foo(float %0)
36  ret i32 %call
37}
38