|
| 1 | +; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5 |
| 2 | +; RUN: llc -global-isel=0 -mtriple=amdgcn -mcpu=gfx1250 < %s | FileCheck -check-prefixes=GFX12,GFX12-SDAG %s |
| 3 | +; RUN: llc -global-isel=0 -mtriple=amdgcn -mcpu=gfx1250 < %s | FileCheck -check-prefixes=GFX12,GFX12-ISEL %s |
| 4 | + |
| 5 | +define amdgpu_kernel void @kernel1() #0 { |
| 6 | +; GFX12-LABEL: kernel1: |
| 7 | +; GFX12: ; %bb.0: |
| 8 | +; GFX12-NEXT: s_cmp_eq_u32 0, 0 |
| 9 | +; GFX12-NEXT: s_barrier_signal_isfirst -1 |
| 10 | +; GFX12-NEXT: s_barrier_wait -1 |
| 11 | +; GFX12-NEXT: s_cselect_b32 s0, -1, 0 |
| 12 | +; GFX12-NEXT: s_delay_alu instid0(SALU_CYCLE_1) |
| 13 | +; GFX12-NEXT: s_and_not1_b32 vcc_lo, exec_lo, s0 |
| 14 | +; GFX12-NEXT: s_cbranch_vccnz .LBB0_2 |
| 15 | +; GFX12-NEXT: ; %bb.1: |
| 16 | +; GFX12-NEXT: s_barrier_signal -3 |
| 17 | +; GFX12-NEXT: .LBB0_2: |
| 18 | +; GFX12-NEXT: s_barrier_wait -3 |
| 19 | +; GFX12-NEXT: s_get_barrier_state s0, -3 |
| 20 | +; GFX12-NEXT: s_endpgm |
| 21 | + call void @llvm.amdgcn.s.cluster.barrier() |
| 22 | + %state3 = call i32 @llvm.amdgcn.s.get.barrier.state(i32 -3) |
| 23 | + ret void |
| 24 | +} |
| 25 | + |
| 26 | +declare void @llvm.amdgcn.s.cluster.barrier() #1 |
| 27 | +declare i32 @llvm.amdgcn.s.get.barrier.state(i32) #1 |
| 28 | + |
| 29 | +attributes #0 = { nounwind } |
| 30 | +attributes #1 = { convergent nounwind } |
| 31 | +attributes #2 = { nounwind readnone } |
| 32 | +;; NOTE: These prefixes are unused and the list is autogenerated. Do not add tests below this line: |
| 33 | +; GFX12-ISEL: {{.*}} |
| 34 | +; GFX12-SDAG: {{.*}} |
0 commit comments