xref: /aosp_15_r20/external/OpenCL-CTS/test_conformance/gl/procs.h (revision 6467f958c7de8070b317fc65bcb0f6472e388d82)
1 //
2 // Copyright (c) 2017 The Khronos Group Inc.
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 //    http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //
16 #include "testBase.h"
17 #include "harness/mt19937.h"
18 
19 
20 #pragma mark -
21 #pragma Misc tests
22 
23 extern int test_buffers(cl_device_id device, cl_context context,
24                         cl_command_queue queue, int num_elements);
25 
26 extern int test_fence_sync(cl_device_id device, cl_context context,
27                            cl_command_queue queue, int numElements);
28 
29 
30 #pragma mark -
31 #pragma mark Tead tests
32 
33 extern int test_images_read_2D(cl_device_id device, cl_context context,
34                                cl_command_queue queue, int num_elements);
35 
36 extern int test_images_read_1D(cl_device_id device, cl_context context,
37                                cl_command_queue queue, int num_elements);
38 
39 extern int test_images_read_texturebuffer(cl_device_id device,
40                                           cl_context context,
41                                           cl_command_queue queue,
42                                           int num_elements);
43 
44 extern int test_images_read_1Darray(cl_device_id device, cl_context context,
45                                     cl_command_queue queue, int num_elements);
46 
47 extern int test_images_read_2Darray(cl_device_id device, cl_context context,
48                                     cl_command_queue queue, int num_elements);
49 
50 extern int test_images_read_cube(cl_device_id device, cl_context context,
51                                  cl_command_queue queue, int num_elements);
52 
53 extern int test_images_read_3D(cl_device_id device, cl_context context,
54                                cl_command_queue queue, int num_elements);
55 
56 extern int test_renderbuffer_read(cl_device_id device, cl_context context,
57                                   cl_command_queue queue, int num_elements);
58 
59 #pragma mark -
60 #pragma mark Write tests
61 
62 // 2D tests are the ones with no suffix:
63 
64 extern int test_images_write(cl_device_id device, cl_context context,
65                              cl_command_queue queue, int num_elements);
66 
67 extern int test_images_write_cube(cl_device_id device, cl_context context,
68                                   cl_command_queue queue, int num_elements);
69 
70 extern int test_renderbuffer_write(cl_device_id device, cl_context context,
71                                    cl_command_queue queue, int num_elements);
72 
73 // Here are the rest:
74 
75 extern int test_images_write_1D(cl_device_id device, cl_context context,
76                                 cl_command_queue queue, int num_elements);
77 
78 extern int test_images_write_texturebuffer(cl_device_id device,
79                                            cl_context context,
80                                            cl_command_queue queue,
81                                            int num_elements);
82 
83 extern int test_images_write_1Darray(cl_device_id device, cl_context context,
84                                      cl_command_queue queue, int num_elements);
85 
86 extern int test_images_write_2Darray(cl_device_id device, cl_context context,
87                                      cl_command_queue queue, int num_elements);
88 
89 extern int test_images_write_3D(cl_device_id device, cl_context context,
90                                 cl_command_queue queue, int num_elements);
91 
92 #pragma mark -
93 #pragma mark Get info test entry points
94 
95 extern int test_buffers_getinfo(cl_device_id device, cl_context context,
96                                 cl_command_queue queue, int numElements);
97 
98 extern int test_images_1D_getinfo(cl_device_id device, cl_context context,
99                                   cl_command_queue queue, int numElements);
100 
101 extern int test_images_texturebuffer_getinfo(cl_device_id device,
102                                              cl_context context,
103                                              cl_command_queue queue,
104                                              int numElements);
105 
106 extern int test_images_1Darray_getinfo(cl_device_id device, cl_context context,
107                                        cl_command_queue queue, int numElements);
108 
109 extern int test_images_2D_getinfo(cl_device_id device, cl_context context,
110                                   cl_command_queue queue, int numElements);
111 
112 extern int test_images_2Darray_getinfo(cl_device_id device, cl_context context,
113                                        cl_command_queue queue, int numElements);
114 
115 extern int test_images_cube_getinfo(cl_device_id device, cl_context context,
116                                     cl_command_queue queue, int numElements);
117 
118 extern int test_images_3D_getinfo(cl_device_id device, cl_context context,
119                                   cl_command_queue queue, int numElements);
120 
121 extern int test_images_read_2D_depth(cl_device_id device, cl_context context,
122                                      cl_command_queue queue, int numElements);
123 
124 extern int test_images_write_2D_depth(cl_device_id device, cl_context context,
125                                       cl_command_queue queue, int numElements);
126 
127 extern int test_images_read_2Darray_depth(cl_device_id device,
128                                           cl_context context,
129                                           cl_command_queue queue, int);
130 
131 extern int test_images_write_2Darray_depth(cl_device_id device,
132                                            cl_context context,
133                                            cl_command_queue queue,
134                                            int numElements);
135 
136 extern int test_images_read_2D_multisample(cl_device_id device,
137                                            cl_context context,
138                                            cl_command_queue queue,
139                                            int numElements);
140 
141 extern int test_images_read_2Darray_multisample(cl_device_id device,
142                                                 cl_context context,
143                                                 cl_command_queue queue, int);
144 
145 extern int test_image_methods_depth(cl_device_id device, cl_context context,
146                                     cl_command_queue queue, int);
147 
148 extern int test_image_methods_multisample(cl_device_id device,
149                                           cl_context context,
150                                           cl_command_queue queue, int);
151 
152 extern int test_renderbuffer_getinfo(cl_device_id device, cl_context context,
153                                      cl_command_queue queue, int numElements);