1 | //===--- OMPKinds.def - OpenMP directives, clauses, rt-calls -*- C++ -*-===// |
2 | // |
3 | // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. |
4 | // See https://llvm.org/LICENSE.txt for license information. |
5 | // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception |
6 | // |
7 | //===----------------------------------------------------------------------===// |
8 | /// \file |
9 | /// |
10 | /// This file defines the list of supported OpenMP runtime |
11 | /// calls, and other things that need to be listed in enums. |
12 | /// |
13 | /// This file is under transition to OMP.td with TableGen code generation. |
14 | /// |
15 | //===----------------------------------------------------------------------===// |
16 | |
17 | /// OpenMP Directives, combined directives and Clauses |
18 | /// - Moved to OMP.td |
19 | |
20 | /// Types used in runtime structs or runtime functions |
21 | /// |
22 | ///{ |
23 | |
24 | #ifndef OMP_TYPE |
25 | #define OMP_TYPE(VarName, InitValue) |
26 | #endif |
27 | |
28 | #define __OMP_TYPE(VarName) OMP_TYPE(VarName, Type::get##VarName##Ty(Ctx)) |
29 | |
30 | __OMP_TYPE(Void) |
31 | __OMP_TYPE(Int1) |
32 | __OMP_TYPE(Int8) |
33 | __OMP_TYPE(Int16) |
34 | __OMP_TYPE(Int32) |
35 | __OMP_TYPE(Int64) |
36 | __OMP_TYPE(Int8Ptr) |
37 | __OMP_TYPE(Int16Ptr) |
38 | __OMP_TYPE(Int32Ptr) |
39 | __OMP_TYPE(Int64Ptr) |
40 | __OMP_TYPE(Double) |
41 | |
42 | OMP_TYPE(SizeTy, M.getDataLayout().getIntPtrType(Ctx)) |
43 | OMP_TYPE(Int63, Type::getIntNTy(Ctx, 63)) |
44 | |
45 | #define __OMP_PTR_TYPE(NAME, BASE) OMP_TYPE(NAME, BASE->getPointerTo()) |
46 | |
47 | __OMP_PTR_TYPE(VoidPtr, Int8) |
48 | __OMP_PTR_TYPE(VoidPtrPtr, VoidPtr) |
49 | __OMP_PTR_TYPE(VoidPtrPtrPtr, VoidPtrPtr) |
50 | |
51 | __OMP_PTR_TYPE(Int8PtrPtr, Int8Ptr) |
52 | __OMP_PTR_TYPE(Int8PtrPtrPtr, Int8PtrPtr) |
53 | |
54 | #undef __OMP_PTR_TYPE |
55 | |
56 | #undef __OMP_TYPE |
57 | #undef OMP_TYPE |
58 | |
59 | ///} |
60 | |
61 | /// array types |
62 | /// |
63 | ///{ |
64 | |
65 | #ifndef OMP_ARRAY_TYPE |
66 | #define OMP_ARRAY_TYPE(VarName, ElemTy, ArraySize) |
67 | #endif |
68 | |
69 | #define __OMP_ARRAY_TYPE(VarName, ElemTy, ArraySize) \ |
70 | OMP_ARRAY_TYPE(VarName, ElemTy, ArraySize) |
71 | |
72 | __OMP_ARRAY_TYPE(KmpCriticalName, Int32, 8) |
73 | __OMP_ARRAY_TYPE(Int32Arr3, Int32, 3) |
74 | |
75 | #undef __OMP_ARRAY_TYPE |
76 | #undef OMP_ARRAY_TYPE |
77 | |
78 | ///} |
79 | |
80 | /// Struct and function types |
81 | /// |
82 | ///{ |
83 | |
84 | #ifndef OMP_STRUCT_TYPE |
85 | #define OMP_STRUCT_TYPE(VarName, StructName, Packed, ...) |
86 | #endif |
87 | |
88 | #define __OMP_STRUCT_TYPE(VarName, Name, Packed, ...) \ |
89 | OMP_STRUCT_TYPE(VarName, "struct." #Name, Packed, __VA_ARGS__) |
90 | |
91 | __OMP_STRUCT_TYPE(Ident, ident_t, false, Int32, Int32, Int32, Int32, Int8Ptr) |
92 | __OMP_STRUCT_TYPE(OffloadEntry, __tgt_offload_entry, false, Int8Ptr, Int8Ptr, SizeTy, |
93 | Int32, Int32) |
94 | __OMP_STRUCT_TYPE(KernelArgs, __tgt_kernel_arguments, false, Int32, Int32, VoidPtrPtr, |
95 | VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr, |
96 | Int64, Int64, Int32Arr3Ty, Int32Arr3Ty, Int32) |
97 | __OMP_STRUCT_TYPE(AsyncInfo, __tgt_async_info, false, Int8Ptr) |
98 | __OMP_STRUCT_TYPE(DependInfo, kmp_dep_info, false, SizeTy, SizeTy, Int8) |
99 | |
100 | #undef __OMP_STRUCT_TYPE |
101 | #undef OMP_STRUCT_TYPE |
102 | |
103 | #ifndef OMP_FUNCTION_TYPE |
104 | #define OMP_FUNCTION_TYPE(VarName, IsVarArg, ReturnType, ...) |
105 | #endif |
106 | |
107 | #define __OMP_FUNCTION_TYPE(VarName, IsVarArg, ReturnType, ...) \ |
108 | OMP_FUNCTION_TYPE(VarName, IsVarArg, ReturnType, __VA_ARGS__) |
109 | |
110 | __OMP_FUNCTION_TYPE(ParallelTask, true, Void, Int32Ptr, Int32Ptr) |
111 | __OMP_FUNCTION_TYPE(ReduceFunction, false, Void, VoidPtr, VoidPtr) |
112 | __OMP_FUNCTION_TYPE(CopyFunction, false, Void, VoidPtr, VoidPtr) |
113 | __OMP_FUNCTION_TYPE(KmpcCtor, false, VoidPtr, VoidPtr) |
114 | __OMP_FUNCTION_TYPE(KmpcDtor, false, Void, VoidPtr) |
115 | __OMP_FUNCTION_TYPE(KmpcCopyCtor, false, VoidPtr, VoidPtr, VoidPtr) |
116 | __OMP_FUNCTION_TYPE(TaskRoutineEntry, false, Int32, Int32, |
117 | /* kmp_task_t */ VoidPtr) |
118 | __OMP_FUNCTION_TYPE(ShuffleReduce, false, Void, VoidPtr, Int16, Int16, Int16) |
119 | __OMP_FUNCTION_TYPE(InterWarpCopy, false, Void, VoidPtr, Int32) |
120 | __OMP_FUNCTION_TYPE(GlobalList, false, Void, VoidPtr, Int32, VoidPtr) |
121 | |
122 | #undef __OMP_FUNCTION_TYPE |
123 | #undef OMP_FUNCTION_TYPE |
124 | |
125 | ///} |
126 | |
127 | /// Internal Control Variables information |
128 | /// |
129 | ///{ |
130 | |
131 | #ifndef ICV_INIT_VALUE |
132 | #define ICV_INIT_VALUE(Enum, Name) |
133 | #endif |
134 | |
135 | #define __ICV_INIT_VALUE(Name) ICV_INIT_VALUE(ICV_##Name, #Name) |
136 | |
137 | __ICV_INIT_VALUE(ZERO) |
138 | __ICV_INIT_VALUE(FALSE) |
139 | __ICV_INIT_VALUE(IMPLEMENTATION_DEFINED) |
140 | __ICV_INIT_VALUE(LAST) |
141 | |
142 | #undef __ICV_INIT_VALUE |
143 | #undef ICV_INIT_VALUE |
144 | |
145 | #ifndef ICV_DATA_ENV |
146 | #define ICV_DATA_ENV(Enum, Name, EnvVarName, Init) |
147 | #endif |
148 | |
149 | #define __ICV_DATA_ENV(Name, EnvVarName, Init) \ |
150 | ICV_DATA_ENV(ICV_##Name, #Name, #EnvVarName, Init) |
151 | |
152 | __ICV_DATA_ENV(nthreads, OMP_NUM_THREADS, ICV_IMPLEMENTATION_DEFINED) |
153 | __ICV_DATA_ENV(active_levels, NONE, ICV_ZERO) |
154 | __ICV_DATA_ENV(cancel, OMP_CANCELLATION, ICV_FALSE) |
155 | __ICV_DATA_ENV(proc_bind, OMP_PROC_BIND, ICV_IMPLEMENTATION_DEFINED) |
156 | __ICV_DATA_ENV(__last, last, ICV_LAST) |
157 | |
158 | #undef __ICV_DATA_ENV |
159 | #undef ICV_DATA_ENV |
160 | |
161 | #ifndef ICV_RT_SET |
162 | #define ICV_RT_SET(Name, RTL) |
163 | #endif |
164 | |
165 | #define __ICV_RT_SET(Name, RTL) ICV_RT_SET(ICV_##Name, OMPRTL_##RTL) |
166 | |
167 | __ICV_RT_SET(nthreads, omp_set_num_threads) |
168 | |
169 | #undef __ICV_RT_SET |
170 | #undef ICV_RT_SET |
171 | |
172 | #ifndef ICV_RT_GET |
173 | #define ICV_RT_GET(Name, RTL) |
174 | #endif |
175 | |
176 | #define __ICV_RT_GET(Name, RTL) ICV_RT_GET(ICV_##Name, OMPRTL_##RTL) |
177 | |
178 | __ICV_RT_GET(nthreads, omp_get_max_threads) |
179 | __ICV_RT_GET(active_levels, omp_get_active_level) |
180 | __ICV_RT_GET(cancel, omp_get_cancellation) |
181 | __ICV_RT_GET(proc_bind, omp_get_proc_bind) |
182 | |
183 | #undef __ICV_RT_GET |
184 | #undef ICV_RT_GET |
185 | |
186 | ///} |
187 | |
188 | /// Runtime library function (and their attributes) |
189 | /// |
190 | ///{ |
191 | |
192 | #ifndef OMP_RTL |
193 | #define OMP_RTL(Enum, Str, IsVarArg, ReturnType, ...) |
194 | #endif |
195 | |
196 | #define __OMP_RTL(Name, IsVarArg, ReturnType, ...) \ |
197 | OMP_RTL(OMPRTL_##Name, #Name, IsVarArg, ReturnType, __VA_ARGS__) |
198 | |
199 | |
200 | |
201 | __OMP_RTL(__kmpc_barrier, false, Void, IdentPtr, Int32) |
202 | __OMP_RTL(__kmpc_cancel, false, Int32, IdentPtr, Int32, Int32) |
203 | __OMP_RTL(__kmpc_cancel_barrier, false, Int32, IdentPtr, Int32) |
204 | __OMP_RTL(__kmpc_error, false, Void, IdentPtr, Int32, Int8Ptr) |
205 | __OMP_RTL(__kmpc_flush, false, Void, IdentPtr) |
206 | __OMP_RTL(__kmpc_global_thread_num, false, Int32, IdentPtr) |
207 | __OMP_RTL(__kmpc_get_hardware_thread_id_in_block, false, Int32, ) |
208 | __OMP_RTL(__kmpc_fork_call, true, Void, IdentPtr, Int32, ParallelTaskPtr) |
209 | __OMP_RTL(__kmpc_fork_call_if, false, Void, IdentPtr, Int32, ParallelTaskPtr, |
210 | Int32, VoidPtr) |
211 | __OMP_RTL(__kmpc_omp_taskwait, false, Int32, IdentPtr, Int32) |
212 | __OMP_RTL(__kmpc_omp_taskyield, false, Int32, IdentPtr, Int32, /* Int */ Int32) |
213 | __OMP_RTL(__kmpc_push_num_threads, false, Void, IdentPtr, Int32, |
214 | /* Int */ Int32) |
215 | __OMP_RTL(__kmpc_push_proc_bind, false, Void, IdentPtr, Int32, /* Int */ Int32) |
216 | __OMP_RTL(__kmpc_omp_reg_task_with_affinity, false, Int32, IdentPtr, Int32, |
217 | /* kmp_task_t */ VoidPtr, Int32, |
218 | /* kmp_task_affinity_info_t */ VoidPtr) |
219 | |
220 | __OMP_RTL(__kmpc_get_hardware_num_blocks, false, Int32, ) |
221 | __OMP_RTL(__kmpc_get_hardware_num_threads_in_block, false, Int32, ) |
222 | __OMP_RTL(__kmpc_get_warp_size, false, Int32, ) |
223 | |
224 | __OMP_RTL(omp_get_thread_num, false, Int32, ) |
225 | __OMP_RTL(omp_get_num_threads, false, Int32, ) |
226 | __OMP_RTL(omp_get_max_threads, false, Int32, ) |
227 | __OMP_RTL(omp_in_parallel, false, Int32, ) |
228 | __OMP_RTL(omp_get_dynamic, false, Int32, ) |
229 | __OMP_RTL(omp_get_cancellation, false, Int32, ) |
230 | __OMP_RTL(omp_get_nested, false, Int32, ) |
231 | __OMP_RTL(omp_get_schedule, false, Void, Int32Ptr, Int32Ptr) |
232 | __OMP_RTL(omp_get_thread_limit, false, Int32, ) |
233 | __OMP_RTL(omp_get_supported_active_levels, false, Int32, ) |
234 | __OMP_RTL(omp_get_max_active_levels, false, Int32, ) |
235 | __OMP_RTL(omp_get_level, false, Int32, ) |
236 | __OMP_RTL(omp_get_ancestor_thread_num, false, Int32, Int32) |
237 | __OMP_RTL(omp_get_team_size, false, Int32, Int32) |
238 | __OMP_RTL(omp_get_active_level, false, Int32, ) |
239 | __OMP_RTL(omp_in_final, false, Int32, ) |
240 | __OMP_RTL(omp_get_proc_bind, false, Int32, ) |
241 | __OMP_RTL(omp_get_num_places, false, Int32, ) |
242 | __OMP_RTL(omp_get_num_procs, false, Int32, ) |
243 | __OMP_RTL(omp_get_place_proc_ids, false, Void, Int32, Int32Ptr) |
244 | __OMP_RTL(omp_get_place_num, false, Int32, ) |
245 | __OMP_RTL(omp_get_partition_num_places, false, Int32, ) |
246 | __OMP_RTL(omp_get_partition_place_nums, false, Void, Int32Ptr) |
247 | __OMP_RTL(omp_get_wtime, false, Double,) |
248 | |
249 | __OMP_RTL(omp_set_num_threads, false, Void, Int32) |
250 | __OMP_RTL(omp_set_dynamic, false, Void, Int32) |
251 | __OMP_RTL(omp_set_nested, false, Void, Int32) |
252 | __OMP_RTL(omp_set_schedule, false, Void, Int32, Int32) |
253 | __OMP_RTL(omp_set_max_active_levels, false, Void, Int32) |
254 | |
255 | __OMP_RTL(__kmpc_master, false, Int32, IdentPtr, Int32) |
256 | __OMP_RTL(__kmpc_end_master, false, Void, IdentPtr, Int32) |
257 | __OMP_RTL(__kmpc_masked, false, Int32, IdentPtr, Int32, Int32) |
258 | __OMP_RTL(__kmpc_end_masked, false, Void, IdentPtr, Int32) |
259 | __OMP_RTL(__kmpc_critical, false, Void, IdentPtr, Int32, KmpCriticalNamePtrTy) |
260 | __OMP_RTL(__kmpc_critical_with_hint, false, Void, IdentPtr, Int32, |
261 | KmpCriticalNamePtrTy, Int32) |
262 | __OMP_RTL(__kmpc_end_critical, false, Void, IdentPtr, Int32, |
263 | KmpCriticalNamePtrTy) |
264 | |
265 | __OMP_RTL(__kmpc_begin, false, Void, IdentPtr, Int32) |
266 | __OMP_RTL(__kmpc_end, false, Void, IdentPtr) |
267 | |
268 | __OMP_RTL(__kmpc_reduce, false, Int32, IdentPtr, Int32, Int32, SizeTy, VoidPtr, |
269 | ReduceFunctionPtr, KmpCriticalNamePtrTy) |
270 | __OMP_RTL(__kmpc_reduce_nowait, false, Int32, IdentPtr, Int32, Int32, SizeTy, |
271 | VoidPtr, ReduceFunctionPtr, KmpCriticalNamePtrTy) |
272 | __OMP_RTL(__kmpc_end_reduce, false, Void, IdentPtr, Int32, KmpCriticalNamePtrTy) |
273 | __OMP_RTL(__kmpc_end_reduce_nowait, false, Void, IdentPtr, Int32, |
274 | KmpCriticalNamePtrTy) |
275 | |
276 | __OMP_RTL(__kmpc_ordered, false, Void, IdentPtr, Int32) |
277 | __OMP_RTL(__kmpc_end_ordered, false, Void, IdentPtr, Int32) |
278 | |
279 | __OMP_RTL(__kmpc_for_static_init_4, false, Void, IdentPtr, Int32, Int32, |
280 | Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
281 | __OMP_RTL(__kmpc_for_static_init_4u, false, Void, IdentPtr, Int32, Int32, |
282 | Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
283 | __OMP_RTL(__kmpc_for_static_init_8, false, Void, IdentPtr, Int32, Int32, |
284 | Int32Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
285 | __OMP_RTL(__kmpc_for_static_init_8u, false, Void, IdentPtr, Int32, Int32, |
286 | Int32Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
287 | __OMP_RTL(__kmpc_for_static_fini, false, Void, IdentPtr, Int32) |
288 | __OMP_RTL(__kmpc_distribute_static_init_4, false, Void, IdentPtr, Int32, Int32, |
289 | Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
290 | __OMP_RTL(__kmpc_distribute_static_init_4u, false, Void, IdentPtr, Int32, Int32, |
291 | Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
292 | __OMP_RTL(__kmpc_distribute_static_init_8, false, Void, IdentPtr, Int32, Int32, |
293 | Int32Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
294 | __OMP_RTL(__kmpc_distribute_static_init_8u, false, Void, IdentPtr, Int32, Int32, |
295 | Int32Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
296 | __OMP_RTL(__kmpc_distribute_static_fini, false, Void, IdentPtr, Int32) |
297 | __OMP_RTL(__kmpc_dist_dispatch_init_4, false, Void, IdentPtr, Int32, Int32, |
298 | Int32Ptr, Int32, Int32, Int32, Int32) |
299 | __OMP_RTL(__kmpc_dist_dispatch_init_4u, false, Void, IdentPtr, Int32, Int32, |
300 | Int32Ptr, Int32, Int32, Int32, Int32) |
301 | __OMP_RTL(__kmpc_dist_dispatch_init_8, false, Void, IdentPtr, Int32, Int32, |
302 | Int32Ptr, Int64, Int64, Int64, Int64) |
303 | __OMP_RTL(__kmpc_dist_dispatch_init_8u, false, Void, IdentPtr, Int32, Int32, |
304 | Int32Ptr, Int64, Int64, Int64, Int64) |
305 | __OMP_RTL(__kmpc_dispatch_init_4, false, Void, IdentPtr, Int32, Int32, Int32, |
306 | Int32, Int32, Int32) |
307 | __OMP_RTL(__kmpc_dispatch_init_4u, false, Void, IdentPtr, Int32, Int32, Int32, |
308 | Int32, Int32, Int32) |
309 | __OMP_RTL(__kmpc_dispatch_init_8, false, Void, IdentPtr, Int32, Int32, Int64, |
310 | Int64, Int64, Int64) |
311 | __OMP_RTL(__kmpc_dispatch_init_8u, false, Void, IdentPtr, Int32, Int32, Int64, |
312 | Int64, Int64, Int64) |
313 | __OMP_RTL(__kmpc_dispatch_next_4, false, Int32, IdentPtr, Int32, Int32Ptr, |
314 | Int32Ptr, Int32Ptr, Int32Ptr) |
315 | __OMP_RTL(__kmpc_dispatch_next_4u, false, Int32, IdentPtr, Int32, Int32Ptr, |
316 | Int32Ptr, Int32Ptr, Int32Ptr) |
317 | __OMP_RTL(__kmpc_dispatch_next_8, false, Int32, IdentPtr, Int32, Int32Ptr, |
318 | Int64Ptr, Int64Ptr, Int64Ptr) |
319 | __OMP_RTL(__kmpc_dispatch_next_8u, false, Int32, IdentPtr, Int32, Int32Ptr, |
320 | Int64Ptr, Int64Ptr, Int64Ptr) |
321 | __OMP_RTL(__kmpc_dispatch_fini_4, false, Void, IdentPtr, Int32) |
322 | __OMP_RTL(__kmpc_dispatch_fini_4u, false, Void, IdentPtr, Int32) |
323 | __OMP_RTL(__kmpc_dispatch_fini_8, false, Void, IdentPtr, Int32) |
324 | __OMP_RTL(__kmpc_dispatch_fini_8u, false, Void, IdentPtr, Int32) |
325 | __OMP_RTL(__kmpc_team_static_init_4, false, Void, IdentPtr, Int32, Int32Ptr, |
326 | Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
327 | __OMP_RTL(__kmpc_team_static_init_4u, false, Void, IdentPtr, Int32, Int32Ptr, |
328 | Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
329 | __OMP_RTL(__kmpc_team_static_init_8, false, Void, IdentPtr, Int32, Int32Ptr, |
330 | Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
331 | __OMP_RTL(__kmpc_team_static_init_8u, false, Void, IdentPtr, Int32, Int32Ptr, |
332 | Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
333 | __OMP_RTL(__kmpc_dist_for_static_init_4, false, Void, IdentPtr, Int32, Int32, |
334 | Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
335 | __OMP_RTL(__kmpc_dist_for_static_init_4u, false, Void, IdentPtr, Int32, Int32, |
336 | Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32Ptr, Int32, Int32) |
337 | __OMP_RTL(__kmpc_dist_for_static_init_8, false, Void, IdentPtr, Int32, Int32, |
338 | Int32Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
339 | __OMP_RTL(__kmpc_dist_for_static_init_8u, false, Void, IdentPtr, Int32, Int32, |
340 | Int32Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64Ptr, Int64, Int64) |
341 | |
342 | __OMP_RTL(__kmpc_single, false, Int32, IdentPtr, Int32) |
343 | __OMP_RTL(__kmpc_end_single, false, Void, IdentPtr, Int32) |
344 | |
345 | __OMP_RTL(__kmpc_omp_task_alloc, false, /* kmp_task_t */ VoidPtr, IdentPtr, |
346 | Int32, Int32, SizeTy, SizeTy, TaskRoutineEntryPtr) |
347 | __OMP_RTL(__kmpc_omp_task, false, Int32, IdentPtr, Int32, |
348 | /* kmp_task_t */ VoidPtr) |
349 | __OMP_RTL(__kmpc_end_taskgroup, false, Void, IdentPtr, Int32) |
350 | __OMP_RTL(__kmpc_taskgroup, false, Void, IdentPtr, Int32) |
351 | __OMP_RTL(__kmpc_omp_task_begin_if0, false, Void, IdentPtr, Int32, |
352 | /* kmp_task_t */ VoidPtr) |
353 | __OMP_RTL(__kmpc_omp_task_complete_if0, false, Void, IdentPtr, Int32, |
354 | /* kmp_tasK_t */ VoidPtr) |
355 | __OMP_RTL(__kmpc_omp_task_with_deps, false, Int32, IdentPtr, Int32, |
356 | /* kmp_task_t */ VoidPtr, Int32, |
357 | /* kmp_depend_info_t */ VoidPtr, Int32, |
358 | /* kmp_depend_info_t */ VoidPtr) |
359 | __OMP_RTL(__kmpc_taskloop, false, Void, IdentPtr, /* Int */ Int32, VoidPtr, |
360 | /* Int */ Int32, Int64Ptr, Int64Ptr, Int64, /* Int */ Int32, |
361 | /* Int */ Int32, Int64, VoidPtr) |
362 | __OMP_RTL(__kmpc_omp_target_task_alloc, false, /* kmp_task_t */ VoidPtr, |
363 | IdentPtr, Int32, Int32, SizeTy, SizeTy, TaskRoutineEntryPtr, Int64) |
364 | __OMP_RTL(__kmpc_taskred_modifier_init, false, /* kmp_taskgroup */ VoidPtr, |
365 | IdentPtr, /* Int */ Int32, /* Int */ Int32, /* Int */ Int32, VoidPtr) |
366 | __OMP_RTL(__kmpc_taskred_init, false, /* kmp_taskgroup */ VoidPtr, |
367 | /* Int */ Int32, /* Int */ Int32, VoidPtr) |
368 | __OMP_RTL(__kmpc_task_reduction_modifier_fini, false, Void, IdentPtr, |
369 | /* Int */ Int32, /* Int */ Int32) |
370 | __OMP_RTL(__kmpc_task_reduction_get_th_data, false, VoidPtr, Int32, VoidPtr, |
371 | VoidPtr) |
372 | __OMP_RTL(__kmpc_task_reduction_init, false, VoidPtr, Int32, Int32, VoidPtr) |
373 | __OMP_RTL(__kmpc_task_reduction_modifier_init, false, VoidPtr, VoidPtr, Int32, |
374 | Int32, Int32, VoidPtr) |
375 | __OMP_RTL(__kmpc_proxy_task_completed_ooo, false, Void, VoidPtr) |
376 | |
377 | __OMP_RTL(__kmpc_omp_wait_deps, false, Void, IdentPtr, Int32, Int32, |
378 | /* kmp_depend_info_t */ VoidPtr, Int32, VoidPtr) |
379 | __OMP_RTL(__kmpc_omp_taskwait_deps_51, false, Void, IdentPtr, Int32, Int32, |
380 | /* kmp_depend_info_t */ VoidPtr, Int32, VoidPtr, Int32) |
381 | __OMP_RTL(__kmpc_cancellationpoint, false, Int32, IdentPtr, Int32, Int32) |
382 | |
383 | __OMP_RTL(__kmpc_fork_teams, true, Void, IdentPtr, Int32, ParallelTaskPtr) |
384 | __OMP_RTL(__kmpc_push_num_teams, false, Void, IdentPtr, Int32, Int32, Int32) |
385 | |
386 | __OMP_RTL(__kmpc_copyprivate, false, Void, IdentPtr, Int32, SizeTy, VoidPtr, |
387 | CopyFunctionPtr, Int32) |
388 | __OMP_RTL(__kmpc_threadprivate_cached, false, VoidPtr, IdentPtr, Int32, VoidPtr, |
389 | SizeTy, VoidPtrPtrPtr) |
390 | __OMP_RTL(__kmpc_threadprivate_register, false, Void, IdentPtr, VoidPtr, |
391 | KmpcCtorPtr, KmpcCopyCtorPtr, KmpcDtorPtr) |
392 | |
393 | __OMP_RTL(__kmpc_doacross_init, false, Void, IdentPtr, Int32, Int32, |
394 | /* kmp_dim */ VoidPtr) |
395 | __OMP_RTL(__kmpc_doacross_post, false, Void, IdentPtr, Int32, Int64Ptr) |
396 | __OMP_RTL(__kmpc_doacross_wait, false, Void, IdentPtr, Int32, Int64Ptr) |
397 | __OMP_RTL(__kmpc_doacross_fini, false, Void, IdentPtr, Int32) |
398 | |
399 | __OMP_RTL(__kmpc_alloc, false, VoidPtr, /* Int */ Int32, SizeTy, VoidPtr) |
400 | __OMP_RTL(__kmpc_aligned_alloc, false, VoidPtr, /* Int */ Int32, SizeTy, SizeTy, |
401 | VoidPtr) |
402 | __OMP_RTL(__kmpc_free, false, Void, /* Int */ Int32, VoidPtr, VoidPtr) |
403 | |
404 | __OMP_RTL(__tgt_interop_init, false, Void, IdentPtr, Int32, VoidPtrPtr, Int32, |
405 | Int32, Int32, VoidPtr, Int32) |
406 | __OMP_RTL(__tgt_interop_destroy, false, Void, IdentPtr, Int32, VoidPtrPtr, |
407 | Int32, Int32, VoidPtr, Int32) |
408 | __OMP_RTL(__tgt_interop_use, false, Void, IdentPtr, Int32, VoidPtrPtr, Int32, |
409 | Int32, VoidPtr, Int32) |
410 | |
411 | __OMP_RTL(__kmpc_init_allocator, false, /* omp_allocator_handle_t */ VoidPtr, |
412 | /* Int */ Int32, /* omp_memespace_handle_t */ VoidPtr, |
413 | /* Int */ Int32, /* omp_alloctrait_t */ VoidPtr) |
414 | __OMP_RTL(__kmpc_destroy_allocator, false, Void, /* Int */ Int32, |
415 | /* omp_allocator_handle_t */ VoidPtr) |
416 | |
417 | __OMP_RTL(__kmpc_push_target_tripcount_mapper, false, Void, IdentPtr, Int64, Int64) |
418 | __OMP_RTL(__tgt_target_mapper, false, Int32, IdentPtr, Int64, VoidPtr, Int32, VoidPtrPtr, |
419 | VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr) |
420 | __OMP_RTL(__tgt_target_nowait_mapper, false, Int32, IdentPtr, Int64, VoidPtr, |
421 | Int32, VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, |
422 | VoidPtrPtr, Int32, VoidPtr, Int32, VoidPtr) |
423 | __OMP_RTL(__tgt_target_teams_mapper, false, Int32, IdentPtr, Int64, VoidPtr, Int32, |
424 | VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr, Int32, Int32) |
425 | __OMP_RTL(__tgt_target_teams_nowait_mapper, false, Int32, IdentPtr, Int64, |
426 | VoidPtr, Int32, VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, |
427 | VoidPtrPtr, VoidPtrPtr, Int32, Int32, Int32, VoidPtr, Int32, VoidPtr) |
428 | __OMP_RTL(__tgt_target_kernel, false, Int32, IdentPtr, Int64, Int32, Int32, |
429 | VoidPtr, KernelArgsPtr) |
430 | __OMP_RTL(__tgt_target_kernel_nowait, false, Int32, IdentPtr, Int64, Int32, |
431 | Int32, VoidPtr, KernelArgsPtr, Int32, VoidPtr, Int32, VoidPtr) |
432 | __OMP_RTL(__tgt_register_requires, false, Void, Int64) |
433 | __OMP_RTL(__tgt_target_data_begin_mapper, false, Void, IdentPtr, Int64, Int32, VoidPtrPtr, |
434 | VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr) |
435 | __OMP_RTL(__tgt_target_data_begin_nowait_mapper, false, Void, IdentPtr, Int64, Int32, |
436 | VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr) |
437 | __OMP_RTL(__tgt_target_data_begin_mapper_issue, false, Void, IdentPtr, Int64, Int32, |
438 | VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr, AsyncInfoPtr) |
439 | __OMP_RTL(__tgt_target_data_begin_mapper_wait, false, Void, Int64, AsyncInfoPtr) |
440 | __OMP_RTL(__tgt_target_data_end_mapper, false, Void, IdentPtr, Int64, Int32, VoidPtrPtr, |
441 | VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr) |
442 | __OMP_RTL(__tgt_target_data_end_nowait_mapper, false, Void, IdentPtr, Int64, Int32, |
443 | VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr) |
444 | __OMP_RTL(__tgt_target_data_update_mapper, false, Void, IdentPtr, Int64, Int32, |
445 | VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr) |
446 | __OMP_RTL(__tgt_target_data_update_nowait_mapper, false, Void, IdentPtr, Int64, Int32, |
447 | VoidPtrPtr, VoidPtrPtr, Int64Ptr, Int64Ptr, VoidPtrPtr, VoidPtrPtr) |
448 | __OMP_RTL(__tgt_mapper_num_components, false, Int64, VoidPtr) |
449 | __OMP_RTL(__tgt_push_mapper_component, false, Void, VoidPtr, VoidPtr, VoidPtr, |
450 | Int64, Int64, VoidPtr) |
451 | __OMP_RTL(__kmpc_task_allow_completion_event, false, VoidPtr, IdentPtr, |
452 | /* Int */ Int32, /* kmp_task_t */ VoidPtr) |
453 | |
454 | /// OpenMP Device runtime functions |
455 | __OMP_RTL(__kmpc_target_init, false, Int32, IdentPtr, Int8, Int1) |
456 | __OMP_RTL(__kmpc_target_deinit, false, Void, IdentPtr, Int8) |
457 | __OMP_RTL(__kmpc_kernel_prepare_parallel, false, Void, VoidPtr) |
458 | __OMP_RTL(__kmpc_parallel_51, false, Void, IdentPtr, Int32, Int32, Int32, Int32, |
459 | VoidPtr, VoidPtr, VoidPtrPtr, SizeTy) |
460 | __OMP_RTL(__kmpc_kernel_parallel, false, Int1, VoidPtrPtr) |
461 | __OMP_RTL(__kmpc_kernel_end_parallel, false, Void, ) |
462 | __OMP_RTL(__kmpc_serialized_parallel, false, Void, IdentPtr, Int32) |
463 | __OMP_RTL(__kmpc_end_serialized_parallel, false, Void, IdentPtr, Int32) |
464 | __OMP_RTL(__kmpc_shuffle_int32, false, Int32, Int32, Int16, Int16) |
465 | __OMP_RTL(__kmpc_nvptx_parallel_reduce_nowait_v2, false, Int32, IdentPtr, Int32, |
466 | Int32, SizeTy, VoidPtr, ShuffleReducePtr, InterWarpCopyPtr) |
467 | __OMP_RTL(__kmpc_nvptx_end_reduce_nowait, false, Void, Int32) |
468 | __OMP_RTL(__kmpc_nvptx_teams_reduce_nowait_v2, false, Int32, IdentPtr, Int32, |
469 | VoidPtr, Int32, VoidPtr, ShuffleReducePtr, InterWarpCopyPtr, |
470 | GlobalListPtr, GlobalListPtr, GlobalListPtr, GlobalListPtr) |
471 | |
472 | __OMP_RTL(__kmpc_shuffle_int64, false, Int64, Int64, Int16, Int16) |
473 | |
474 | __OMP_RTL(__kmpc_alloc_shared, false, VoidPtr, SizeTy) |
475 | __OMP_RTL(__kmpc_free_shared, false, Void, VoidPtr, SizeTy) |
476 | __OMP_RTL(__kmpc_begin_sharing_variables, false, Void, VoidPtrPtrPtr, SizeTy) |
477 | __OMP_RTL(__kmpc_end_sharing_variables, false, Void, ) |
478 | __OMP_RTL(__kmpc_get_shared_variables, false, Void, VoidPtrPtrPtr) |
479 | __OMP_RTL(__kmpc_parallel_level, false, Int16, IdentPtr, Int32) |
480 | __OMP_RTL(__kmpc_is_spmd_exec_mode, false, Int8, ) |
481 | __OMP_RTL(__kmpc_barrier_simple_spmd, false, Void, IdentPtr, Int32) |
482 | __OMP_RTL(__kmpc_barrier_simple_generic, false, Void, IdentPtr, Int32) |
483 | |
484 | __OMP_RTL(__kmpc_warp_active_thread_mask, false, Int64,) |
485 | __OMP_RTL(__kmpc_syncwarp, false, Void, Int64) |
486 | |
487 | __OMP_RTL(__last, false, Void, ) |
488 | |
489 | #undef __OMP_RTL |
490 | #undef OMP_RTL |
491 | |
492 | #define ParamAttrs(...) ArrayRef<AttributeSet>({__VA_ARGS__}) |
493 | #define EnumAttr(Kind) Attribute::get(Ctx, Attribute::AttrKind::Kind) |
494 | #define EnumAttrInt(Kind, N) Attribute::get(Ctx, Attribute::AttrKind::Kind, N) |
495 | #define AllocSizeAttr(N, M) Attribute::getWithAllocSizeArgs(Ctx, N, M) |
496 | #define MemoryAttr(ME) Attribute::getWithMemoryEffects(Ctx, ME) |
497 | #define AttributeSet(...) \ |
498 | AttributeSet::get(Ctx, ArrayRef<Attribute>({__VA_ARGS__})) |
499 | |
500 | #ifndef OMP_ATTRS_SET |
501 | #define OMP_ATTRS_SET(VarName, AttrSet) |
502 | #endif |
503 | |
504 | #define __OMP_ATTRS_SET(VarName, AttrSet) OMP_ATTRS_SET(VarName, AttrSet) |
505 | |
506 | __OMP_ATTRS_SET( |
507 | GetterAttrs, |
508 | OptimisticAttributes |
509 | ? AttributeSet( |
510 | EnumAttr(NoUnwind), EnumAttr(NoSync), EnumAttr(NoFree), |
511 | EnumAttr(WillReturn), |
512 | MemoryAttr(MemoryEffects::inaccessibleMemOnly(ModRefInfo::Ref))) |
513 | : AttributeSet(EnumAttr(NoUnwind))) |
514 | __OMP_ATTRS_SET( |
515 | GetterArgReadAttrs, |
516 | OptimisticAttributes |
517 | ? AttributeSet( |
518 | EnumAttr(NoUnwind), EnumAttr(NoSync), EnumAttr(NoFree), |
519 | EnumAttr(WillReturn), |
520 | MemoryAttr(MemoryEffects::inaccessibleOrArgMemOnly(ModRefInfo::Ref))) |
521 | : AttributeSet(EnumAttr(NoUnwind))) |
522 | __OMP_ATTRS_SET( |
523 | GetterArgWriteAttrs, |
524 | OptimisticAttributes |
525 | ? AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync), EnumAttr(NoFree), |
526 | EnumAttr(WillReturn), |
527 | MemoryAttr(MemoryEffects::argMemOnly() | MemoryEffects::inaccessibleMemOnly(ModRefInfo::Ref))) |
528 | : AttributeSet(EnumAttr(NoUnwind))) |
529 | __OMP_ATTRS_SET( |
530 | SetterAttrs, |
531 | OptimisticAttributes |
532 | ? AttributeSet( |
533 | EnumAttr(NoUnwind), EnumAttr(NoSync), EnumAttr(NoFree), |
534 | EnumAttr(WillReturn), |
535 | MemoryAttr(MemoryEffects::inaccessibleMemOnly(ModRefInfo::Mod))) |
536 | : AttributeSet(EnumAttr(NoUnwind))) |
537 | |
538 | __OMP_ATTRS_SET(DefaultAttrs, |
539 | OptimisticAttributes |
540 | ? AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync), |
541 | EnumAttr(WillReturn), EnumAttr(NoFree)) |
542 | : AttributeSet(EnumAttr(NoUnwind))) |
543 | |
544 | __OMP_ATTRS_SET(BarrierAttrs, |
545 | OptimisticAttributes |
546 | ? AttributeSet(EnumAttr(NoUnwind), EnumAttr(Convergent)) |
547 | : AttributeSet(EnumAttr(NoUnwind), EnumAttr(Convergent))) |
548 | |
549 | __OMP_ATTRS_SET( |
550 | InaccessibleArgOnlyAttrs, |
551 | OptimisticAttributes |
552 | ? AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync), EnumAttr(NoFree), |
553 | EnumAttr(WillReturn), |
554 | MemoryAttr(MemoryEffects::inaccessibleOrArgMemOnly())) |
555 | : AttributeSet(EnumAttr(NoUnwind))) |
556 | |
557 | __OMP_ATTRS_SET(AlwaysInlineAttrs, |
558 | OptimisticAttributes |
559 | ? AttributeSet(EnumAttr(AlwaysInline)) |
560 | : AttributeSet(EnumAttr(AlwaysInline))) |
561 | |
562 | #if 0 |
563 | __OMP_ATTRS_SET( |
564 | InaccessibleOnlyAttrs, |
565 | OptimisticAttributes |
566 | ? AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync), EnumAttr(NoFree), |
567 | EnumAttr(WillReturn), |
568 | MemoryAttr(MemoryEffects::inaccessibleMemOnly())) |
569 | : AttributeSet(EnumAttr(NoUnwind))) |
570 | #endif |
571 | |
572 | __OMP_ATTRS_SET(AllocAttrs, |
573 | OptimisticAttributes |
574 | ? AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync), |
575 | EnumAttr(WillReturn)) |
576 | : AttributeSet(EnumAttr(NoUnwind))) |
577 | |
578 | __OMP_ATTRS_SET(ForkAttrs, OptimisticAttributes |
579 | ? AttributeSet(EnumAttr(NoUnwind)) |
580 | : AttributeSet(EnumAttr(NoUnwind))) |
581 | |
582 | __OMP_ATTRS_SET(ReadOnlyPtrAttrs, |
583 | OptimisticAttributes |
584 | ? AttributeSet(EnumAttr(ReadOnly), EnumAttr(NoFree), |
585 | EnumAttr(NoCapture)) |
586 | : AttributeSet()) |
587 | |
588 | __OMP_ATTRS_SET(DeviceAllocAttrs, |
589 | OptimisticAttributes |
590 | ? AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync)) |
591 | : AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync))) |
592 | |
593 | #if 0 |
594 | __OMP_ATTRS_SET(WriteOnlyPtrAttrs, |
595 | OptimisticAttributes |
596 | ? AttributeSet(EnumAttr(WriteOnly), EnumAttr(NoFree), |
597 | EnumAttr(NoCapture)) |
598 | : AttributeSet()) |
599 | #endif |
600 | |
601 | __OMP_ATTRS_SET(ArgPtrAttrs, |
602 | OptimisticAttributes |
603 | ? AttributeSet(EnumAttr(NoCapture), EnumAttr(NoFree)) |
604 | : AttributeSet()) |
605 | |
606 | __OMP_ATTRS_SET(ReturnPtrAttrs, |
607 | OptimisticAttributes |
608 | ? AttributeSet(EnumAttr(NoAlias)) |
609 | : AttributeSet()) |
610 | |
611 | __OMP_ATTRS_SET(ZExt, AttributeSet(EnumAttr(ZExt))) |
612 | __OMP_ATTRS_SET(SExt, AttributeSet(EnumAttr(SExt))) |
613 | __OMP_ATTRS_SET(SizeTyExt, |
614 | M.getDataLayout().getIntPtrType(Ctx)->getBitWidth() < 64 |
615 | ? AttributeSet(EnumAttr(ZExt)) |
616 | : AttributeSet()) |
617 | |
618 | #if 0 |
619 | __OMP_ATTRS_SET(ReturnAlignedPtrAttrs, |
620 | OptimisticAttributes |
621 | ? AttributeSet(EnumAttr(NoAlias), EnumAttrInt(Alignment, 8), |
622 | EnumAttrInt(DereferenceableOrNull, 8)) |
623 | : AttributeSet()) |
624 | #endif |
625 | |
626 | #undef __OMP_ATTRS_SET |
627 | #undef OMP_ATTRS_SET |
628 | |
629 | #ifndef OMP_RTL_ATTRS |
630 | #define OMP_RTL_ATTRS(Enum, FnAttrSet, RetAttrSet, ArgAttrSets) |
631 | #endif |
632 | |
633 | #define __OMP_RTL_ATTRS(Name, FnAttrSet, RetAttrSet, ArgAttrSets) \ |
634 | OMP_RTL_ATTRS(OMPRTL_##Name, FnAttrSet, RetAttrSet, ArgAttrSets) |
635 | |
636 | __OMP_RTL_ATTRS(__kmpc_barrier, BarrierAttrs, AttributeSet(), |
637 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
638 | __OMP_RTL_ATTRS(__kmpc_barrier_simple_spmd, BarrierAttrs, AttributeSet(), |
639 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
640 | __OMP_RTL_ATTRS(__kmpc_barrier_simple_generic, BarrierAttrs, AttributeSet(), |
641 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
642 | __OMP_RTL_ATTRS(__kmpc_warp_active_thread_mask, BarrierAttrs, AttributeSet(), |
643 | ParamAttrs()) |
644 | __OMP_RTL_ATTRS(__kmpc_syncwarp, BarrierAttrs, AttributeSet(), ParamAttrs()) |
645 | __OMP_RTL_ATTRS(__kmpc_cancel, InaccessibleArgOnlyAttrs, SExt, |
646 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
647 | __OMP_RTL_ATTRS(__kmpc_cancel_barrier, BarrierAttrs, SExt, |
648 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
649 | __OMP_RTL_ATTRS(__kmpc_error, AttributeSet(), AttributeSet(), |
650 | ParamAttrs(AttributeSet(), SExt)) |
651 | __OMP_RTL_ATTRS(__kmpc_flush, BarrierAttrs, AttributeSet(), |
652 | ParamAttrs(ReadOnlyPtrAttrs)) |
653 | __OMP_RTL_ATTRS(__kmpc_global_thread_num, GetterArgReadAttrs, SExt, |
654 | ParamAttrs(ReadOnlyPtrAttrs)) |
655 | __OMP_RTL_ATTRS(__kmpc_get_hardware_thread_id_in_block, GetterAttrs, ZExt, |
656 | ParamAttrs()) |
657 | __OMP_RTL_ATTRS(__kmpc_fork_call, ForkAttrs, AttributeSet(), |
658 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ReadOnlyPtrAttrs)) |
659 | __OMP_RTL_ATTRS(__kmpc_fork_call_if, AttributeSet(), AttributeSet(), |
660 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ReadOnlyPtrAttrs, SExt)) |
661 | __OMP_RTL_ATTRS(__kmpc_omp_taskwait, BarrierAttrs, SExt, |
662 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
663 | __OMP_RTL_ATTRS(__kmpc_omp_taskyield, InaccessibleArgOnlyAttrs, SExt, |
664 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
665 | __OMP_RTL_ATTRS(__kmpc_push_num_threads, InaccessibleArgOnlyAttrs, |
666 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
667 | __OMP_RTL_ATTRS(__kmpc_push_proc_bind, InaccessibleArgOnlyAttrs, AttributeSet(), |
668 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
669 | __OMP_RTL_ATTRS(__kmpc_omp_reg_task_with_affinity, DefaultAttrs, SExt, |
670 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ReadOnlyPtrAttrs, |
671 | SExt, ReadOnlyPtrAttrs)) |
672 | |
673 | __OMP_RTL_ATTRS(__kmpc_get_hardware_num_blocks, GetterAttrs, ZExt, ParamAttrs()) |
674 | __OMP_RTL_ATTRS(__kmpc_get_hardware_num_threads_in_block, GetterAttrs, ZExt, ParamAttrs()) |
675 | __OMP_RTL_ATTRS(__kmpc_get_warp_size, GetterAttrs, ZExt, ParamAttrs()) |
676 | |
677 | __OMP_RTL_ATTRS(omp_get_thread_num, GetterAttrs, SExt, ParamAttrs()) |
678 | __OMP_RTL_ATTRS(omp_get_num_threads, GetterAttrs, SExt, ParamAttrs()) |
679 | __OMP_RTL_ATTRS(omp_get_max_threads, GetterAttrs, SExt, ParamAttrs()) |
680 | __OMP_RTL_ATTRS(omp_in_parallel, GetterAttrs, SExt, ParamAttrs()) |
681 | __OMP_RTL_ATTRS(omp_get_dynamic, GetterAttrs, SExt, ParamAttrs()) |
682 | __OMP_RTL_ATTRS(omp_get_cancellation, GetterAttrs, SExt, ParamAttrs()) |
683 | __OMP_RTL_ATTRS(omp_get_nested, GetterAttrs, SExt, ParamAttrs()) |
684 | __OMP_RTL_ATTRS( |
685 | omp_get_schedule, GetterArgWriteAttrs, AttributeSet(), |
686 | ParamAttrs(AttributeSet(EnumAttr(NoCapture), EnumAttr(WriteOnly)), |
687 | AttributeSet(EnumAttr(NoCapture), EnumAttr(WriteOnly)))) |
688 | __OMP_RTL_ATTRS(omp_get_thread_limit, GetterAttrs, SExt, ParamAttrs()) |
689 | __OMP_RTL_ATTRS(omp_get_supported_active_levels, GetterAttrs, SExt, ParamAttrs()) |
690 | __OMP_RTL_ATTRS(omp_get_max_active_levels, GetterAttrs, SExt, ParamAttrs()) |
691 | __OMP_RTL_ATTRS(omp_get_level, GetterAttrs, SExt, ParamAttrs()) |
692 | __OMP_RTL_ATTRS(omp_get_ancestor_thread_num, GetterAttrs, SExt, ParamAttrs(SExt)) |
693 | __OMP_RTL_ATTRS(omp_get_team_size, GetterAttrs, SExt, ParamAttrs(SExt)) |
694 | __OMP_RTL_ATTRS(omp_get_active_level, GetterAttrs, SExt, ParamAttrs()) |
695 | __OMP_RTL_ATTRS(omp_in_final, GetterAttrs, SExt, ParamAttrs()) |
696 | __OMP_RTL_ATTRS(omp_get_proc_bind, GetterAttrs, SExt, ParamAttrs()) |
697 | __OMP_RTL_ATTRS(omp_get_num_places, GetterAttrs, SExt, ParamAttrs()) |
698 | __OMP_RTL_ATTRS(omp_get_num_procs, GetterAttrs, SExt, ParamAttrs()) |
699 | __OMP_RTL_ATTRS(omp_get_place_proc_ids, GetterArgWriteAttrs, AttributeSet(), |
700 | ParamAttrs(SExt, AttributeSet(EnumAttr(NoCapture), |
701 | EnumAttr(WriteOnly)))) |
702 | __OMP_RTL_ATTRS(omp_get_place_num, GetterAttrs, SExt, ParamAttrs()) |
703 | __OMP_RTL_ATTRS(omp_get_partition_num_places, GetterAttrs, SExt, ParamAttrs()) |
704 | __OMP_RTL_ATTRS(omp_get_partition_place_nums, GetterArgWriteAttrs, AttributeSet(), |
705 | ParamAttrs()) |
706 | __OMP_RTL_ATTRS(omp_get_wtime, GetterAttrs, AttributeSet(), ParamAttrs()) |
707 | |
708 | __OMP_RTL_ATTRS(omp_set_num_threads, SetterAttrs, AttributeSet(), |
709 | ParamAttrs(SExt)) |
710 | __OMP_RTL_ATTRS(omp_set_dynamic, SetterAttrs, AttributeSet(), ParamAttrs(SExt)) |
711 | __OMP_RTL_ATTRS(omp_set_nested, SetterAttrs, AttributeSet(), ParamAttrs(SExt)) |
712 | __OMP_RTL_ATTRS(omp_set_schedule, SetterAttrs, AttributeSet(), |
713 | ParamAttrs(SExt, SExt)) |
714 | __OMP_RTL_ATTRS(omp_set_max_active_levels, SetterAttrs, AttributeSet(), |
715 | ParamAttrs(SExt)) |
716 | |
717 | __OMP_RTL_ATTRS(__kmpc_master, InaccessibleArgOnlyAttrs, SExt, |
718 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
719 | __OMP_RTL_ATTRS(__kmpc_end_master, InaccessibleArgOnlyAttrs, AttributeSet(), |
720 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
721 | __OMP_RTL_ATTRS(__kmpc_masked, InaccessibleArgOnlyAttrs, SExt, |
722 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
723 | __OMP_RTL_ATTRS(__kmpc_end_masked, InaccessibleArgOnlyAttrs, AttributeSet(), |
724 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
725 | __OMP_RTL_ATTRS(__kmpc_critical, BarrierAttrs, AttributeSet(), |
726 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet())) |
727 | __OMP_RTL_ATTRS(__kmpc_critical_with_hint, BarrierAttrs, AttributeSet(), |
728 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet(), ZExt)) |
729 | __OMP_RTL_ATTRS(__kmpc_end_critical, BarrierAttrs, AttributeSet(), |
730 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet())) |
731 | |
732 | __OMP_RTL_ATTRS(__kmpc_begin, DefaultAttrs, AttributeSet(), |
733 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
734 | __OMP_RTL_ATTRS(__kmpc_end, DefaultAttrs, AttributeSet(), |
735 | ParamAttrs(ReadOnlyPtrAttrs)) |
736 | |
737 | __OMP_RTL_ATTRS(__kmpc_reduce, BarrierAttrs, SExt, |
738 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, SizeTyExt, |
739 | ReadOnlyPtrAttrs, AttributeSet())) |
740 | __OMP_RTL_ATTRS(__kmpc_reduce_nowait, BarrierAttrs, SExt, |
741 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, SizeTyExt, |
742 | ReadOnlyPtrAttrs, AttributeSet())) |
743 | __OMP_RTL_ATTRS(__kmpc_end_reduce, BarrierAttrs, AttributeSet(), |
744 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet())) |
745 | __OMP_RTL_ATTRS(__kmpc_end_reduce_nowait, BarrierAttrs, AttributeSet(), |
746 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet())) |
747 | |
748 | __OMP_RTL_ATTRS(__kmpc_ordered, BarrierAttrs, AttributeSet(), |
749 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
750 | __OMP_RTL_ATTRS(__kmpc_end_ordered, BarrierAttrs, AttributeSet(), |
751 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
752 | |
753 | __OMP_RTL_ATTRS(__kmpc_for_static_init_4, GetterArgWriteAttrs, AttributeSet(), |
754 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
755 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, SExt, SExt)) |
756 | __OMP_RTL_ATTRS(__kmpc_for_static_init_4u, GetterArgWriteAttrs, AttributeSet(), |
757 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
758 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, SExt, SExt)) |
759 | __OMP_RTL_ATTRS(__kmpc_for_static_init_8, GetterArgWriteAttrs, AttributeSet(), |
760 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
761 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, |
762 | AttributeSet(), AttributeSet())) |
763 | __OMP_RTL_ATTRS(__kmpc_for_static_init_8u, GetterArgWriteAttrs, AttributeSet(), |
764 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
765 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, |
766 | AttributeSet(), AttributeSet())) |
767 | __OMP_RTL_ATTRS(__kmpc_for_static_fini, InaccessibleArgOnlyAttrs, |
768 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
769 | __OMP_RTL_ATTRS(__kmpc_distribute_static_init_4, GetterArgWriteAttrs, |
770 | AttributeSet(), |
771 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
772 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, SExt, SExt)) |
773 | __OMP_RTL_ATTRS(__kmpc_distribute_static_init_4u, GetterArgWriteAttrs, |
774 | AttributeSet(), |
775 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
776 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, SExt, SExt)) |
777 | __OMP_RTL_ATTRS(__kmpc_distribute_static_init_8, GetterArgWriteAttrs, |
778 | AttributeSet(), |
779 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
780 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, |
781 | AttributeSet(), AttributeSet())) |
782 | __OMP_RTL_ATTRS(__kmpc_distribute_static_init_8u, GetterArgWriteAttrs, |
783 | AttributeSet(), |
784 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
785 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, |
786 | AttributeSet(), AttributeSet())) |
787 | __OMP_RTL_ATTRS(__kmpc_distribute_static_fini, InaccessibleArgOnlyAttrs, |
788 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
789 | __OMP_RTL_ATTRS(__kmpc_dist_dispatch_init_4, GetterArgWriteAttrs, |
790 | AttributeSet(), |
791 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, SExt, |
792 | SExt, SExt, SExt)) |
793 | __OMP_RTL_ATTRS(__kmpc_dist_dispatch_init_4u, GetterArgWriteAttrs, |
794 | AttributeSet(), |
795 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, ZExt, |
796 | ZExt, SExt, SExt)) |
797 | __OMP_RTL_ATTRS(__kmpc_dist_dispatch_init_8, GetterArgWriteAttrs, |
798 | AttributeSet(), |
799 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs)) |
800 | __OMP_RTL_ATTRS(__kmpc_dist_dispatch_init_8u, GetterArgWriteAttrs, |
801 | AttributeSet(), |
802 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs)) |
803 | __OMP_RTL_ATTRS(__kmpc_dispatch_init_4, GetterArgWriteAttrs, AttributeSet(), |
804 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, SExt, SExt, SExt, SExt)) |
805 | __OMP_RTL_ATTRS(__kmpc_dispatch_init_4u, GetterArgWriteAttrs, AttributeSet(), |
806 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ZExt, ZExt, SExt, SExt)) |
807 | __OMP_RTL_ATTRS(__kmpc_dispatch_init_8, GetterArgWriteAttrs, AttributeSet(), |
808 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
809 | __OMP_RTL_ATTRS(__kmpc_dispatch_init_8u, GetterArgWriteAttrs, AttributeSet(), |
810 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
811 | __OMP_RTL_ATTRS(__kmpc_dispatch_next_4, GetterArgWriteAttrs, SExt, |
812 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
813 | ArgPtrAttrs, ArgPtrAttrs)) |
814 | __OMP_RTL_ATTRS(__kmpc_dispatch_next_4u, GetterArgWriteAttrs, SExt, |
815 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
816 | ArgPtrAttrs, ArgPtrAttrs)) |
817 | __OMP_RTL_ATTRS(__kmpc_dispatch_next_8, GetterArgWriteAttrs, SExt, |
818 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
819 | ArgPtrAttrs, ArgPtrAttrs)) |
820 | __OMP_RTL_ATTRS(__kmpc_dispatch_next_8u, GetterArgWriteAttrs, SExt, |
821 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
822 | ArgPtrAttrs, ArgPtrAttrs)) |
823 | __OMP_RTL_ATTRS(__kmpc_dispatch_fini_4, InaccessibleArgOnlyAttrs, |
824 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
825 | __OMP_RTL_ATTRS(__kmpc_dispatch_fini_4u, InaccessibleArgOnlyAttrs, |
826 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
827 | __OMP_RTL_ATTRS(__kmpc_dispatch_fini_8, InaccessibleArgOnlyAttrs, |
828 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
829 | __OMP_RTL_ATTRS(__kmpc_dispatch_fini_8u, InaccessibleArgOnlyAttrs, |
830 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
831 | __OMP_RTL_ATTRS(__kmpc_team_static_init_4, GetterArgWriteAttrs, AttributeSet(), |
832 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
833 | ArgPtrAttrs, ArgPtrAttrs, SExt, SExt)) |
834 | __OMP_RTL_ATTRS(__kmpc_team_static_init_4u, GetterArgWriteAttrs, AttributeSet(), |
835 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
836 | ArgPtrAttrs, ArgPtrAttrs, SExt, SExt)) |
837 | __OMP_RTL_ATTRS(__kmpc_team_static_init_8, GetterArgWriteAttrs, AttributeSet(), |
838 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
839 | ArgPtrAttrs, ArgPtrAttrs)) |
840 | __OMP_RTL_ATTRS(__kmpc_team_static_init_8u, GetterArgWriteAttrs, AttributeSet(), |
841 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ArgPtrAttrs, ArgPtrAttrs, |
842 | ArgPtrAttrs, ArgPtrAttrs)) |
843 | __OMP_RTL_ATTRS(__kmpc_dist_for_static_init_4, GetterArgWriteAttrs, |
844 | AttributeSet(), |
845 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
846 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, |
847 | ArgPtrAttrs, SExt, SExt)) |
848 | __OMP_RTL_ATTRS(__kmpc_dist_for_static_init_4u, GetterArgWriteAttrs, |
849 | AttributeSet(), |
850 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
851 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, |
852 | ArgPtrAttrs, SExt, SExt)) |
853 | __OMP_RTL_ATTRS(__kmpc_dist_for_static_init_8, GetterArgWriteAttrs, |
854 | AttributeSet(), |
855 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
856 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs)) |
857 | __OMP_RTL_ATTRS(__kmpc_dist_for_static_init_8u, GetterArgWriteAttrs, |
858 | AttributeSet(), |
859 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ArgPtrAttrs, |
860 | ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs, ArgPtrAttrs)) |
861 | |
862 | __OMP_RTL_ATTRS(__kmpc_single, BarrierAttrs, SExt, |
863 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
864 | __OMP_RTL_ATTRS(__kmpc_end_single, BarrierAttrs, AttributeSet(), |
865 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
866 | |
867 | __OMP_RTL_ATTRS(__kmpc_omp_task_alloc, DefaultAttrs, ReturnPtrAttrs, |
868 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, SizeTyExt, SizeTyExt, |
869 | ReadOnlyPtrAttrs)) |
870 | __OMP_RTL_ATTRS(__kmpc_omp_task, DefaultAttrs, SExt, |
871 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet())) |
872 | __OMP_RTL_ATTRS(__kmpc_end_taskgroup, BarrierAttrs, AttributeSet(), |
873 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
874 | __OMP_RTL_ATTRS(__kmpc_taskgroup, BarrierAttrs, AttributeSet(), |
875 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
876 | __OMP_RTL_ATTRS(__kmpc_omp_task_begin_if0, DefaultAttrs, AttributeSet(), |
877 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
878 | __OMP_RTL_ATTRS(__kmpc_omp_task_complete_if0, DefaultAttrs, AttributeSet(), |
879 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
880 | __OMP_RTL_ATTRS(__kmpc_omp_task_with_deps, DefaultAttrs, SExt, |
881 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet(), SExt, |
882 | ReadOnlyPtrAttrs, SExt, ReadOnlyPtrAttrs)) |
883 | __OMP_RTL_ATTRS(__kmpc_taskloop, DefaultAttrs, AttributeSet(), |
884 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet(), SExt, |
885 | ArgPtrAttrs, ArgPtrAttrs, AttributeSet(), SExt, SExt)) |
886 | __OMP_RTL_ATTRS(__kmpc_omp_target_task_alloc, DefaultAttrs, ReturnPtrAttrs, |
887 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, SizeTyExt, SizeTyExt, |
888 | ReadOnlyPtrAttrs, AttributeSet())) |
889 | __OMP_RTL_ATTRS(__kmpc_taskred_modifier_init, DefaultAttrs, ReturnPtrAttrs, |
890 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, SExt)) |
891 | __OMP_RTL_ATTRS(__kmpc_taskred_init, DefaultAttrs, AttributeSet(), |
892 | ParamAttrs(SExt, SExt)) |
893 | __OMP_RTL_ATTRS(__kmpc_task_reduction_modifier_fini, BarrierAttrs, |
894 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
895 | __OMP_RTL_ATTRS(__kmpc_task_reduction_get_th_data, DefaultAttrs, ReturnPtrAttrs, |
896 | ParamAttrs(SExt)) |
897 | __OMP_RTL_ATTRS(__kmpc_task_reduction_init, DefaultAttrs, ReturnPtrAttrs, |
898 | ParamAttrs(SExt, SExt)) |
899 | __OMP_RTL_ATTRS(__kmpc_task_reduction_modifier_init, DefaultAttrs, |
900 | ReturnPtrAttrs, ParamAttrs(AttributeSet(), SExt, SExt, SExt)) |
901 | __OMP_RTL_ATTRS(__kmpc_proxy_task_completed_ooo, DefaultAttrs, AttributeSet(), |
902 | ParamAttrs()) |
903 | |
904 | __OMP_RTL_ATTRS(__kmpc_omp_wait_deps, BarrierAttrs, AttributeSet(), |
905 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ReadOnlyPtrAttrs, SExt)) |
906 | __OMP_RTL_ATTRS(__kmpc_omp_taskwait_deps_51, BarrierAttrs, AttributeSet(), |
907 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, ReadOnlyPtrAttrs)) |
908 | __OMP_RTL_ATTRS(__kmpc_cancellationpoint, DefaultAttrs, SExt, |
909 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
910 | |
911 | __OMP_RTL_ATTRS(__kmpc_fork_teams, ForkAttrs, AttributeSet(), |
912 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ReadOnlyPtrAttrs)) |
913 | __OMP_RTL_ATTRS(__kmpc_push_num_teams, InaccessibleArgOnlyAttrs, AttributeSet(), |
914 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt, SExt)) |
915 | |
916 | __OMP_RTL_ATTRS(__kmpc_copyprivate, DefaultAttrs, AttributeSet(), |
917 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SizeTyExt, |
918 | ReadOnlyPtrAttrs, AttributeSet(), SExt)) |
919 | __OMP_RTL_ATTRS(__kmpc_threadprivate_cached, DefaultAttrs, ReturnPtrAttrs, |
920 | ParamAttrs(ReadOnlyPtrAttrs, SExt, AttributeSet(), SizeTyExt)) |
921 | __OMP_RTL_ATTRS(__kmpc_threadprivate_register, DefaultAttrs, AttributeSet(), |
922 | ParamAttrs(ReadOnlyPtrAttrs, AttributeSet(), ReadOnlyPtrAttrs, |
923 | ReadOnlyPtrAttrs, ReadOnlyPtrAttrs)) |
924 | |
925 | __OMP_RTL_ATTRS(__kmpc_doacross_init, BarrierAttrs, AttributeSet(), |
926 | ParamAttrs(ReadOnlyPtrAttrs, SExt, SExt)) |
927 | __OMP_RTL_ATTRS(__kmpc_doacross_post, BarrierAttrs, AttributeSet(), |
928 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ReadOnlyPtrAttrs)) |
929 | __OMP_RTL_ATTRS(__kmpc_doacross_wait, BarrierAttrs, AttributeSet(), |
930 | ParamAttrs(ReadOnlyPtrAttrs, SExt, ReadOnlyPtrAttrs)) |
931 | __OMP_RTL_ATTRS(__kmpc_doacross_fini, BarrierAttrs, AttributeSet(), |
932 | ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
933 | |
934 | __OMP_RTL_ATTRS(__kmpc_alloc_shared, |
935 | AttributeSet(EnumAttr(NoUnwind), EnumAttr(NoSync), |
936 | AllocSizeAttr(0, std::nullopt)), |
937 | ReturnPtrAttrs, ParamAttrs(SizeTyExt)) |
938 | __OMP_RTL_ATTRS(__kmpc_free_shared, DeviceAllocAttrs, AttributeSet(), |
939 | ParamAttrs(AttributeSet(EnumAttr(NoCapture), |
940 | EnumAttr(AllocatedPointer)), |
941 | SizeTyExt)) |
942 | __OMP_RTL_ATTRS(__kmpc_begin_sharing_variables, AttributeSet(), AttributeSet(), |
943 | ParamAttrs(AttributeSet(), SizeTyExt)) |
944 | |
945 | __OMP_RTL_ATTRS(__kmpc_alloc, DefaultAttrs, ReturnPtrAttrs, |
946 | ParamAttrs(SExt, SizeTyExt)) |
947 | __OMP_RTL_ATTRS(__kmpc_aligned_alloc, DefaultAttrs, ReturnPtrAttrs, |
948 | ParamAttrs(SExt, SizeTyExt, SizeTyExt)) |
949 | __OMP_RTL_ATTRS(__kmpc_free, AllocAttrs, AttributeSet(), |
950 | ParamAttrs(SExt)) |
951 | |
952 | __OMP_RTL_ATTRS(__tgt_interop_init, AttributeSet(), AttributeSet(), |
953 | ParamAttrs(AttributeSet(), SExt, AttributeSet(), SExt, |
954 | SExt, AttributeSet(), AttributeSet(), SExt)) |
955 | __OMP_RTL_ATTRS(__tgt_interop_destroy, AttributeSet(), AttributeSet(), |
956 | ParamAttrs(AttributeSet(), SExt, AttributeSet(), SExt, SExt, |
957 | AttributeSet(), SExt)) |
958 | __OMP_RTL_ATTRS(__tgt_interop_use, AttributeSet(), AttributeSet(), |
959 | ParamAttrs(AttributeSet(), SExt, AttributeSet(), SExt, SExt, |
960 | AttributeSet(), SExt)) |
961 | |
962 | __OMP_RTL_ATTRS(__kmpc_init_allocator, DefaultAttrs, ReturnPtrAttrs, |
963 | ParamAttrs(SExt, AttributeSet(), SExt)) |
964 | __OMP_RTL_ATTRS(__kmpc_destroy_allocator, AllocAttrs, AttributeSet(), |
965 | ParamAttrs(SExt)) |
966 | |
967 | __OMP_RTL_ATTRS(__kmpc_push_target_tripcount_mapper, SetterAttrs, |
968 | AttributeSet(), ParamAttrs()) |
969 | __OMP_RTL_ATTRS(__tgt_target_mapper, ForkAttrs, SExt, |
970 | ParamAttrs(AttributeSet(),AttributeSet(),AttributeSet(), SExt)) |
971 | __OMP_RTL_ATTRS(__tgt_target_nowait_mapper, ForkAttrs, SExt, |
972 | ParamAttrs(AttributeSet(), AttributeSet(), AttributeSet(), SExt, |
973 | AttributeSet(), AttributeSet(), AttributeSet(), |
974 | AttributeSet(), AttributeSet(), AttributeSet(), |
975 | SExt, AttributeSet(), SExt)) |
976 | __OMP_RTL_ATTRS(__tgt_target_teams_mapper, ForkAttrs, SExt, |
977 | ParamAttrs(AttributeSet(), AttributeSet(), AttributeSet(), SExt, |
978 | AttributeSet(), AttributeSet(), AttributeSet(), |
979 | AttributeSet(), AttributeSet(), AttributeSet(), SExt, |
980 | SExt)) |
981 | __OMP_RTL_ATTRS(__tgt_target_teams_nowait_mapper, ForkAttrs, SExt, |
982 | ParamAttrs(AttributeSet(), AttributeSet(), AttributeSet(), SExt, |
983 | AttributeSet(), AttributeSet(), AttributeSet(), |
984 | AttributeSet(), AttributeSet(), AttributeSet(), |
985 | SExt, SExt, SExt, AttributeSet(), SExt)) |
986 | __OMP_RTL_ATTRS(__tgt_target_kernel, ForkAttrs, SExt, |
987 | ParamAttrs(AttributeSet(), AttributeSet(), SExt, SExt)) |
988 | __OMP_RTL_ATTRS(__tgt_target_kernel_nowait, ForkAttrs, SExt, |
989 | ParamAttrs(AttributeSet(), AttributeSet(), SExt, SExt, |
990 | AttributeSet(), AttributeSet(), SExt, AttributeSet(), |
991 | SExt)) |
992 | __OMP_RTL_ATTRS(__tgt_register_requires, ForkAttrs, AttributeSet(), |
993 | ParamAttrs()) |
994 | __OMP_RTL_ATTRS(__tgt_target_data_begin_mapper, ForkAttrs, AttributeSet(), |
995 | ParamAttrs(AttributeSet(), AttributeSet(), SExt)) |
996 | __OMP_RTL_ATTRS(__tgt_target_data_begin_nowait_mapper, ForkAttrs, AttributeSet(), |
997 | ParamAttrs(AttributeSet(), AttributeSet(), SExt, AttributeSet(), |
998 | AttributeSet(), AttributeSet(), AttributeSet(), |
999 | AttributeSet(), AttributeSet())) |
1000 | __OMP_RTL_ATTRS(__tgt_target_data_begin_mapper_issue, AttributeSet(), |
1001 | AttributeSet(), |
1002 | ParamAttrs(AttributeSet(), AttributeSet(), SExt)) |
1003 | __OMP_RTL_ATTRS(__tgt_target_data_end_mapper, ForkAttrs, AttributeSet(), |
1004 | ParamAttrs(AttributeSet(), AttributeSet(), SExt)) |
1005 | __OMP_RTL_ATTRS(__tgt_target_data_end_nowait_mapper, ForkAttrs, AttributeSet(), |
1006 | ParamAttrs(AttributeSet(), AttributeSet(), SExt, AttributeSet(), |
1007 | AttributeSet(), AttributeSet(), AttributeSet(), |
1008 | AttributeSet(), AttributeSet())) |
1009 | __OMP_RTL_ATTRS(__tgt_target_data_update_mapper, ForkAttrs, AttributeSet(), |
1010 | ParamAttrs(AttributeSet(), AttributeSet(), SExt)) |
1011 | __OMP_RTL_ATTRS(__tgt_target_data_update_nowait_mapper, ForkAttrs, AttributeSet(), |
1012 | ParamAttrs(AttributeSet(), AttributeSet(), SExt, AttributeSet(), |
1013 | AttributeSet(), AttributeSet(), AttributeSet(), |
1014 | AttributeSet(), AttributeSet())) |
1015 | __OMP_RTL_ATTRS(__tgt_mapper_num_components, ForkAttrs, AttributeSet(), |
1016 | ParamAttrs()) |
1017 | __OMP_RTL_ATTRS(__tgt_push_mapper_component, ForkAttrs, AttributeSet(), |
1018 | ParamAttrs()) |
1019 | __OMP_RTL_ATTRS(__kmpc_task_allow_completion_event, DefaultAttrs, |
1020 | ReturnPtrAttrs, ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
1021 | |
1022 | __OMP_RTL_ATTRS(__kmpc_target_init, AttributeSet(), SExt, |
1023 | ParamAttrs(AttributeSet(), SExt, SExt)) |
1024 | __OMP_RTL_ATTRS(__kmpc_target_deinit, AttributeSet(), AttributeSet(), |
1025 | ParamAttrs(AttributeSet(), SExt)) |
1026 | __OMP_RTL_ATTRS(__kmpc_parallel_51, AlwaysInlineAttrs, AttributeSet(), |
1027 | ParamAttrs(AttributeSet(), SExt, SExt, SExt, SExt, |
1028 | AttributeSet(), AttributeSet(), AttributeSet(), |
1029 | SizeTyExt)) |
1030 | __OMP_RTL_ATTRS(__kmpc_serialized_parallel, InaccessibleArgOnlyAttrs, |
1031 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
1032 | __OMP_RTL_ATTRS(__kmpc_end_serialized_parallel, InaccessibleArgOnlyAttrs, |
1033 | AttributeSet(), ParamAttrs(ReadOnlyPtrAttrs, SExt)) |
1034 | __OMP_RTL_ATTRS(__kmpc_shuffle_int32, AttributeSet(), SExt, |
1035 | ParamAttrs(SExt, SExt, SExt)) |
1036 | __OMP_RTL_ATTRS(__kmpc_nvptx_parallel_reduce_nowait_v2, AttributeSet(), SExt, |
1037 | ParamAttrs(AttributeSet(), SExt, SExt, SizeTyExt)) |
1038 | __OMP_RTL_ATTRS(__kmpc_nvptx_end_reduce_nowait, AttributeSet(), AttributeSet(), |
1039 | ParamAttrs(SExt)) |
1040 | __OMP_RTL_ATTRS(__kmpc_nvptx_teams_reduce_nowait_v2, AttributeSet(), SExt, |
1041 | ParamAttrs(AttributeSet(), SExt, AttributeSet(), ZExt)) |
1042 | |
1043 | __OMP_RTL_ATTRS(__kmpc_shuffle_int64, AttributeSet(), AttributeSet(), |
1044 | ParamAttrs(AttributeSet(), SExt, SExt)) |
1045 | |
1046 | __OMP_RTL_ATTRS(__kmpc_is_spmd_exec_mode, AttributeSet(), SExt, ParamAttrs()) |
1047 | |
1048 | #undef __OMP_RTL_ATTRS |
1049 | #undef OMP_RTL_ATTRS |
1050 | #undef AttributeSet |
1051 | #undef EnumAttr |
1052 | #undef EnumAttrInt |
1053 | #undef ParamAttrs |
1054 | #undef AllocSizeAttr |
1055 | |
1056 | ///} |
1057 | |
1058 | /// KMP ident_t bit flags |
1059 | /// |
1060 | /// In accordance with the values in `openmp/runtime/src/kmp.h`. |
1061 | /// |
1062 | ///{ |
1063 | |
1064 | #ifndef OMP_IDENT_FLAG |
1065 | #define OMP_IDENT_FLAG(Enum, Str, Value) |
1066 | #endif |
1067 | |
1068 | #define __OMP_IDENT_FLAG(Name, Value) \ |
1069 | OMP_IDENT_FLAG(OMP_IDENT_FLAG_##Name, #Name, Value) |
1070 | |
1071 | __OMP_IDENT_FLAG(KMPC, 0x02) |
1072 | __OMP_IDENT_FLAG(ATOMIC_REDUCE, 0x10) |
1073 | __OMP_IDENT_FLAG(BARRIER_EXPL, 0x20) |
1074 | __OMP_IDENT_FLAG(BARRIER_IMPL, 0x0040) |
1075 | __OMP_IDENT_FLAG(BARRIER_IMPL_MASK, 0x01C0) |
1076 | __OMP_IDENT_FLAG(BARRIER_IMPL_FOR, 0x0040) |
1077 | __OMP_IDENT_FLAG(BARRIER_IMPL_SECTIONS, 0x00C0) |
1078 | __OMP_IDENT_FLAG(BARRIER_IMPL_SINGLE, 0x0140) |
1079 | __OMP_IDENT_FLAG(BARRIER_IMPL_WORKSHARE, 0x01C0) |
1080 | |
1081 | #undef __OMP_IDENT_FLAG |
1082 | #undef OMP_IDENT_FLAG |
1083 | |
1084 | ///} |
1085 | |
1086 | /// KMP cancel kind |
1087 | /// |
1088 | ///{ |
1089 | |
1090 | #ifndef OMP_CANCEL_KIND |
1091 | #define OMP_CANCEL_KIND(Enum, Str, DirectiveEnum, Value) |
1092 | #endif |
1093 | |
1094 | #define __OMP_CANCEL_KIND(Name, Value) \ |
1095 | OMP_CANCEL_KIND(OMP_CANCEL_KIND_##Name, #Name, OMPD_##Name, Value) |
1096 | |
1097 | __OMP_CANCEL_KIND(parallel, 1) |
1098 | __OMP_CANCEL_KIND(for, 2) |
1099 | __OMP_CANCEL_KIND(sections, 3) |
1100 | __OMP_CANCEL_KIND(taskgroup, 4) |
1101 | |
1102 | #undef __OMP_CANCEL_KIND |
1103 | #undef OMP_CANCEL_KIND |
1104 | |
1105 | ///} |
1106 | |
1107 | /// Default kinds |
1108 | /// |
1109 | ///{ |
1110 | |
1111 | #ifndef OMP_DEFAULT_KIND |
1112 | #define OMP_DEFAULT_KIND(Enum, Str) |
1113 | #endif |
1114 | |
1115 | #define __OMP_DEFAULT_KIND(Name) OMP_DEFAULT_KIND(OMP_DEFAULT_##Name, #Name) |
1116 | |
1117 | __OMP_DEFAULT_KIND(none) |
1118 | __OMP_DEFAULT_KIND(shared) |
1119 | __OMP_DEFAULT_KIND(private) |
1120 | __OMP_DEFAULT_KIND(firstprivate) |
1121 | __OMP_DEFAULT_KIND(unknown) |
1122 | |
1123 | #undef __OMP_DEFAULT_KIND |
1124 | #undef OMP_DEFAULT_KIND |
1125 | |
1126 | ///} |
1127 | |
1128 | /// Proc bind kinds |
1129 | /// |
1130 | ///{ |
1131 | |
1132 | #ifndef OMP_PROC_BIND_KIND |
1133 | #define OMP_PROC_BIND_KIND(Enum, Str, Value) |
1134 | #endif |
1135 | |
1136 | #define __OMP_PROC_BIND_KIND(Name, Value) \ |
1137 | OMP_PROC_BIND_KIND(OMP_PROC_BIND_##Name, #Name, Value) |
1138 | |
1139 | __OMP_PROC_BIND_KIND(master, 2) |
1140 | __OMP_PROC_BIND_KIND(close, 3) |
1141 | __OMP_PROC_BIND_KIND(spread, 4) |
1142 | __OMP_PROC_BIND_KIND(primary, 5) |
1143 | __OMP_PROC_BIND_KIND(default, 6) |
1144 | __OMP_PROC_BIND_KIND(unknown, 7) |
1145 | |
1146 | #undef __OMP_PROC_BIND_KIND |
1147 | #undef OMP_PROC_BIND_KIND |
1148 | |
1149 | ///} |
1150 | |
1151 | /// OpenMP context related definitions: |
1152 | /// - trait set selector |
1153 | /// - trait selector |
1154 | /// - trait property |
1155 | /// |
1156 | ///{ |
1157 | |
1158 | #ifndef OMP_TRAIT_SET |
1159 | #define OMP_TRAIT_SET(Enum, Str) |
1160 | #endif |
1161 | #ifndef OMP_TRAIT_SELECTOR |
1162 | #define OMP_TRAIT_SELECTOR(Enum, TraitSetEnum, Str, RequiresProperty) |
1163 | #endif |
1164 | #ifndef OMP_TRAIT_PROPERTY |
1165 | #define OMP_TRAIT_PROPERTY(Enum, TraitSetEnum, TraitSelectorEnum, Str) |
1166 | #endif |
1167 | #ifndef OMP_LAST_TRAIT_PROPERTY |
1168 | #define OMP_LAST_TRAIT_PROPERTY(Enum) |
1169 | #endif |
1170 | |
1171 | #define __OMP_TRAIT_SET(Name) OMP_TRAIT_SET(Name, #Name) |
1172 | #define __OMP_TRAIT_SELECTOR(TraitSet, Name, RequiresProperty) \ |
1173 | OMP_TRAIT_SELECTOR(TraitSet##_##Name, TraitSet, #Name, RequiresProperty) |
1174 | #define __OMP_TRAIT_SELECTOR_AND_PROPERTY(TraitSet, Name) \ |
1175 | OMP_TRAIT_SELECTOR(TraitSet##_##Name, TraitSet, #Name, false) \ |
1176 | OMP_TRAIT_PROPERTY(TraitSet##_##Name##_##Name, TraitSet, TraitSet##_##Name, \ |
1177 | #Name) |
1178 | #define __OMP_TRAIT_PROPERTY(TraitSet, TraitSelector, Name) \ |
1179 | OMP_TRAIT_PROPERTY(TraitSet##_##TraitSelector##_##Name, TraitSet, \ |
1180 | TraitSet##_##TraitSelector, #Name) |
1181 | |
1182 | // "invalid" must go first. |
1183 | OMP_TRAIT_SET(invalid, "invalid" ) |
1184 | OMP_TRAIT_SELECTOR(invalid, invalid, "invalid" , false) |
1185 | OMP_TRAIT_PROPERTY(invalid, invalid, invalid, "invalid" ) |
1186 | |
1187 | __OMP_TRAIT_SET(construct) |
1188 | __OMP_TRAIT_SELECTOR_AND_PROPERTY(construct, target) |
1189 | __OMP_TRAIT_SELECTOR_AND_PROPERTY(construct, teams) |
1190 | __OMP_TRAIT_SELECTOR_AND_PROPERTY(construct, parallel) |
1191 | __OMP_TRAIT_SELECTOR_AND_PROPERTY(construct, for) |
1192 | __OMP_TRAIT_SELECTOR_AND_PROPERTY(construct, simd) |
1193 | |
1194 | __OMP_TRAIT_SET(device) |
1195 | |
1196 | __OMP_TRAIT_SELECTOR(device, kind, true) |
1197 | |
1198 | __OMP_TRAIT_PROPERTY(device, kind, host) |
1199 | __OMP_TRAIT_PROPERTY(device, kind, nohost) |
1200 | __OMP_TRAIT_PROPERTY(device, kind, cpu) |
1201 | __OMP_TRAIT_PROPERTY(device, kind, gpu) |
1202 | __OMP_TRAIT_PROPERTY(device, kind, fpga) |
1203 | __OMP_TRAIT_PROPERTY(device, kind, any) |
1204 | |
1205 | __OMP_TRAIT_SELECTOR(device, arch, true) |
1206 | |
1207 | __OMP_TRAIT_PROPERTY(device, arch, arm) |
1208 | __OMP_TRAIT_PROPERTY(device, arch, armeb) |
1209 | __OMP_TRAIT_PROPERTY(device, arch, aarch64) |
1210 | __OMP_TRAIT_PROPERTY(device, arch, aarch64_be) |
1211 | __OMP_TRAIT_PROPERTY(device, arch, aarch64_32) |
1212 | __OMP_TRAIT_PROPERTY(device, arch, ppc) |
1213 | __OMP_TRAIT_PROPERTY(device, arch, ppcle) |
1214 | __OMP_TRAIT_PROPERTY(device, arch, ppc64) |
1215 | __OMP_TRAIT_PROPERTY(device, arch, ppc64le) |
1216 | __OMP_TRAIT_PROPERTY(device, arch, x86) |
1217 | __OMP_TRAIT_PROPERTY(device, arch, x86_64) |
1218 | __OMP_TRAIT_PROPERTY(device, arch, amdgcn) |
1219 | __OMP_TRAIT_PROPERTY(device, arch, nvptx) |
1220 | __OMP_TRAIT_PROPERTY(device, arch, nvptx64) |
1221 | |
1222 | __OMP_TRAIT_SET(implementation) |
1223 | |
1224 | __OMP_TRAIT_SELECTOR(implementation, vendor, true) |
1225 | |
1226 | __OMP_TRAIT_PROPERTY(implementation, vendor, amd) |
1227 | __OMP_TRAIT_PROPERTY(implementation, vendor, arm) |
1228 | __OMP_TRAIT_PROPERTY(implementation, vendor, bsc) |
1229 | __OMP_TRAIT_PROPERTY(implementation, vendor, cray) |
1230 | __OMP_TRAIT_PROPERTY(implementation, vendor, fujitsu) |
1231 | __OMP_TRAIT_PROPERTY(implementation, vendor, gnu) |
1232 | __OMP_TRAIT_PROPERTY(implementation, vendor, ibm) |
1233 | __OMP_TRAIT_PROPERTY(implementation, vendor, intel) |
1234 | __OMP_TRAIT_PROPERTY(implementation, vendor, llvm) |
1235 | __OMP_TRAIT_PROPERTY(implementation, vendor, nec) |
1236 | __OMP_TRAIT_PROPERTY(implementation, vendor, nvidia) |
1237 | __OMP_TRAIT_PROPERTY(implementation, vendor, pgi) |
1238 | __OMP_TRAIT_PROPERTY(implementation, vendor, ti) |
1239 | __OMP_TRAIT_PROPERTY(implementation, vendor, unknown) |
1240 | |
1241 | __OMP_TRAIT_SELECTOR(implementation, extension, true) |
1242 | __OMP_TRAIT_PROPERTY(implementation, extension, match_all) |
1243 | __OMP_TRAIT_PROPERTY(implementation, extension, match_any) |
1244 | __OMP_TRAIT_PROPERTY(implementation, extension, match_none) |
1245 | __OMP_TRAIT_PROPERTY(implementation, extension, disable_implicit_base) |
1246 | __OMP_TRAIT_PROPERTY(implementation, extension, allow_templates) |
1247 | __OMP_TRAIT_PROPERTY(implementation, extension, bind_to_declaration) |
1248 | |
1249 | __OMP_TRAIT_SET(user) |
1250 | |
1251 | __OMP_TRAIT_SELECTOR(user, condition, true) |
1252 | |
1253 | __OMP_TRAIT_PROPERTY(user, condition, true) |
1254 | __OMP_TRAIT_PROPERTY(user, condition, false) |
1255 | __OMP_TRAIT_PROPERTY(user, condition, unknown) |
1256 | |
1257 | __OMP_TRAIT_SELECTOR_AND_PROPERTY(construct, dispatch) |
1258 | |
1259 | // Note that we put isa last so that the other conditions are checked first. |
1260 | // This allows us to issue warnings wrt. isa only if we match otherwise. |
1261 | __OMP_TRAIT_SELECTOR(device, isa, true) |
1262 | |
1263 | // We use "__ANY" as a placeholder in the isa property to denote the |
1264 | // conceptual "any", not the literal `any` used in kind. The string we |
1265 | // we use is not important except that it will show up in diagnostics. |
1266 | OMP_TRAIT_PROPERTY(device_isa___ANY, device, device_isa, |
1267 | "<any, entirely target dependent>" ) |
1268 | |
1269 | |
1270 | #undef OMP_TRAIT_SET |
1271 | #undef __OMP_TRAIT_SET |
1272 | ///} |
1273 | |
1274 | /// Traits for the requires directive |
1275 | /// |
1276 | /// These will (potentially) become trait selectors for the OpenMP context if |
1277 | /// the OMP_REQUIRES_TRAIT macro is not defined. |
1278 | /// |
1279 | ///{ |
1280 | |
1281 | #ifdef OMP_REQUIRES_TRAIT |
1282 | #define __OMP_REQUIRES_TRAIT(Name) \ |
1283 | OMP_REQUIRES_TRAIT(OMP_REQUIRES_TRAIT_##Name, #Name) |
1284 | #else |
1285 | #define __OMP_REQUIRES_TRAIT(Name) \ |
1286 | __OMP_TRAIT_SELECTOR_AND_PROPERTY(implementation, Name) |
1287 | #endif |
1288 | |
1289 | __OMP_REQUIRES_TRAIT(unified_address) |
1290 | __OMP_REQUIRES_TRAIT(unified_shared_memory) |
1291 | __OMP_REQUIRES_TRAIT(reverse_offload) |
1292 | __OMP_REQUIRES_TRAIT(dynamic_allocators) |
1293 | __OMP_REQUIRES_TRAIT(atomic_default_mem_order) |
1294 | |
1295 | OMP_LAST_TRAIT_PROPERTY( |
1296 | implementation_atomic_default_mem_order_atomic_default_mem_order) |
1297 | |
1298 | #undef __OMP_TRAIT_SELECTOR_AND_PROPERTY |
1299 | #undef OMP_TRAIT_SELECTOR |
1300 | #undef __OMP_TRAIT_SELECTOR |
1301 | #undef OMP_TRAIT_PROPERTY |
1302 | #undef OMP_LAST_TRAIT_PROPERTY |
1303 | #undef __OMP_TRAIT_PROPERTY |
1304 | #undef __OMP_REQUIRES_TRAIT |
1305 | #undef OMP_REQUIRES_TRAIT |
1306 | ///} |
1307 | |
1308 | |
1309 | /// Assumption clauses |
1310 | /// |
1311 | ///{ |
1312 | |
1313 | #ifdef OMP_ASSUME_CLAUSE |
1314 | #define __OMP_ASSUME_CLAUSE(Identifier, StartsWith, HasDirectiveList, HasExpression) \ |
1315 | OMP_ASSUME_CLAUSE(Identifier, StartsWith, HasDirectiveList, HasExpression) |
1316 | #else |
1317 | #define __OMP_ASSUME_CLAUSE(...) |
1318 | #endif |
1319 | |
1320 | __OMP_ASSUME_CLAUSE(llvm::StringLiteral("ext_" ), true, false, false) |
1321 | __OMP_ASSUME_CLAUSE(llvm::StringLiteral("absent" ), false, true, false) |
1322 | __OMP_ASSUME_CLAUSE(llvm::StringLiteral("contains" ), false, true, false) |
1323 | __OMP_ASSUME_CLAUSE(llvm::StringLiteral("holds" ), false, false, true) |
1324 | __OMP_ASSUME_CLAUSE(llvm::StringLiteral("no_openmp" ), false, false, false) |
1325 | __OMP_ASSUME_CLAUSE(llvm::StringLiteral("no_openmp_routines" ), false, false, false) |
1326 | __OMP_ASSUME_CLAUSE(llvm::StringLiteral("no_parallelism" ), false, false, false) |
1327 | |
1328 | #undef __OMP_ASSUME_CLAUSE |
1329 | #undef OMP_ASSUME_CLAUSE |
1330 | ///} |
1331 | |