145bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=redwood -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 245bb48eaSTom Stellard; RUN: FileCheck --check-prefix=BUG64 %s < %t 345bb48eaSTom Stellard 445bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=sumo -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 545bb48eaSTom Stellard; RUN: FileCheck --check-prefix=BUG64 %s < %t 645bb48eaSTom Stellard 745bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=barts -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 845bb48eaSTom Stellard; RUN: FileCheck --check-prefix=BUG64 %s < %t 945bb48eaSTom Stellard 1045bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=turks -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 1145bb48eaSTom Stellard; RUN: FileCheck --check-prefix=BUG64 %s < %t 1245bb48eaSTom Stellard 1345bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=caicos -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 1445bb48eaSTom Stellard; RUN: FileCheck --check-prefix=BUG64 %s < %t 1545bb48eaSTom Stellard 1645bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=cedar -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 1745bb48eaSTom Stellard; RUN: FileCheck --check-prefix=BUG32 %s < %t 1845bb48eaSTom Stellard 1945bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=juniper -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 2045bb48eaSTom Stellard; RUN: FileCheck --check-prefix=NOBUG %s < %t 2145bb48eaSTom Stellard 2245bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=cypress -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 2345bb48eaSTom Stellard; RUN: FileCheck --check-prefix=NOBUG %s < %t 2445bb48eaSTom Stellard 2545bb48eaSTom Stellard; RUN: llc -march=r600 -mcpu=cayman -debug-only=r600cf %s -o - 2>%t | FileCheck %s --check-prefix=FUNC 2645bb48eaSTom Stellard; RUN: FileCheck --check-prefix=NOBUG %s < %t 2745bb48eaSTom Stellard 2845bb48eaSTom Stellard; REQUIRES: asserts 2945bb48eaSTom Stellard 3045bb48eaSTom Stellard; We are currently allocating 2 extra sub-entries on Evergreen / NI for 3145bb48eaSTom Stellard; non-WQM push instructions if we change this to 1, then we will need to 3245bb48eaSTom Stellard; add one level of depth to each of these tests. 3345bb48eaSTom Stellard 3445bb48eaSTom Stellard; BUG64-NOT: Applying bug work-around 3545bb48eaSTom Stellard; BUG32-NOT: Applying bug work-around 3645bb48eaSTom Stellard; NOBUG-NOT: Applying bug work-around 3745bb48eaSTom Stellard; FUNC-LABEL: {{^}}nested3: 38*3dbeefa9SMatt Arsenaultdefine amdgpu_kernel void @nested3(i32 addrspace(1)* %out, i32 %cond) { 3945bb48eaSTom Stellardentry: 4045bb48eaSTom Stellard %0 = icmp sgt i32 %cond, 0 4145bb48eaSTom Stellard br i1 %0, label %if.1, label %end 4245bb48eaSTom Stellard 4345bb48eaSTom Stellardif.1: 4445bb48eaSTom Stellard %1 = icmp sgt i32 %cond, 10 4545bb48eaSTom Stellard br i1 %1, label %if.2, label %if.store.1 4645bb48eaSTom Stellard 4745bb48eaSTom Stellardif.store.1: 4845bb48eaSTom Stellard store i32 1, i32 addrspace(1)* %out 4945bb48eaSTom Stellard br label %end 5045bb48eaSTom Stellard 5145bb48eaSTom Stellardif.2: 5245bb48eaSTom Stellard %2 = icmp sgt i32 %cond, 20 5345bb48eaSTom Stellard br i1 %2, label %if.3, label %if.2.store 5445bb48eaSTom Stellard 5545bb48eaSTom Stellardif.2.store: 5645bb48eaSTom Stellard store i32 2, i32 addrspace(1)* %out 5745bb48eaSTom Stellard br label %end 5845bb48eaSTom Stellard 5945bb48eaSTom Stellardif.3: 6045bb48eaSTom Stellard store i32 3, i32 addrspace(1)* %out 6145bb48eaSTom Stellard br label %end 6245bb48eaSTom Stellard 6345bb48eaSTom Stellardend: 6445bb48eaSTom Stellard ret void 6545bb48eaSTom Stellard} 6645bb48eaSTom Stellard 6745bb48eaSTom Stellard; BUG64: Applying bug work-around 6845bb48eaSTom Stellard; BUG32-NOT: Applying bug work-around 6945bb48eaSTom Stellard; NOBUG-NOT: Applying bug work-around 7045bb48eaSTom Stellard; FUNC-LABEL: {{^}}nested4: 71*3dbeefa9SMatt Arsenaultdefine amdgpu_kernel void @nested4(i32 addrspace(1)* %out, i32 %cond) { 7245bb48eaSTom Stellardentry: 7345bb48eaSTom Stellard %0 = icmp sgt i32 %cond, 0 7445bb48eaSTom Stellard br i1 %0, label %if.1, label %end 7545bb48eaSTom Stellard 7645bb48eaSTom Stellardif.1: 7745bb48eaSTom Stellard %1 = icmp sgt i32 %cond, 10 7845bb48eaSTom Stellard br i1 %1, label %if.2, label %if.1.store 7945bb48eaSTom Stellard 8045bb48eaSTom Stellardif.1.store: 8145bb48eaSTom Stellard store i32 1, i32 addrspace(1)* %out 8245bb48eaSTom Stellard br label %end 8345bb48eaSTom Stellard 8445bb48eaSTom Stellardif.2: 8545bb48eaSTom Stellard %2 = icmp sgt i32 %cond, 20 8645bb48eaSTom Stellard br i1 %2, label %if.3, label %if.2.store 8745bb48eaSTom Stellard 8845bb48eaSTom Stellardif.2.store: 8945bb48eaSTom Stellard store i32 2, i32 addrspace(1)* %out 9045bb48eaSTom Stellard br label %end 9145bb48eaSTom Stellard 9245bb48eaSTom Stellardif.3: 9345bb48eaSTom Stellard %3 = icmp sgt i32 %cond, 30 9445bb48eaSTom Stellard br i1 %3, label %if.4, label %if.3.store 9545bb48eaSTom Stellard 9645bb48eaSTom Stellardif.3.store: 9745bb48eaSTom Stellard store i32 3, i32 addrspace(1)* %out 9845bb48eaSTom Stellard br label %end 9945bb48eaSTom Stellard 10045bb48eaSTom Stellardif.4: 10145bb48eaSTom Stellard store i32 4, i32 addrspace(1)* %out 10245bb48eaSTom Stellard br label %end 10345bb48eaSTom Stellard 10445bb48eaSTom Stellardend: 10545bb48eaSTom Stellard ret void 10645bb48eaSTom Stellard} 10745bb48eaSTom Stellard 10845bb48eaSTom Stellard; BUG64: Applying bug work-around 10945bb48eaSTom Stellard; BUG32-NOT: Applying bug work-around 11045bb48eaSTom Stellard; NOBUG-NOT: Applying bug work-around 11145bb48eaSTom Stellard; FUNC-LABEL: {{^}}nested7: 112*3dbeefa9SMatt Arsenaultdefine amdgpu_kernel void @nested7(i32 addrspace(1)* %out, i32 %cond) { 11345bb48eaSTom Stellardentry: 11445bb48eaSTom Stellard %0 = icmp sgt i32 %cond, 0 11545bb48eaSTom Stellard br i1 %0, label %if.1, label %end 11645bb48eaSTom Stellard 11745bb48eaSTom Stellardif.1: 11845bb48eaSTom Stellard %1 = icmp sgt i32 %cond, 10 11945bb48eaSTom Stellard br i1 %1, label %if.2, label %if.1.store 12045bb48eaSTom Stellard 12145bb48eaSTom Stellardif.1.store: 12245bb48eaSTom Stellard store i32 1, i32 addrspace(1)* %out 12345bb48eaSTom Stellard br label %end 12445bb48eaSTom Stellard 12545bb48eaSTom Stellardif.2: 12645bb48eaSTom Stellard %2 = icmp sgt i32 %cond, 20 12745bb48eaSTom Stellard br i1 %2, label %if.3, label %if.2.store 12845bb48eaSTom Stellard 12945bb48eaSTom Stellardif.2.store: 13045bb48eaSTom Stellard store i32 2, i32 addrspace(1)* %out 13145bb48eaSTom Stellard br label %end 13245bb48eaSTom Stellard 13345bb48eaSTom Stellardif.3: 13445bb48eaSTom Stellard %3 = icmp sgt i32 %cond, 30 13545bb48eaSTom Stellard br i1 %3, label %if.4, label %if.3.store 13645bb48eaSTom Stellard 13745bb48eaSTom Stellardif.3.store: 13845bb48eaSTom Stellard store i32 3, i32 addrspace(1)* %out 13945bb48eaSTom Stellard br label %end 14045bb48eaSTom Stellard 14145bb48eaSTom Stellardif.4: 14245bb48eaSTom Stellard %4 = icmp sgt i32 %cond, 40 14345bb48eaSTom Stellard br i1 %4, label %if.5, label %if.4.store 14445bb48eaSTom Stellard 14545bb48eaSTom Stellardif.4.store: 14645bb48eaSTom Stellard store i32 4, i32 addrspace(1)* %out 14745bb48eaSTom Stellard br label %end 14845bb48eaSTom Stellard 14945bb48eaSTom Stellardif.5: 15045bb48eaSTom Stellard %5 = icmp sgt i32 %cond, 50 15145bb48eaSTom Stellard br i1 %5, label %if.6, label %if.5.store 15245bb48eaSTom Stellard 15345bb48eaSTom Stellardif.5.store: 15445bb48eaSTom Stellard store i32 5, i32 addrspace(1)* %out 15545bb48eaSTom Stellard br label %end 15645bb48eaSTom Stellard 15745bb48eaSTom Stellardif.6: 15845bb48eaSTom Stellard %6 = icmp sgt i32 %cond, 60 15945bb48eaSTom Stellard br i1 %6, label %if.7, label %if.6.store 16045bb48eaSTom Stellard 16145bb48eaSTom Stellardif.6.store: 16245bb48eaSTom Stellard store i32 6, i32 addrspace(1)* %out 16345bb48eaSTom Stellard br label %end 16445bb48eaSTom Stellard 16545bb48eaSTom Stellardif.7: 16645bb48eaSTom Stellard store i32 7, i32 addrspace(1)* %out 16745bb48eaSTom Stellard br label %end 16845bb48eaSTom Stellard 16945bb48eaSTom Stellardend: 17045bb48eaSTom Stellard ret void 17145bb48eaSTom Stellard} 17245bb48eaSTom Stellard 17345bb48eaSTom Stellard; BUG64: Applying bug work-around 17445bb48eaSTom Stellard; BUG32: Applying bug work-around 17545bb48eaSTom Stellard; NOBUG-NOT: Applying bug work-around 17645bb48eaSTom Stellard; FUNC-LABEL: {{^}}nested8: 177*3dbeefa9SMatt Arsenaultdefine amdgpu_kernel void @nested8(i32 addrspace(1)* %out, i32 %cond) { 17845bb48eaSTom Stellardentry: 17945bb48eaSTom Stellard %0 = icmp sgt i32 %cond, 0 18045bb48eaSTom Stellard br i1 %0, label %if.1, label %end 18145bb48eaSTom Stellard 18245bb48eaSTom Stellardif.1: 18345bb48eaSTom Stellard %1 = icmp sgt i32 %cond, 10 18445bb48eaSTom Stellard br i1 %1, label %if.2, label %if.1.store 18545bb48eaSTom Stellard 18645bb48eaSTom Stellardif.1.store: 18745bb48eaSTom Stellard store i32 1, i32 addrspace(1)* %out 18845bb48eaSTom Stellard br label %end 18945bb48eaSTom Stellard 19045bb48eaSTom Stellardif.2: 19145bb48eaSTom Stellard %2 = icmp sgt i32 %cond, 20 19245bb48eaSTom Stellard br i1 %2, label %if.3, label %if.2.store 19345bb48eaSTom Stellard 19445bb48eaSTom Stellardif.2.store: 19545bb48eaSTom Stellard store i32 2, i32 addrspace(1)* %out 19645bb48eaSTom Stellard br label %end 19745bb48eaSTom Stellard 19845bb48eaSTom Stellardif.3: 19945bb48eaSTom Stellard %3 = icmp sgt i32 %cond, 30 20045bb48eaSTom Stellard br i1 %3, label %if.4, label %if.3.store 20145bb48eaSTom Stellard 20245bb48eaSTom Stellardif.3.store: 20345bb48eaSTom Stellard store i32 3, i32 addrspace(1)* %out 20445bb48eaSTom Stellard br label %end 20545bb48eaSTom Stellard 20645bb48eaSTom Stellardif.4: 20745bb48eaSTom Stellard %4 = icmp sgt i32 %cond, 40 20845bb48eaSTom Stellard br i1 %4, label %if.5, label %if.4.store 20945bb48eaSTom Stellard 21045bb48eaSTom Stellardif.4.store: 21145bb48eaSTom Stellard store i32 4, i32 addrspace(1)* %out 21245bb48eaSTom Stellard br label %end 21345bb48eaSTom Stellard 21445bb48eaSTom Stellardif.5: 21545bb48eaSTom Stellard %5 = icmp sgt i32 %cond, 50 21645bb48eaSTom Stellard br i1 %5, label %if.6, label %if.5.store 21745bb48eaSTom Stellard 21845bb48eaSTom Stellardif.5.store: 21945bb48eaSTom Stellard store i32 5, i32 addrspace(1)* %out 22045bb48eaSTom Stellard br label %end 22145bb48eaSTom Stellard 22245bb48eaSTom Stellardif.6: 22345bb48eaSTom Stellard %6 = icmp sgt i32 %cond, 60 22445bb48eaSTom Stellard br i1 %6, label %if.7, label %if.6.store 22545bb48eaSTom Stellard 22645bb48eaSTom Stellardif.6.store: 22745bb48eaSTom Stellard store i32 6, i32 addrspace(1)* %out 22845bb48eaSTom Stellard br label %end 22945bb48eaSTom Stellard 23045bb48eaSTom Stellardif.7: 23145bb48eaSTom Stellard %7 = icmp sgt i32 %cond, 70 23245bb48eaSTom Stellard br i1 %7, label %if.8, label %if.7.store 23345bb48eaSTom Stellard 23445bb48eaSTom Stellardif.7.store: 23545bb48eaSTom Stellard store i32 7, i32 addrspace(1)* %out 23645bb48eaSTom Stellard br label %end 23745bb48eaSTom Stellard 23845bb48eaSTom Stellardif.8: 23945bb48eaSTom Stellard store i32 8, i32 addrspace(1)* %out 24045bb48eaSTom Stellard br label %end 24145bb48eaSTom Stellard 24245bb48eaSTom Stellardend: 24345bb48eaSTom Stellard ret void 24445bb48eaSTom Stellard} 245