• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: opt %s -mtriple amdgcn-- -analyze -divergence -use-gpu-divergence-analysis | FileCheck %s
2
3; CHECK-LABEL: Printing analysis 'Legacy Divergence Analysis' for function 'test_amdgpu_ps':
4; CHECK: DIVERGENT:  [4 x <16 x i8>] addrspace(4)* %arg0
5; CHECK-NOT: DIVERGENT
6; CHECK: DIVERGENT:  <2 x i32> %arg3
7; CHECK: DIVERGENT:  <3 x i32> %arg4
8; CHECK: DIVERGENT:  float %arg5
9; CHECK: DIVERGENT:  i32 %arg6
10
11define amdgpu_ps void @test_amdgpu_ps([4 x <16 x i8>] addrspace(4)* byref([4 x <16 x i8>]) %arg0, float inreg %arg1, i32 inreg %arg2, <2 x i32> %arg3, <3 x i32> %arg4, float %arg5, i32 %arg6) #0 {
12  ret void
13}
14
15; CHECK-LABEL: Printing analysis 'Legacy Divergence Analysis' for function 'test_amdgpu_kernel':
16; CHECK-NOT: %arg0
17; CHECK-NOT: %arg1
18; CHECK-NOT: %arg2
19; CHECK-NOT: %arg3
20; CHECK-NOT: %arg4
21; CHECK-NOT: %arg5
22; CHECK-NOT: %arg6
23define amdgpu_kernel void @test_amdgpu_kernel([4 x <16 x i8>] addrspace(4)* byref([4 x <16 x i8>]) %arg0, float inreg %arg1, i32 inreg %arg2, <2 x i32> %arg3, <3 x i32> %arg4, float %arg5, i32 %arg6) #0 {
24  ret void
25}
26
27; CHECK-LABEL: Printing analysis 'Legacy Divergence Analysis' for function 'test_c':
28; CHECK: DIVERGENT:
29; CHECK: DIVERGENT:
30; CHECK: DIVERGENT:
31; CHECK: DIVERGENT:
32; CHECK: DIVERGENT:
33; CHECK: DIVERGENT:
34; CHECK: DIVERGENT:
35define void @test_c([4 x <16 x i8>] addrspace(5)* byval([4 x <16 x i8>]) %arg0, float inreg %arg1, i32 inreg %arg2, <2 x i32> %arg3, <3 x i32> %arg4, float %arg5, i32 %arg6) #0 {
36  ret void
37}
38
39attributes #0 = { nounwind }
40