xref: /aosp_15_r20/external/llvm/test/CodeGen/AMDGPU/infinite-loop.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=amdgcn -mcpu=SI -verify-machineinstrs < %s | FileCheck -check-prefix=SI %s
2*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=amdgcn -mcpu=tonga -verify-machineinstrs < %s | FileCheck -check-prefix=SI %s
3*9880d681SAndroid Build Coastguard Worker
4*9880d681SAndroid Build Coastguard Worker; SI-LABEL: {{^}}infinite_loop:
5*9880d681SAndroid Build Coastguard Worker; SI: v_mov_b32_e32 [[REG:v[0-9]+]], 0x3e7
6*9880d681SAndroid Build Coastguard Worker; SI: BB0_1:
7*9880d681SAndroid Build Coastguard Worker; SI: buffer_store_dword [[REG]]
8*9880d681SAndroid Build Coastguard Worker; SI: s_waitcnt vmcnt(0) expcnt(0)
9*9880d681SAndroid Build Coastguard Worker; SI: s_branch BB0_1
10*9880d681SAndroid Build Coastguard Workerdefine void @infinite_loop(i32 addrspace(1)* %out) {
11*9880d681SAndroid Build Coastguard Workerentry:
12*9880d681SAndroid Build Coastguard Worker  br label %for.body
13*9880d681SAndroid Build Coastguard Worker
14*9880d681SAndroid Build Coastguard Workerfor.body:                                         ; preds = %entry, %for.body
15*9880d681SAndroid Build Coastguard Worker  store i32 999, i32 addrspace(1)* %out, align 4
16*9880d681SAndroid Build Coastguard Worker  br label %for.body
17*9880d681SAndroid Build Coastguard Worker}
18*9880d681SAndroid Build Coastguard Worker
19