1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc --mtriple=loongarch64 -mattr=+d --verify-machineinstrs < %s \
5 define void @getSetCCResultType(ptr %p) {
6 ; CHECK-LABEL: getSetCCResultType:
7 ; CHECK: # %bb.0: # %entry
8 ; CHECK-NEXT: ld.w $a1, $a0, 0
9 ; CHECK-NEXT: ld.w $a2, $a0, 12
10 ; CHECK-NEXT: ld.w $a3, $a0, 4
11 ; CHECK-NEXT: ld.w $a4, $a0, 8
12 ; CHECK-NEXT: sltui $a1, $a1, 1
13 ; CHECK-NEXT: sub.d $a1, $zero, $a1
14 ; CHECK-NEXT: sltui $a3, $a3, 1
15 ; CHECK-NEXT: sub.d $a3, $zero, $a3
16 ; CHECK-NEXT: sltui $a4, $a4, 1
17 ; CHECK-NEXT: sub.d $a4, $zero, $a4
18 ; CHECK-NEXT: sltui $a2, $a2, 1
19 ; CHECK-NEXT: sub.d $a2, $zero, $a2
20 ; CHECK-NEXT: st.w $a2, $a0, 12
21 ; CHECK-NEXT: st.w $a4, $a0, 8
22 ; CHECK-NEXT: st.w $a3, $a0, 4
23 ; CHECK-NEXT: st.w $a1, $a0, 0
26 %0 = load <4 x i32>, ptr %p, align 16
27 %cmp = icmp eq <4 x i32> %0, zeroinitializer
28 %sext = sext <4 x i1> %cmp to <4 x i32>
29 store <4 x i32> %sext, ptr %p, align 16