• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx700 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX700 --check-prefix=NOTES %s
2; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx802 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX802 --check-prefix=NOTES %s
3; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -filetype=obj -o - < %s | llvm-readobj -elf-output-style=GNU -notes | FileCheck --check-prefix=CHECK --check-prefix=GFX900 --check-prefix=NOTES %s
4
5%opencl.image1d_t = type opaque
6%opencl.image1d_array_t = type opaque
7%opencl.image1d_buffer_t = type opaque
8%opencl.image2d_t = type opaque
9%opencl.image2d_array_t = type opaque
10%opencl.image2d_array_depth_t = type opaque
11%opencl.image2d_array_msaa_t = type opaque
12%opencl.image2d_array_msaa_depth_t = type opaque
13%opencl.image2d_depth_t = type opaque
14%opencl.image2d_msaa_t = type opaque
15%opencl.image2d_msaa_depth_t = type opaque
16%opencl.image3d_t = type opaque
17
18; CHECK: ---
19; CHECK:  Version: [ 1, 0 ]
20
21; CHECK:  Kernels:
22; CHECK:    - Name:       test
23; CHECK:      SymbolName: 'test@kd'
24; CHECK:      Args:
25; CHECK:        - Name:      a
26; CHECK:          TypeName:  image1d_t
27; CHECK:          Size:      8
28; CHECK:          ValueKind: Image
29; CHECK:        - Name:      b
30; CHECK:          TypeName:  image1d_array_t
31; CHECK:          Size:      8
32; CHECK:          ValueKind: Image
33; CHECK:        - Name:      c
34; CHECK:          TypeName:  image1d_buffer_t
35; CHECK:          Size:      8
36; CHECK:          ValueKind: Image
37; CHECK:        - Name:      d
38; CHECK:          TypeName:  image2d_t
39; CHECK:          Size:      8
40; CHECK:          ValueKind: Image
41; CHECK:        - Name:      e
42; CHECK:          TypeName:  image2d_array_t
43; CHECK:          Size:      8
44; CHECK:          ValueKind: Image
45; CHECK:        - Name:      f
46; CHECK:          TypeName:  image2d_array_depth_t
47; CHECK:          Size:      8
48; CHECK:          ValueKind: Image
49; CHECK:        - Name:      g
50; CHECK:          TypeName:  image2d_array_msaa_t
51; CHECK:          Size:      8
52; CHECK:          ValueKind: Image
53; CHECK:        - Name:      h
54; CHECK:          TypeName:  image2d_array_msaa_depth_t
55; CHECK:          Size:      8
56; CHECK:          ValueKind: Image
57; CHECK:        - Name:      i
58; CHECK:          TypeName:  image2d_depth_t
59; CHECK:          Size:      8
60; CHECK:          ValueKind: Image
61; CHECK:        - Name:      j
62; CHECK:          TypeName:  image2d_msaa_t
63; CHECK:          Size:      8
64; CHECK:          ValueKind: Image
65; CHECK:        - Name:      k
66; CHECK:          TypeName:  image2d_msaa_depth_t
67; CHECK:          Size:      8
68; CHECK:          ValueKind: Image
69; CHECK:        - Name:      l
70; CHECK:          TypeName:  image3d_t
71; CHECK:          Size:      8
72; CHECK:          ValueKind: Image
73define amdgpu_kernel void @test(%opencl.image1d_t addrspace(1)* %a,
74                                %opencl.image1d_array_t addrspace(1)* %b,
75                                %opencl.image1d_buffer_t addrspace(1)* %c,
76                                %opencl.image2d_t addrspace(1)* %d,
77                                %opencl.image2d_array_t addrspace(1)* %e,
78                                %opencl.image2d_array_depth_t addrspace(1)* %f,
79                                %opencl.image2d_array_msaa_t addrspace(1)* %g,
80                                %opencl.image2d_array_msaa_depth_t addrspace(1)* %h,
81                                %opencl.image2d_depth_t addrspace(1)* %i,
82                                %opencl.image2d_msaa_t addrspace(1)* %j,
83                                %opencl.image2d_msaa_depth_t addrspace(1)* %k,
84                                %opencl.image3d_t addrspace(1)* %l)
85    !kernel_arg_type !1 !kernel_arg_base_type !1 {
86  ret void
87}
88
89!1 = !{!"image1d_t", !"image1d_array_t", !"image1d_buffer_t",
90       !"image2d_t", !"image2d_array_t", !"image2d_array_depth_t",
91       !"image2d_array_msaa_t", !"image2d_array_msaa_depth_t",
92       !"image2d_depth_t", !"image2d_msaa_t", !"image2d_msaa_depth_t",
93       !"image3d_t"}
94