brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.7 KiB · 07816f1 Raw
77 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py2; RUN: llc -mtriple=amdgcn -mcpu=gfx1010 < %s | FileCheck %s -check-prefix=ISA3; RUN: llc -mtriple=amdgcn -mcpu=gfx1010 -stop-before=si-fix-sgpr-copies < %s | FileCheck %s -check-prefix=MIR4 5define void @f(i32 %arg, ptr %ptr) {6; ISA-LABEL: f:7; ISA:       ; %bb.0: ; %bb8; ISA-NEXT:    s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)9; ISA-NEXT:    s_mov_b64 s[4:5], 010; ISA-NEXT:    v_cmp_gt_i32_e32 vcc_lo, 1, v011; ISA-NEXT:    s_load_dwordx2 s[4:5], s[4:5], 0x012; ISA-NEXT:    v_mov_b32_e32 v6, 013; ISA-NEXT:    s_waitcnt lgkmcnt(0)14; ISA-NEXT:    s_lshr_b32 s6, s5, 115; ISA-NEXT:    s_lshr_b32 s7, 1, s416; ISA-NEXT:    s_cmp_lg_u32 s4, 017; ISA-NEXT:    s_cselect_b32 s4, -1, 018; ISA-NEXT:    v_cndmask_b32_e64 v0, 0, 1.0, s419; ISA-NEXT:    s_and_b32 s4, s4, exec_lo20; ISA-NEXT:    s_cselect_b32 s4, s6, 021; ISA-NEXT:    s_cselect_b32 s6, s7, 022; ISA-NEXT:    s_cselect_b32 s5, s5, 023; ISA-NEXT:    v_cvt_f32_i32_e32 v3, s424; ISA-NEXT:    v_cvt_f32_ubyte0_e32 v4, s625; ISA-NEXT:    v_cvt_f32_i32_e32 v5, s526; ISA-NEXT:    s_mov_b32 s4, 027; ISA-NEXT:  .LBB0_1: ; %bb1428; ISA-NEXT:    ; =>This Inner Loop Header: Depth=129; ISA-NEXT:    v_mov_b32_e32 v7, v630; ISA-NEXT:    s_and_b32 s5, exec_lo, vcc_lo31; ISA-NEXT:    s_or_b32 s4, s5, s432; ISA-NEXT:    v_add_f32_e32 v6, v7, v033; ISA-NEXT:    v_add_f32_e64 v6, v6, |v3|34; ISA-NEXT:    v_add_f32_e32 v6, v6, v435; ISA-NEXT:    v_add_f32_e32 v6, v6, v536; ISA-NEXT:    s_andn2_b32 exec_lo, exec_lo, s437; ISA-NEXT:    s_cbranch_execnz .LBB0_138; ISA-NEXT:  ; %bb.2: ; %bb2139; ISA-NEXT:    s_or_b32 exec_lo, exec_lo, s440; ISA-NEXT:    flat_store_dword v[1:2], v741; ISA-NEXT:    s_waitcnt lgkmcnt(0)42; ISA-NEXT:    s_setpc_b64 s[30:31]43bb:44  %i = load <2 x i32>, ptr addrspace(4) null, align 429496729645  %i1 = extractelement <2 x i32> %i, i64 146  %i2 = extractelement <2 x i32> %i, i64 047  %i3 = lshr i32 %i1, 148  %i4 = icmp ne i32 %i2, 049  %i5 = select i1 %i4, i32 %i3, i32 050  %i6 = sitofp i32 %i5 to float51  %i7 = call float @llvm.fabs.f32(float %i6)52  %i8 = uitofp i1 %i4 to float53  %i9 = lshr i32 1, %i254  %i10 = select i1 %i4, i32 %i9, i32 055  %i11 = sitofp i32 %i10 to float56  %i12 = select i1 %i4, i32 %i1, i32 057  %i13 = sitofp i32 %i12 to float58  br label %bb1459 60bb14:61  %i15 = phi float [ 0.0, %bb ], [ %i19, %bb14 ]62  %i16 = fadd float %i15, %i863  %i17 = fadd float %i16, %i764  %i18 = fadd float %i17, %i1165  %i19 = fadd float %i18, %i1366  %i20 = icmp sgt i32 %arg, 067  br i1 %i20, label %bb14, label %bb2168 69bb21:70  store float %i15, ptr %ptr, align 471  ret void72}73 74declare float @llvm.fabs.f32(float)75;; NOTE: These prefixes are unused and the list is autogenerated. Do not add tests below this line:76; MIR: {{.*}}77