1 ; RUN: llc -march=amdgcn -O0 -o - %s | FileCheck %s
3 ; CHECK-LABEL: non_uniform_loop
5 define amdgpu_kernel void @non_uniform_loop(float addrspace(1)* %array) {
7 %w = tail call i32 @llvm.amdgcn.workitem.id.x()
11 %i = phi i32 [0, %entry], [%i.next, %for.inc]
12 %cmp = icmp ult i32 %i, %w
13 br i1 %cmp, label %for.body, label %for.end
19 %i.next = add i32 %i, 1
26 declare i32 @llvm.amdgcn.workitem.id.x()