1#ifndef LLVM_OpenMP_INC 2#define LLVM_OpenMP_INC 3 4#include "llvm/ADT/ArrayRef.h" 5#include "llvm/ADT/BitmaskEnum.h" 6#include <cstddef> 7 8namespace llvm { 9class StringRef; 10namespace omp { 11 12LLVM_ENABLE_BITMASK_ENUMS_IN_NAMESPACE(); 13 14enum class Association { 15 Block, 16 Declaration, 17 Delimited, 18 Loop, 19 None, 20 Separating, 21}; 22 23static constexpr std::size_t Association_enumSize = 6; 24 25enum class Directive { 26 OMPD_allocate, 27 OMPD_allocators, 28 OMPD_assumes, 29 OMPD_atomic, 30 OMPD_barrier, 31 OMPD_begin_assumes, 32 OMPD_begin_declare_target, 33 OMPD_begin_declare_variant, 34 OMPD_cancel, 35 OMPD_cancellation_point, 36 OMPD_critical, 37 OMPD_declare_mapper, 38 OMPD_declare_reduction, 39 OMPD_declare_simd, 40 OMPD_declare_target, 41 OMPD_declare_variant, 42 OMPD_depobj, 43 OMPD_distribute, 44 OMPD_distribute_parallel_do, 45 OMPD_distribute_parallel_do_simd, 46 OMPD_distribute_parallel_for, 47 OMPD_distribute_parallel_for_simd, 48 OMPD_distribute_simd, 49 OMPD_do, 50 OMPD_do_simd, 51 OMPD_end_assumes, 52 OMPD_end_declare_target, 53 OMPD_end_declare_variant, 54 OMPD_end_do, 55 OMPD_end_do_simd, 56 OMPD_end_sections, 57 OMPD_end_single, 58 OMPD_end_workshare, 59 OMPD_error, 60 OMPD_flush, 61 OMPD_for, 62 OMPD_for_simd, 63 OMPD_masked_taskloop, 64 OMPD_masked_taskloop_simd, 65 OMPD_master, 66 OMPD_master_taskloop, 67 OMPD_master_taskloop_simd, 68 OMPD_metadirective, 69 OMPD_nothing, 70 OMPD_ordered, 71 OMPD_parallel, 72 OMPD_parallel_do, 73 OMPD_parallel_do_simd, 74 OMPD_parallel_for, 75 OMPD_parallel_for_simd, 76 OMPD_parallel_masked, 77 OMPD_parallel_masked_taskloop, 78 OMPD_parallel_masked_taskloop_simd, 79 OMPD_parallel_master, 80 OMPD_parallel_master_taskloop, 81 OMPD_parallel_master_taskloop_simd, 82 OMPD_parallel_sections, 83 OMPD_parallel_workshare, 84 OMPD_requires, 85 OMPD_scan, 86 OMPD_section, 87 OMPD_sections, 88 OMPD_simd, 89 OMPD_single, 90 OMPD_target, 91 OMPD_target_data, 92 OMPD_target_enter_data, 93 OMPD_target_exit_data, 94 OMPD_target_parallel, 95 OMPD_target_parallel_do, 96 OMPD_target_parallel_do_simd, 97 OMPD_target_parallel_for, 98 OMPD_target_parallel_for_simd, 99 OMPD_target_simd, 100 OMPD_target_teams, 101 OMPD_target_teams_distribute, 102 OMPD_target_teams_distribute_parallel_do, 103 OMPD_target_teams_distribute_parallel_do_simd, 104 OMPD_target_teams_distribute_parallel_for, 105 OMPD_target_teams_distribute_parallel_for_simd, 106 OMPD_target_teams_distribute_simd, 107 OMPD_target_update, 108 OMPD_task, 109 OMPD_taskgroup, 110 OMPD_taskloop, 111 OMPD_taskloop_simd, 112 OMPD_taskwait, 113 OMPD_taskyield, 114 OMPD_teams, 115 OMPD_teams_distribute, 116 OMPD_teams_distribute_parallel_do, 117 OMPD_teams_distribute_parallel_do_simd, 118 OMPD_teams_distribute_parallel_for, 119 OMPD_teams_distribute_parallel_for_simd, 120 OMPD_teams_distribute_simd, 121 OMPD_threadprivate, 122 OMPD_tile, 123 OMPD_unknown, 124 OMPD_unroll, 125 OMPD_workshare, 126 OMPD_dispatch, 127 OMPD_interop, 128 OMPD_loop, 129 OMPD_masked, 130 OMPD_parallel_loop, 131 OMPD_scope, 132 OMPD_target_parallel_loop, 133 OMPD_target_teams_loop, 134 OMPD_teams_loop, 135}; 136 137static constexpr std::size_t Directive_enumSize = 109; 138 139constexpr auto OMPD_allocate = llvm::omp::Directive::OMPD_allocate; 140constexpr auto OMPD_allocators = llvm::omp::Directive::OMPD_allocators; 141constexpr auto OMPD_assumes = llvm::omp::Directive::OMPD_assumes; 142constexpr auto OMPD_atomic = llvm::omp::Directive::OMPD_atomic; 143constexpr auto OMPD_barrier = llvm::omp::Directive::OMPD_barrier; 144constexpr auto OMPD_begin_assumes = llvm::omp::Directive::OMPD_begin_assumes; 145constexpr auto OMPD_begin_declare_target = llvm::omp::Directive::OMPD_begin_declare_target; 146constexpr auto OMPD_begin_declare_variant = llvm::omp::Directive::OMPD_begin_declare_variant; 147constexpr auto OMPD_cancel = llvm::omp::Directive::OMPD_cancel; 148constexpr auto OMPD_cancellation_point = llvm::omp::Directive::OMPD_cancellation_point; 149constexpr auto OMPD_critical = llvm::omp::Directive::OMPD_critical; 150constexpr auto OMPD_declare_mapper = llvm::omp::Directive::OMPD_declare_mapper; 151constexpr auto OMPD_declare_reduction = llvm::omp::Directive::OMPD_declare_reduction; 152constexpr auto OMPD_declare_simd = llvm::omp::Directive::OMPD_declare_simd; 153constexpr auto OMPD_declare_target = llvm::omp::Directive::OMPD_declare_target; 154constexpr auto OMPD_declare_variant = llvm::omp::Directive::OMPD_declare_variant; 155constexpr auto OMPD_depobj = llvm::omp::Directive::OMPD_depobj; 156constexpr auto OMPD_distribute = llvm::omp::Directive::OMPD_distribute; 157constexpr auto OMPD_distribute_parallel_do = llvm::omp::Directive::OMPD_distribute_parallel_do; 158constexpr auto OMPD_distribute_parallel_do_simd = llvm::omp::Directive::OMPD_distribute_parallel_do_simd; 159constexpr auto OMPD_distribute_parallel_for = llvm::omp::Directive::OMPD_distribute_parallel_for; 160constexpr auto OMPD_distribute_parallel_for_simd = llvm::omp::Directive::OMPD_distribute_parallel_for_simd; 161constexpr auto OMPD_distribute_simd = llvm::omp::Directive::OMPD_distribute_simd; 162constexpr auto OMPD_do = llvm::omp::Directive::OMPD_do; 163constexpr auto OMPD_do_simd = llvm::omp::Directive::OMPD_do_simd; 164constexpr auto OMPD_end_assumes = llvm::omp::Directive::OMPD_end_assumes; 165constexpr auto OMPD_end_declare_target = llvm::omp::Directive::OMPD_end_declare_target; 166constexpr auto OMPD_end_declare_variant = llvm::omp::Directive::OMPD_end_declare_variant; 167constexpr auto OMPD_end_do = llvm::omp::Directive::OMPD_end_do; 168constexpr auto OMPD_end_do_simd = llvm::omp::Directive::OMPD_end_do_simd; 169constexpr auto OMPD_end_sections = llvm::omp::Directive::OMPD_end_sections; 170constexpr auto OMPD_end_single = llvm::omp::Directive::OMPD_end_single; 171constexpr auto OMPD_end_workshare = llvm::omp::Directive::OMPD_end_workshare; 172constexpr auto OMPD_error = llvm::omp::Directive::OMPD_error; 173constexpr auto OMPD_flush = llvm::omp::Directive::OMPD_flush; 174constexpr auto OMPD_for = llvm::omp::Directive::OMPD_for; 175constexpr auto OMPD_for_simd = llvm::omp::Directive::OMPD_for_simd; 176constexpr auto OMPD_masked_taskloop = llvm::omp::Directive::OMPD_masked_taskloop; 177constexpr auto OMPD_masked_taskloop_simd = llvm::omp::Directive::OMPD_masked_taskloop_simd; 178constexpr auto OMPD_master = llvm::omp::Directive::OMPD_master; 179constexpr auto OMPD_master_taskloop = llvm::omp::Directive::OMPD_master_taskloop; 180constexpr auto OMPD_master_taskloop_simd = llvm::omp::Directive::OMPD_master_taskloop_simd; 181constexpr auto OMPD_metadirective = llvm::omp::Directive::OMPD_metadirective; 182constexpr auto OMPD_nothing = llvm::omp::Directive::OMPD_nothing; 183constexpr auto OMPD_ordered = llvm::omp::Directive::OMPD_ordered; 184constexpr auto OMPD_parallel = llvm::omp::Directive::OMPD_parallel; 185constexpr auto OMPD_parallel_do = llvm::omp::Directive::OMPD_parallel_do; 186constexpr auto OMPD_parallel_do_simd = llvm::omp::Directive::OMPD_parallel_do_simd; 187constexpr auto OMPD_parallel_for = llvm::omp::Directive::OMPD_parallel_for; 188constexpr auto OMPD_parallel_for_simd = llvm::omp::Directive::OMPD_parallel_for_simd; 189constexpr auto OMPD_parallel_masked = llvm::omp::Directive::OMPD_parallel_masked; 190constexpr auto OMPD_parallel_masked_taskloop = llvm::omp::Directive::OMPD_parallel_masked_taskloop; 191constexpr auto OMPD_parallel_masked_taskloop_simd = llvm::omp::Directive::OMPD_parallel_masked_taskloop_simd; 192constexpr auto OMPD_parallel_master = llvm::omp::Directive::OMPD_parallel_master; 193constexpr auto OMPD_parallel_master_taskloop = llvm::omp::Directive::OMPD_parallel_master_taskloop; 194constexpr auto OMPD_parallel_master_taskloop_simd = llvm::omp::Directive::OMPD_parallel_master_taskloop_simd; 195constexpr auto OMPD_parallel_sections = llvm::omp::Directive::OMPD_parallel_sections; 196constexpr auto OMPD_parallel_workshare = llvm::omp::Directive::OMPD_parallel_workshare; 197constexpr auto OMPD_requires = llvm::omp::Directive::OMPD_requires; 198constexpr auto OMPD_scan = llvm::omp::Directive::OMPD_scan; 199constexpr auto OMPD_section = llvm::omp::Directive::OMPD_section; 200constexpr auto OMPD_sections = llvm::omp::Directive::OMPD_sections; 201constexpr auto OMPD_simd = llvm::omp::Directive::OMPD_simd; 202constexpr auto OMPD_single = llvm::omp::Directive::OMPD_single; 203constexpr auto OMPD_target = llvm::omp::Directive::OMPD_target; 204constexpr auto OMPD_target_data = llvm::omp::Directive::OMPD_target_data; 205constexpr auto OMPD_target_enter_data = llvm::omp::Directive::OMPD_target_enter_data; 206constexpr auto OMPD_target_exit_data = llvm::omp::Directive::OMPD_target_exit_data; 207constexpr auto OMPD_target_parallel = llvm::omp::Directive::OMPD_target_parallel; 208constexpr auto OMPD_target_parallel_do = llvm::omp::Directive::OMPD_target_parallel_do; 209constexpr auto OMPD_target_parallel_do_simd = llvm::omp::Directive::OMPD_target_parallel_do_simd; 210constexpr auto OMPD_target_parallel_for = llvm::omp::Directive::OMPD_target_parallel_for; 211constexpr auto OMPD_target_parallel_for_simd = llvm::omp::Directive::OMPD_target_parallel_for_simd; 212constexpr auto OMPD_target_simd = llvm::omp::Directive::OMPD_target_simd; 213constexpr auto OMPD_target_teams = llvm::omp::Directive::OMPD_target_teams; 214constexpr auto OMPD_target_teams_distribute = llvm::omp::Directive::OMPD_target_teams_distribute; 215constexpr auto OMPD_target_teams_distribute_parallel_do = llvm::omp::Directive::OMPD_target_teams_distribute_parallel_do; 216constexpr auto OMPD_target_teams_distribute_parallel_do_simd = llvm::omp::Directive::OMPD_target_teams_distribute_parallel_do_simd; 217constexpr auto OMPD_target_teams_distribute_parallel_for = llvm::omp::Directive::OMPD_target_teams_distribute_parallel_for; 218constexpr auto OMPD_target_teams_distribute_parallel_for_simd = llvm::omp::Directive::OMPD_target_teams_distribute_parallel_for_simd; 219constexpr auto OMPD_target_teams_distribute_simd = llvm::omp::Directive::OMPD_target_teams_distribute_simd; 220constexpr auto OMPD_target_update = llvm::omp::Directive::OMPD_target_update; 221constexpr auto OMPD_task = llvm::omp::Directive::OMPD_task; 222constexpr auto OMPD_taskgroup = llvm::omp::Directive::OMPD_taskgroup; 223constexpr auto OMPD_taskloop = llvm::omp::Directive::OMPD_taskloop; 224constexpr auto OMPD_taskloop_simd = llvm::omp::Directive::OMPD_taskloop_simd; 225constexpr auto OMPD_taskwait = llvm::omp::Directive::OMPD_taskwait; 226constexpr auto OMPD_taskyield = llvm::omp::Directive::OMPD_taskyield; 227constexpr auto OMPD_teams = llvm::omp::Directive::OMPD_teams; 228constexpr auto OMPD_teams_distribute = llvm::omp::Directive::OMPD_teams_distribute; 229constexpr auto OMPD_teams_distribute_parallel_do = llvm::omp::Directive::OMPD_teams_distribute_parallel_do; 230constexpr auto OMPD_teams_distribute_parallel_do_simd = llvm::omp::Directive::OMPD_teams_distribute_parallel_do_simd; 231constexpr auto OMPD_teams_distribute_parallel_for = llvm::omp::Directive::OMPD_teams_distribute_parallel_for; 232constexpr auto OMPD_teams_distribute_parallel_for_simd = llvm::omp::Directive::OMPD_teams_distribute_parallel_for_simd; 233constexpr auto OMPD_teams_distribute_simd = llvm::omp::Directive::OMPD_teams_distribute_simd; 234constexpr auto OMPD_threadprivate = llvm::omp::Directive::OMPD_threadprivate; 235constexpr auto OMPD_tile = llvm::omp::Directive::OMPD_tile; 236constexpr auto OMPD_unknown = llvm::omp::Directive::OMPD_unknown; 237constexpr auto OMPD_unroll = llvm::omp::Directive::OMPD_unroll; 238constexpr auto OMPD_workshare = llvm::omp::Directive::OMPD_workshare; 239constexpr auto OMPD_dispatch = llvm::omp::Directive::OMPD_dispatch; 240constexpr auto OMPD_interop = llvm::omp::Directive::OMPD_interop; 241constexpr auto OMPD_loop = llvm::omp::Directive::OMPD_loop; 242constexpr auto OMPD_masked = llvm::omp::Directive::OMPD_masked; 243constexpr auto OMPD_parallel_loop = llvm::omp::Directive::OMPD_parallel_loop; 244constexpr auto OMPD_scope = llvm::omp::Directive::OMPD_scope; 245constexpr auto OMPD_target_parallel_loop = llvm::omp::Directive::OMPD_target_parallel_loop; 246constexpr auto OMPD_target_teams_loop = llvm::omp::Directive::OMPD_target_teams_loop; 247constexpr auto OMPD_teams_loop = llvm::omp::Directive::OMPD_teams_loop; 248 249enum class Clause { 250 OMPC_acq_rel, 251 OMPC_acquire, 252 OMPC_adjust_args, 253 OMPC_affinity, 254 OMPC_align, 255 OMPC_aligned, 256 OMPC_allocate, 257 OMPC_allocator, 258 OMPC_append_args, 259 OMPC_at, 260 OMPC_atomic_default_mem_order, 261 OMPC_bind, 262 OMPC_cancellation_construct_type, 263 OMPC_capture, 264 OMPC_collapse, 265 OMPC_compare, 266 OMPC_copyprivate, 267 OMPC_copyin, 268 OMPC_default, 269 OMPC_defaultmap, 270 OMPC_depend, 271 OMPC_depobj, 272 OMPC_destroy, 273 OMPC_detach, 274 OMPC_device, 275 OMPC_device_type, 276 OMPC_dist_schedule, 277 OMPC_doacross, 278 OMPC_dynamic_allocators, 279 OMPC_enter, 280 OMPC_exclusive, 281 OMPC_fail, 282 OMPC_filter, 283 OMPC_final, 284 OMPC_firstprivate, 285 OMPC_flush, 286 OMPC_from, 287 OMPC_full, 288 OMPC_grainsize, 289 OMPC_has_device_addr, 290 OMPC_hint, 291 OMPC_if, 292 OMPC_in_reduction, 293 OMPC_inbranch, 294 OMPC_inclusive, 295 OMPC_indirect, 296 OMPC_init, 297 OMPC_is_device_ptr, 298 OMPC_lastprivate, 299 OMPC_linear, 300 OMPC_link, 301 OMPC_map, 302 OMPC_match, 303 OMPC_memory_order, 304 OMPC_mergeable, 305 OMPC_message, 306 OMPC_nogroup, 307 OMPC_nowait, 308 OMPC_nocontext, 309 OMPC_nontemporal, 310 OMPC_notinbranch, 311 OMPC_novariants, 312 OMPC_num_tasks, 313 OMPC_num_teams, 314 OMPC_num_threads, 315 OMPC_ompx_attribute, 316 OMPC_ompx_dyn_cgroup_mem, 317 OMPC_ompx_bare, 318 OMPC_order, 319 OMPC_ordered, 320 OMPC_partial, 321 OMPC_priority, 322 OMPC_private, 323 OMPC_proc_bind, 324 OMPC_read, 325 OMPC_reduction, 326 OMPC_relaxed, 327 OMPC_release, 328 OMPC_reverse_offload, 329 OMPC_safelen, 330 OMPC_schedule, 331 OMPC_seq_cst, 332 OMPC_severity, 333 OMPC_shared, 334 OMPC_simd, 335 OMPC_simdlen, 336 OMPC_sizes, 337 OMPC_task_reduction, 338 OMPC_thread_limit, 339 OMPC_threadprivate, 340 OMPC_threads, 341 OMPC_to, 342 OMPC_unified_address, 343 OMPC_unified_shared_memory, 344 OMPC_uniform, 345 OMPC_unknown, 346 OMPC_untied, 347 OMPC_update, 348 OMPC_use, 349 OMPC_use_device_addr, 350 OMPC_use_device_ptr, 351 OMPC_uses_allocators, 352 OMPC_weak, 353 OMPC_when, 354 OMPC_write, 355}; 356 357static constexpr std::size_t Clause_enumSize = 105; 358 359constexpr auto OMPC_acq_rel = llvm::omp::Clause::OMPC_acq_rel; 360constexpr auto OMPC_acquire = llvm::omp::Clause::OMPC_acquire; 361constexpr auto OMPC_adjust_args = llvm::omp::Clause::OMPC_adjust_args; 362constexpr auto OMPC_affinity = llvm::omp::Clause::OMPC_affinity; 363constexpr auto OMPC_align = llvm::omp::Clause::OMPC_align; 364constexpr auto OMPC_aligned = llvm::omp::Clause::OMPC_aligned; 365constexpr auto OMPC_allocate = llvm::omp::Clause::OMPC_allocate; 366constexpr auto OMPC_allocator = llvm::omp::Clause::OMPC_allocator; 367constexpr auto OMPC_append_args = llvm::omp::Clause::OMPC_append_args; 368constexpr auto OMPC_at = llvm::omp::Clause::OMPC_at; 369constexpr auto OMPC_atomic_default_mem_order = llvm::omp::Clause::OMPC_atomic_default_mem_order; 370constexpr auto OMPC_bind = llvm::omp::Clause::OMPC_bind; 371constexpr auto OMPC_cancellation_construct_type = llvm::omp::Clause::OMPC_cancellation_construct_type; 372constexpr auto OMPC_capture = llvm::omp::Clause::OMPC_capture; 373constexpr auto OMPC_collapse = llvm::omp::Clause::OMPC_collapse; 374constexpr auto OMPC_compare = llvm::omp::Clause::OMPC_compare; 375constexpr auto OMPC_copyprivate = llvm::omp::Clause::OMPC_copyprivate; 376constexpr auto OMPC_copyin = llvm::omp::Clause::OMPC_copyin; 377constexpr auto OMPC_default = llvm::omp::Clause::OMPC_default; 378constexpr auto OMPC_defaultmap = llvm::omp::Clause::OMPC_defaultmap; 379constexpr auto OMPC_depend = llvm::omp::Clause::OMPC_depend; 380constexpr auto OMPC_depobj = llvm::omp::Clause::OMPC_depobj; 381constexpr auto OMPC_destroy = llvm::omp::Clause::OMPC_destroy; 382constexpr auto OMPC_detach = llvm::omp::Clause::OMPC_detach; 383constexpr auto OMPC_device = llvm::omp::Clause::OMPC_device; 384constexpr auto OMPC_device_type = llvm::omp::Clause::OMPC_device_type; 385constexpr auto OMPC_dist_schedule = llvm::omp::Clause::OMPC_dist_schedule; 386constexpr auto OMPC_doacross = llvm::omp::Clause::OMPC_doacross; 387constexpr auto OMPC_dynamic_allocators = llvm::omp::Clause::OMPC_dynamic_allocators; 388constexpr auto OMPC_enter = llvm::omp::Clause::OMPC_enter; 389constexpr auto OMPC_exclusive = llvm::omp::Clause::OMPC_exclusive; 390constexpr auto OMPC_fail = llvm::omp::Clause::OMPC_fail; 391constexpr auto OMPC_filter = llvm::omp::Clause::OMPC_filter; 392constexpr auto OMPC_final = llvm::omp::Clause::OMPC_final; 393constexpr auto OMPC_firstprivate = llvm::omp::Clause::OMPC_firstprivate; 394constexpr auto OMPC_flush = llvm::omp::Clause::OMPC_flush; 395constexpr auto OMPC_from = llvm::omp::Clause::OMPC_from; 396constexpr auto OMPC_full = llvm::omp::Clause::OMPC_full; 397constexpr auto OMPC_grainsize = llvm::omp::Clause::OMPC_grainsize; 398constexpr auto OMPC_has_device_addr = llvm::omp::Clause::OMPC_has_device_addr; 399constexpr auto OMPC_hint = llvm::omp::Clause::OMPC_hint; 400constexpr auto OMPC_if = llvm::omp::Clause::OMPC_if; 401constexpr auto OMPC_in_reduction = llvm::omp::Clause::OMPC_in_reduction; 402constexpr auto OMPC_inbranch = llvm::omp::Clause::OMPC_inbranch; 403constexpr auto OMPC_inclusive = llvm::omp::Clause::OMPC_inclusive; 404constexpr auto OMPC_indirect = llvm::omp::Clause::OMPC_indirect; 405constexpr auto OMPC_init = llvm::omp::Clause::OMPC_init; 406constexpr auto OMPC_is_device_ptr = llvm::omp::Clause::OMPC_is_device_ptr; 407constexpr auto OMPC_lastprivate = llvm::omp::Clause::OMPC_lastprivate; 408constexpr auto OMPC_linear = llvm::omp::Clause::OMPC_linear; 409constexpr auto OMPC_link = llvm::omp::Clause::OMPC_link; 410constexpr auto OMPC_map = llvm::omp::Clause::OMPC_map; 411constexpr auto OMPC_match = llvm::omp::Clause::OMPC_match; 412constexpr auto OMPC_memory_order = llvm::omp::Clause::OMPC_memory_order; 413constexpr auto OMPC_mergeable = llvm::omp::Clause::OMPC_mergeable; 414constexpr auto OMPC_message = llvm::omp::Clause::OMPC_message; 415constexpr auto OMPC_nogroup = llvm::omp::Clause::OMPC_nogroup; 416constexpr auto OMPC_nowait = llvm::omp::Clause::OMPC_nowait; 417constexpr auto OMPC_nocontext = llvm::omp::Clause::OMPC_nocontext; 418constexpr auto OMPC_nontemporal = llvm::omp::Clause::OMPC_nontemporal; 419constexpr auto OMPC_notinbranch = llvm::omp::Clause::OMPC_notinbranch; 420constexpr auto OMPC_novariants = llvm::omp::Clause::OMPC_novariants; 421constexpr auto OMPC_num_tasks = llvm::omp::Clause::OMPC_num_tasks; 422constexpr auto OMPC_num_teams = llvm::omp::Clause::OMPC_num_teams; 423constexpr auto OMPC_num_threads = llvm::omp::Clause::OMPC_num_threads; 424constexpr auto OMPC_ompx_attribute = llvm::omp::Clause::OMPC_ompx_attribute; 425constexpr auto OMPC_ompx_dyn_cgroup_mem = llvm::omp::Clause::OMPC_ompx_dyn_cgroup_mem; 426constexpr auto OMPC_ompx_bare = llvm::omp::Clause::OMPC_ompx_bare; 427constexpr auto OMPC_order = llvm::omp::Clause::OMPC_order; 428constexpr auto OMPC_ordered = llvm::omp::Clause::OMPC_ordered; 429constexpr auto OMPC_partial = llvm::omp::Clause::OMPC_partial; 430constexpr auto OMPC_priority = llvm::omp::Clause::OMPC_priority; 431constexpr auto OMPC_private = llvm::omp::Clause::OMPC_private; 432constexpr auto OMPC_proc_bind = llvm::omp::Clause::OMPC_proc_bind; 433constexpr auto OMPC_read = llvm::omp::Clause::OMPC_read; 434constexpr auto OMPC_reduction = llvm::omp::Clause::OMPC_reduction; 435constexpr auto OMPC_relaxed = llvm::omp::Clause::OMPC_relaxed; 436constexpr auto OMPC_release = llvm::omp::Clause::OMPC_release; 437constexpr auto OMPC_reverse_offload = llvm::omp::Clause::OMPC_reverse_offload; 438constexpr auto OMPC_safelen = llvm::omp::Clause::OMPC_safelen; 439constexpr auto OMPC_schedule = llvm::omp::Clause::OMPC_schedule; 440constexpr auto OMPC_seq_cst = llvm::omp::Clause::OMPC_seq_cst; 441constexpr auto OMPC_severity = llvm::omp::Clause::OMPC_severity; 442constexpr auto OMPC_shared = llvm::omp::Clause::OMPC_shared; 443constexpr auto OMPC_simd = llvm::omp::Clause::OMPC_simd; 444constexpr auto OMPC_simdlen = llvm::omp::Clause::OMPC_simdlen; 445constexpr auto OMPC_sizes = llvm::omp::Clause::OMPC_sizes; 446constexpr auto OMPC_task_reduction = llvm::omp::Clause::OMPC_task_reduction; 447constexpr auto OMPC_thread_limit = llvm::omp::Clause::OMPC_thread_limit; 448constexpr auto OMPC_threadprivate = llvm::omp::Clause::OMPC_threadprivate; 449constexpr auto OMPC_threads = llvm::omp::Clause::OMPC_threads; 450constexpr auto OMPC_to = llvm::omp::Clause::OMPC_to; 451constexpr auto OMPC_unified_address = llvm::omp::Clause::OMPC_unified_address; 452constexpr auto OMPC_unified_shared_memory = llvm::omp::Clause::OMPC_unified_shared_memory; 453constexpr auto OMPC_uniform = llvm::omp::Clause::OMPC_uniform; 454constexpr auto OMPC_unknown = llvm::omp::Clause::OMPC_unknown; 455constexpr auto OMPC_untied = llvm::omp::Clause::OMPC_untied; 456constexpr auto OMPC_update = llvm::omp::Clause::OMPC_update; 457constexpr auto OMPC_use = llvm::omp::Clause::OMPC_use; 458constexpr auto OMPC_use_device_addr = llvm::omp::Clause::OMPC_use_device_addr; 459constexpr auto OMPC_use_device_ptr = llvm::omp::Clause::OMPC_use_device_ptr; 460constexpr auto OMPC_uses_allocators = llvm::omp::Clause::OMPC_uses_allocators; 461constexpr auto OMPC_weak = llvm::omp::Clause::OMPC_weak; 462constexpr auto OMPC_when = llvm::omp::Clause::OMPC_when; 463constexpr auto OMPC_write = llvm::omp::Clause::OMPC_write; 464 465enum class CancellationConstructType { 466 OMP_CANCELLATION_CONSTRUCT_Parallel=1, 467 OMP_CANCELLATION_CONSTRUCT_Loop=2, 468 OMP_CANCELLATION_CONSTRUCT_Sections=3, 469 OMP_CANCELLATION_CONSTRUCT_Taskgroup=4, 470 OMP_CANCELLATION_CONSTRUCT_None=5, 471}; 472 473constexpr auto OMP_CANCELLATION_CONSTRUCT_Parallel = llvm::omp::CancellationConstructType::OMP_CANCELLATION_CONSTRUCT_Parallel; 474constexpr auto OMP_CANCELLATION_CONSTRUCT_Loop = llvm::omp::CancellationConstructType::OMP_CANCELLATION_CONSTRUCT_Loop; 475constexpr auto OMP_CANCELLATION_CONSTRUCT_Sections = llvm::omp::CancellationConstructType::OMP_CANCELLATION_CONSTRUCT_Sections; 476constexpr auto OMP_CANCELLATION_CONSTRUCT_Taskgroup = llvm::omp::CancellationConstructType::OMP_CANCELLATION_CONSTRUCT_Taskgroup; 477constexpr auto OMP_CANCELLATION_CONSTRUCT_None = llvm::omp::CancellationConstructType::OMP_CANCELLATION_CONSTRUCT_None; 478 479enum class GrainsizeType { 480 OMP_GRAINSIZE_Strict=1, 481 OMP_GRAINSIZE_Unknown=2, 482}; 483 484constexpr auto OMP_GRAINSIZE_Strict = llvm::omp::GrainsizeType::OMP_GRAINSIZE_Strict; 485constexpr auto OMP_GRAINSIZE_Unknown = llvm::omp::GrainsizeType::OMP_GRAINSIZE_Unknown; 486 487enum class MemoryOrderKind { 488 OMP_MEMORY_ORDER_SeqCst=1, 489 OMP_MEMORY_ORDER_AcqRel=2, 490 OMP_MEMORY_ORDER_Acquire=3, 491 OMP_MEMORY_ORDER_Release=4, 492 OMP_MEMORY_ORDER_Relaxed=5, 493 OMP_MEMORY_ORDER_Default=6, 494}; 495 496constexpr auto OMP_MEMORY_ORDER_SeqCst = llvm::omp::MemoryOrderKind::OMP_MEMORY_ORDER_SeqCst; 497constexpr auto OMP_MEMORY_ORDER_AcqRel = llvm::omp::MemoryOrderKind::OMP_MEMORY_ORDER_AcqRel; 498constexpr auto OMP_MEMORY_ORDER_Acquire = llvm::omp::MemoryOrderKind::OMP_MEMORY_ORDER_Acquire; 499constexpr auto OMP_MEMORY_ORDER_Release = llvm::omp::MemoryOrderKind::OMP_MEMORY_ORDER_Release; 500constexpr auto OMP_MEMORY_ORDER_Relaxed = llvm::omp::MemoryOrderKind::OMP_MEMORY_ORDER_Relaxed; 501constexpr auto OMP_MEMORY_ORDER_Default = llvm::omp::MemoryOrderKind::OMP_MEMORY_ORDER_Default; 502 503enum class NumTasksType { 504 OMP_NUMTASKS_Strict=1, 505 OMP_NUMTASKS_Unknown=2, 506}; 507 508constexpr auto OMP_NUMTASKS_Strict = llvm::omp::NumTasksType::OMP_NUMTASKS_Strict; 509constexpr auto OMP_NUMTASKS_Unknown = llvm::omp::NumTasksType::OMP_NUMTASKS_Unknown; 510 511enum class OrderKind { 512 OMP_ORDER_unknown=2, 513 OMP_ORDER_concurrent=1, 514}; 515 516constexpr auto OMP_ORDER_unknown = llvm::omp::OrderKind::OMP_ORDER_unknown; 517constexpr auto OMP_ORDER_concurrent = llvm::omp::OrderKind::OMP_ORDER_concurrent; 518 519enum class ProcBindKind { 520 OMP_PROC_BIND_primary=5, 521 OMP_PROC_BIND_master=2, 522 OMP_PROC_BIND_close=3, 523 OMP_PROC_BIND_spread=4, 524 OMP_PROC_BIND_default=6, 525 OMP_PROC_BIND_unknown=7, 526}; 527 528constexpr auto OMP_PROC_BIND_primary = llvm::omp::ProcBindKind::OMP_PROC_BIND_primary; 529constexpr auto OMP_PROC_BIND_master = llvm::omp::ProcBindKind::OMP_PROC_BIND_master; 530constexpr auto OMP_PROC_BIND_close = llvm::omp::ProcBindKind::OMP_PROC_BIND_close; 531constexpr auto OMP_PROC_BIND_spread = llvm::omp::ProcBindKind::OMP_PROC_BIND_spread; 532constexpr auto OMP_PROC_BIND_default = llvm::omp::ProcBindKind::OMP_PROC_BIND_default; 533constexpr auto OMP_PROC_BIND_unknown = llvm::omp::ProcBindKind::OMP_PROC_BIND_unknown; 534 535enum class ScheduleKind { 536 OMP_SCHEDULE_Static=2, 537 OMP_SCHEDULE_Dynamic=3, 538 OMP_SCHEDULE_Guided=4, 539 OMP_SCHEDULE_Auto=5, 540 OMP_SCHEDULE_Runtime=6, 541 OMP_SCHEDULE_Default=7, 542}; 543 544constexpr auto OMP_SCHEDULE_Static = llvm::omp::ScheduleKind::OMP_SCHEDULE_Static; 545constexpr auto OMP_SCHEDULE_Dynamic = llvm::omp::ScheduleKind::OMP_SCHEDULE_Dynamic; 546constexpr auto OMP_SCHEDULE_Guided = llvm::omp::ScheduleKind::OMP_SCHEDULE_Guided; 547constexpr auto OMP_SCHEDULE_Auto = llvm::omp::ScheduleKind::OMP_SCHEDULE_Auto; 548constexpr auto OMP_SCHEDULE_Runtime = llvm::omp::ScheduleKind::OMP_SCHEDULE_Runtime; 549constexpr auto OMP_SCHEDULE_Default = llvm::omp::ScheduleKind::OMP_SCHEDULE_Default; 550 551// Enumeration helper functions 552Directive getOpenMPDirectiveKind(llvm::StringRef Str); 553 554llvm::StringRef getOpenMPDirectiveName(Directive D); 555 556Clause getOpenMPClauseKind(llvm::StringRef Str); 557 558llvm::StringRef getOpenMPClauseName(Clause C); 559 560/// Return true if \p C is a valid clause for \p D in version \p Version. 561bool isAllowedClauseForDirective(Directive D, Clause C, unsigned Version); 562 563constexpr std::size_t getMaxLeafCount() { return 6; } 564Association getDirectiveAssociation(Directive D); 565CancellationConstructType getCancellationConstructType(StringRef); 566llvm::StringRef getOpenMPCancellationConstructTypeName(CancellationConstructType); 567GrainsizeType getGrainsizeType(StringRef); 568llvm::StringRef getOpenMPGrainsizeTypeName(GrainsizeType); 569MemoryOrderKind getMemoryOrderKind(StringRef); 570llvm::StringRef getOpenMPMemoryOrderKindName(MemoryOrderKind); 571NumTasksType getNumTasksType(StringRef); 572llvm::StringRef getOpenMPNumTasksTypeName(NumTasksType); 573OrderKind getOrderKind(StringRef); 574llvm::StringRef getOpenMPOrderKindName(OrderKind); 575ProcBindKind getProcBindKind(StringRef); 576llvm::StringRef getOpenMPProcBindKindName(ProcBindKind); 577ScheduleKind getScheduleKind(StringRef); 578llvm::StringRef getOpenMPScheduleKindName(ScheduleKind); 579 580} // namespace omp 581} // namespace llvm 582#endif // LLVM_OpenMP_INC 583