llvm.org GIT mirror llvm / cbb188b
R600: Fix broken check lines, missing scalar case. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@218655 91177308-0d34-0410-b5e6-96231b3b80d8 Matt Arsenault 5 years ago
1 changed file(s) with 30 addition(s) and 20 deletion(s). Raw diff Collapse all Expand all
None ; RUN: llc < %s -march=r600 -mcpu=redwood | FileCheck %s --check-prefix=R600-CHECK
1 ; RUN: llc < %s -march=r600 -mcpu=SI -verify-machineinstrs | FileCheck %s --check-prefix=SI-CHECK
0 ; RUN: llc -march=r600 -mcpu=SI -verify-machineinstrs < %s | FileCheck -check-prefix=SI -check-prefix=FUNC %s
1 ; RUN: llc -march=r600 -mcpu=redwood < %s | FileCheck -check-prefix=R600 -check-prefix=FUNC %s
22
3 ; R600-CHECK: @sint_to_fp_v2i32
4 ; R600-CHECK-DAG: INT_TO_FLT * T{{[0-9]+\.[XYZW]}}, KC0[2].W
5 ; R600-CHECK-DAG: INT_TO_FLT * T{{[0-9]+\.[XYZW]}}, KC0[3].X
6 ; SI-CHECK: @sint_to_fp_v2i32
7 ; SI-CHECK: V_CVT_F32_I32_e32
8 ; SI-CHECK: V_CVT_F32_I32_e32
3
4 ; FUNC-LABEL: @s_sint_to_fp_i32_to_f32
5 ; R600: INT_TO_FLT * T{{[0-9]+\.[XYZW]}}, KC0[2].Z
6 ; SI: V_CVT_F32_I32_e32 {{v[0-9]+}}, {{s[0-9]+$}}
7 define void @s_sint_to_fp_i32_to_f32(float addrspace(1)* %out, i32 %in) {
8 %result = sitofp i32 %in to float
9 store float %result, float addrspace(1)* %out
10 ret void
11 }
12
13 ; FUNC-LABEL: @sint_to_fp_v2i32
14 ; R600-DAG: INT_TO_FLT * T{{[0-9]+\.[XYZW]}}, KC0[2].W
15 ; R600-DAG: INT_TO_FLT * T{{[0-9]+\.[XYZW]}}, KC0[3].X
16
17 ; SI: V_CVT_F32_I32_e32
18 ; SI: V_CVT_F32_I32_e32
919 define void @sint_to_fp_v2i32(<2 x float> addrspace(1)* %out, <2 x i32> %in) {
1020 %result = sitofp <2 x i32> %in to <2 x float>
1121 store <2 x float> %result, <2 x float> addrspace(1)* %out
1222 ret void
1323 }
1424
15 ; R600-CHECK: @sint_to_fp_v4i32
16 ; R600-CHECK: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
17 ; R600-CHECK: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
18 ; R600-CHECK: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
19 ; R600-CHECK: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
20 ; SI-CHECK: @sint_to_fp_v4i32
21 ; SI-CHECK: V_CVT_F32_I32_e32
22 ; SI-CHECK: V_CVT_F32_I32_e32
23 ; SI-CHECK: V_CVT_F32_I32_e32
24 ; SI-CHECK: V_CVT_F32_I32_e32
25 ; FUNC-LABEL: @sint_to_fp_v4i32
26 ; R600: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
27 ; R600: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
28 ; R600: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
29 ; R600: INT_TO_FLT * T{{[0-9]+\.[XYZW], T[0-9]+\.[XYZW]}}
30
31 ; SI: V_CVT_F32_I32_e32
32 ; SI: V_CVT_F32_I32_e32
33 ; SI: V_CVT_F32_I32_e32
34 ; SI: V_CVT_F32_I32_e32
2535 define void @sint_to_fp_v4i32(<4 x float> addrspace(1)* %out, <4 x i32> addrspace(1)* %in) {
2636 %value = load <4 x i32> addrspace(1) * %in
2737 %result = sitofp <4 x i32> %value to <4 x float>
3141
3242 ; FUNC-LABEL: @sint_to_fp_i1_f32:
3343 ; SI: V_CMP_EQ_I32_e64 [[CMP:s\[[0-9]+:[0-9]\]]],
34 ; SI-NEXT: V_CNDMASK_B32_e64 [[RESULT:v[0-9]+]], 0, -1.000000e+00, [[CMP]]
44 ; SI-NEXT: V_CNDMASK_B32_e64 [[RESULT:v[0-9]+]], 0, 1.0, [[CMP]]
3545 ; SI: BUFFER_STORE_DWORD [[RESULT]],
3646 ; SI: S_ENDPGM
3747 define void @sint_to_fp_i1_f32(float addrspace(1)* %out, i32 %in) {
4252 }
4353
4454 ; FUNC-LABEL: @sint_to_fp_i1_f32_load:
45 ; SI: V_CNDMASK_B32_e64 [[RESULT:v[0-9]+]], 0, -1.000000e+00
55 ; SI: V_CNDMASK_B32_e64 [[RESULT:v[0-9]+]], 0, -1.0
4656 ; SI: BUFFER_STORE_DWORD [[RESULT]],
4757 ; SI: S_ENDPGM
4858 define void @sint_to_fp_i1_f32_load(float addrspace(1)* %out, i1 %in) {