1*4c3eb207Smrg /* This file is automatically generated. DO NOT EDIT! */ 2*4c3eb207Smrg /* Generated from: NetBSD: mknative-gcc,v 1.113 2021/04/11 01:44:14 mrg Exp */ 3*4c3eb207Smrg /* Generated from: NetBSD: mknative.common,v 1.16 2018/04/15 15:13:37 christos Exp */ 4*4c3eb207Smrg 5*4c3eb207Smrg /* Copyright (C) 2005-2020 Free Software Foundation, Inc. 6*4c3eb207Smrg Contributed by Richard Henderson <rth@redhat.com>. 7*4c3eb207Smrg 8*4c3eb207Smrg This file is part of the GNU Offloading and Multi Processing Library 9*4c3eb207Smrg (libgomp). 10*4c3eb207Smrg 11*4c3eb207Smrg Libgomp is free software; you can redistribute it and/or modify it 12*4c3eb207Smrg under the terms of the GNU General Public License as published by 13*4c3eb207Smrg the Free Software Foundation; either version 3, or (at your option) 14*4c3eb207Smrg any later version. 15*4c3eb207Smrg 16*4c3eb207Smrg Libgomp is distributed in the hope that it will be useful, but WITHOUT ANY 17*4c3eb207Smrg WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 18*4c3eb207Smrg FOR A PARTICULAR PURPOSE. See the GNU General Public License for 19*4c3eb207Smrg more details. 20*4c3eb207Smrg 21*4c3eb207Smrg Under Section 7 of GPL version 3, you are granted additional 22*4c3eb207Smrg permissions described in the GCC Runtime Library Exception, version 23*4c3eb207Smrg 3.1, as published by the Free Software Foundation. 24*4c3eb207Smrg 25*4c3eb207Smrg You should have received a copy of the GNU General Public License and 26*4c3eb207Smrg a copy of the GCC Runtime Library Exception along with this program; 27*4c3eb207Smrg see the files COPYING3 and COPYING.RUNTIME respectively. If not, see 28*4c3eb207Smrg <http://www.gnu.org/licenses/>. */ 29*4c3eb207Smrg 30*4c3eb207Smrg #ifndef _OMP_H 31*4c3eb207Smrg #define _OMP_H 1 32*4c3eb207Smrg 33*4c3eb207Smrg #ifndef _LIBGOMP_OMP_LOCK_DEFINED 34*4c3eb207Smrg #define _LIBGOMP_OMP_LOCK_DEFINED 1 35*4c3eb207Smrg /* These two structures get edited by the libgomp build process to 36*4c3eb207Smrg reflect the shape of the two types. Their internals are private 37*4c3eb207Smrg to the library. */ 38*4c3eb207Smrg 39*4c3eb207Smrg typedef struct 40*4c3eb207Smrg { 41*4c3eb207Smrg unsigned char _x[8] 42*4c3eb207Smrg __attribute__((__aligned__(8))); 43*4c3eb207Smrg } omp_lock_t; 44*4c3eb207Smrg 45*4c3eb207Smrg typedef struct 46*4c3eb207Smrg { 47*4c3eb207Smrg unsigned char _x[24] 48*4c3eb207Smrg __attribute__((__aligned__(8))); 49*4c3eb207Smrg } omp_nest_lock_t; 50*4c3eb207Smrg #endif 51*4c3eb207Smrg 52*4c3eb207Smrg typedef enum omp_sched_t 53*4c3eb207Smrg { 54*4c3eb207Smrg omp_sched_static = 1, 55*4c3eb207Smrg omp_sched_dynamic = 2, 56*4c3eb207Smrg omp_sched_guided = 3, 57*4c3eb207Smrg omp_sched_auto = 4, 58*4c3eb207Smrg omp_sched_monotonic = 0x80000000U 59*4c3eb207Smrg } omp_sched_t; 60*4c3eb207Smrg 61*4c3eb207Smrg typedef enum omp_proc_bind_t 62*4c3eb207Smrg { 63*4c3eb207Smrg omp_proc_bind_false = 0, 64*4c3eb207Smrg omp_proc_bind_true = 1, 65*4c3eb207Smrg omp_proc_bind_master = 2, 66*4c3eb207Smrg omp_proc_bind_close = 3, 67*4c3eb207Smrg omp_proc_bind_spread = 4 68*4c3eb207Smrg } omp_proc_bind_t; 69*4c3eb207Smrg 70*4c3eb207Smrg typedef enum omp_sync_hint_t 71*4c3eb207Smrg { 72*4c3eb207Smrg omp_sync_hint_none = 0, 73*4c3eb207Smrg omp_lock_hint_none = omp_sync_hint_none, 74*4c3eb207Smrg omp_sync_hint_uncontended = 1, 75*4c3eb207Smrg omp_lock_hint_uncontended = omp_sync_hint_uncontended, 76*4c3eb207Smrg omp_sync_hint_contended = 2, 77*4c3eb207Smrg omp_lock_hint_contended = omp_sync_hint_contended, 78*4c3eb207Smrg omp_sync_hint_nonspeculative = 4, 79*4c3eb207Smrg omp_lock_hint_nonspeculative = omp_sync_hint_nonspeculative, 80*4c3eb207Smrg omp_sync_hint_speculative = 8, 81*4c3eb207Smrg omp_lock_hint_speculative = omp_sync_hint_speculative 82*4c3eb207Smrg } omp_sync_hint_t; 83*4c3eb207Smrg 84*4c3eb207Smrg typedef omp_sync_hint_t omp_lock_hint_t; 85*4c3eb207Smrg 86*4c3eb207Smrg typedef struct __attribute__((__aligned__ (sizeof (void *)))) omp_depend_t 87*4c3eb207Smrg { 88*4c3eb207Smrg char __omp_depend_t__[2 * sizeof (void *)]; 89*4c3eb207Smrg } omp_depend_t; 90*4c3eb207Smrg 91*4c3eb207Smrg typedef enum omp_pause_resource_t 92*4c3eb207Smrg { 93*4c3eb207Smrg omp_pause_soft = 1, 94*4c3eb207Smrg omp_pause_hard = 2 95*4c3eb207Smrg } omp_pause_resource_t; 96*4c3eb207Smrg 97*4c3eb207Smrg #ifdef __cplusplus 98*4c3eb207Smrg extern "C" { 99*4c3eb207Smrg # define __GOMP_NOTHROW throw () 100*4c3eb207Smrg #else 101*4c3eb207Smrg # define __GOMP_NOTHROW __attribute__((__nothrow__)) 102*4c3eb207Smrg #endif 103*4c3eb207Smrg 104*4c3eb207Smrg extern void omp_set_num_threads (int) __GOMP_NOTHROW; 105*4c3eb207Smrg extern int omp_get_num_threads (void) __GOMP_NOTHROW; 106*4c3eb207Smrg extern int omp_get_max_threads (void) __GOMP_NOTHROW; 107*4c3eb207Smrg extern int omp_get_thread_num (void) __GOMP_NOTHROW; 108*4c3eb207Smrg extern int omp_get_num_procs (void) __GOMP_NOTHROW; 109*4c3eb207Smrg 110*4c3eb207Smrg extern int omp_in_parallel (void) __GOMP_NOTHROW; 111*4c3eb207Smrg 112*4c3eb207Smrg extern void omp_set_dynamic (int) __GOMP_NOTHROW; 113*4c3eb207Smrg extern int omp_get_dynamic (void) __GOMP_NOTHROW; 114*4c3eb207Smrg 115*4c3eb207Smrg extern void omp_set_nested (int) __GOMP_NOTHROW; 116*4c3eb207Smrg extern int omp_get_nested (void) __GOMP_NOTHROW; 117*4c3eb207Smrg 118*4c3eb207Smrg extern void omp_init_lock (omp_lock_t *) __GOMP_NOTHROW; 119*4c3eb207Smrg extern void omp_init_lock_with_hint (omp_lock_t *, omp_sync_hint_t) 120*4c3eb207Smrg __GOMP_NOTHROW; 121*4c3eb207Smrg extern void omp_destroy_lock (omp_lock_t *) __GOMP_NOTHROW; 122*4c3eb207Smrg extern void omp_set_lock (omp_lock_t *) __GOMP_NOTHROW; 123*4c3eb207Smrg extern void omp_unset_lock (omp_lock_t *) __GOMP_NOTHROW; 124*4c3eb207Smrg extern int omp_test_lock (omp_lock_t *) __GOMP_NOTHROW; 125*4c3eb207Smrg 126*4c3eb207Smrg extern void omp_init_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW; 127*4c3eb207Smrg extern void omp_init_nest_lock_with_hint (omp_nest_lock_t *, omp_sync_hint_t) 128*4c3eb207Smrg __GOMP_NOTHROW; 129*4c3eb207Smrg extern void omp_destroy_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW; 130*4c3eb207Smrg extern void omp_set_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW; 131*4c3eb207Smrg extern void omp_unset_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW; 132*4c3eb207Smrg extern int omp_test_nest_lock (omp_nest_lock_t *) __GOMP_NOTHROW; 133*4c3eb207Smrg 134*4c3eb207Smrg extern double omp_get_wtime (void) __GOMP_NOTHROW; 135*4c3eb207Smrg extern double omp_get_wtick (void) __GOMP_NOTHROW; 136*4c3eb207Smrg 137*4c3eb207Smrg extern void omp_set_schedule (omp_sched_t, int) __GOMP_NOTHROW; 138*4c3eb207Smrg extern void omp_get_schedule (omp_sched_t *, int *) __GOMP_NOTHROW; 139*4c3eb207Smrg extern int omp_get_thread_limit (void) __GOMP_NOTHROW; 140*4c3eb207Smrg extern void omp_set_max_active_levels (int) __GOMP_NOTHROW; 141*4c3eb207Smrg extern int omp_get_max_active_levels (void) __GOMP_NOTHROW; 142*4c3eb207Smrg extern int omp_get_level (void) __GOMP_NOTHROW; 143*4c3eb207Smrg extern int omp_get_ancestor_thread_num (int) __GOMP_NOTHROW; 144*4c3eb207Smrg extern int omp_get_team_size (int) __GOMP_NOTHROW; 145*4c3eb207Smrg extern int omp_get_active_level (void) __GOMP_NOTHROW; 146*4c3eb207Smrg 147*4c3eb207Smrg extern int omp_in_final (void) __GOMP_NOTHROW; 148*4c3eb207Smrg 149*4c3eb207Smrg extern int omp_get_cancellation (void) __GOMP_NOTHROW; 150*4c3eb207Smrg extern omp_proc_bind_t omp_get_proc_bind (void) __GOMP_NOTHROW; 151*4c3eb207Smrg extern int omp_get_num_places (void) __GOMP_NOTHROW; 152*4c3eb207Smrg extern int omp_get_place_num_procs (int) __GOMP_NOTHROW; 153*4c3eb207Smrg extern void omp_get_place_proc_ids (int, int *) __GOMP_NOTHROW; 154*4c3eb207Smrg extern int omp_get_place_num (void) __GOMP_NOTHROW; 155*4c3eb207Smrg extern int omp_get_partition_num_places (void) __GOMP_NOTHROW; 156*4c3eb207Smrg extern void omp_get_partition_place_nums (int *) __GOMP_NOTHROW; 157*4c3eb207Smrg 158*4c3eb207Smrg extern void omp_set_default_device (int) __GOMP_NOTHROW; 159*4c3eb207Smrg extern int omp_get_default_device (void) __GOMP_NOTHROW; 160*4c3eb207Smrg extern int omp_get_num_devices (void) __GOMP_NOTHROW; 161*4c3eb207Smrg extern int omp_get_num_teams (void) __GOMP_NOTHROW; 162*4c3eb207Smrg extern int omp_get_team_num (void) __GOMP_NOTHROW; 163*4c3eb207Smrg 164*4c3eb207Smrg extern int omp_is_initial_device (void) __GOMP_NOTHROW; 165*4c3eb207Smrg extern int omp_get_initial_device (void) __GOMP_NOTHROW; 166*4c3eb207Smrg extern int omp_get_max_task_priority (void) __GOMP_NOTHROW; 167*4c3eb207Smrg 168*4c3eb207Smrg extern void *omp_target_alloc (__SIZE_TYPE__, int) __GOMP_NOTHROW; 169*4c3eb207Smrg extern void omp_target_free (void *, int) __GOMP_NOTHROW; 170*4c3eb207Smrg extern int omp_target_is_present (const void *, int) __GOMP_NOTHROW; 171*4c3eb207Smrg extern int omp_target_memcpy (void *, const void *, __SIZE_TYPE__, 172*4c3eb207Smrg __SIZE_TYPE__, __SIZE_TYPE__, int, int) 173*4c3eb207Smrg __GOMP_NOTHROW; 174*4c3eb207Smrg extern int omp_target_memcpy_rect (void *, const void *, __SIZE_TYPE__, int, 175*4c3eb207Smrg const __SIZE_TYPE__ *, 176*4c3eb207Smrg const __SIZE_TYPE__ *, 177*4c3eb207Smrg const __SIZE_TYPE__ *, 178*4c3eb207Smrg const __SIZE_TYPE__ *, 179*4c3eb207Smrg const __SIZE_TYPE__ *, int, int) 180*4c3eb207Smrg __GOMP_NOTHROW; 181*4c3eb207Smrg extern int omp_target_associate_ptr (const void *, const void *, __SIZE_TYPE__, 182*4c3eb207Smrg __SIZE_TYPE__, int) __GOMP_NOTHROW; 183*4c3eb207Smrg extern int omp_target_disassociate_ptr (const void *, int) __GOMP_NOTHROW; 184*4c3eb207Smrg 185*4c3eb207Smrg extern void omp_set_affinity_format (const char *) __GOMP_NOTHROW; 186*4c3eb207Smrg extern __SIZE_TYPE__ omp_get_affinity_format (char *, __SIZE_TYPE__) 187*4c3eb207Smrg __GOMP_NOTHROW; 188*4c3eb207Smrg extern void omp_display_affinity (const char *) __GOMP_NOTHROW; 189*4c3eb207Smrg extern __SIZE_TYPE__ omp_capture_affinity (char *, __SIZE_TYPE__, const char *) 190*4c3eb207Smrg __GOMP_NOTHROW; 191*4c3eb207Smrg 192*4c3eb207Smrg extern int omp_pause_resource (omp_pause_resource_t, int) __GOMP_NOTHROW; 193*4c3eb207Smrg extern int omp_pause_resource_all (omp_pause_resource_t) __GOMP_NOTHROW; 194*4c3eb207Smrg 195*4c3eb207Smrg #ifdef __cplusplus 196*4c3eb207Smrg } 197*4c3eb207Smrg #endif 198*4c3eb207Smrg 199*4c3eb207Smrg #endif /* _OMP_H */ 200