1/* 2 * Copyright (c) 2014 ETH Zurich. 3 * All rights reserved. 4 * 5 * This file is distributed under the terms in the attached LICENSE file. 6 * If you do not find this file, copies can be found by writing to: 7 * ETH Zurich D-INFK, Universitaetsstrasse 64, CH-8092 Zurich. Attn: Systems Group. 8 */ 9 10#ifndef __GOMP_ABI_H 11#define __GOMP_ABI_H 12 13/* This header specifies the function signatures of the GOMP library as described 14 * in the GCC runtime library 15 * 16 * These functions have to be implemented in order to give full OpenMP support 17 */ 18 19/* atomic.c */ 20void GOMP_atomic_start(void); 21void GOMP_atomic_end(void); 22 23/* barrier.c */ 24void GOMP_barrier(void); 25bool GOMP_barrier_cancel (void); 26 27/* critical.c */ 28void GOMP_critical_start(void); 29void GOMP_critical_end(void); 30void GOMP_critical_name_start(void **pptr); 31void GOMP_critical_name_end(void **pptr); 32 33/* loop.c */ 34bool GOMP_loop_static_start (long, long, long, long, long *, long *); 35bool GOMP_loop_dynamic_start (long, long, long, long, long *, long *); 36bool GOMP_loop_guided_start (long, long, long, long, long *, long *); 37bool GOMP_loop_runtime_start (long, long, long, long *, long *); 38 39bool GOMP_loop_ordered_static_start (long, long, long, long, 40 long *, long *); 41bool GOMP_loop_ordered_dynamic_start (long, long, long, long, 42 long *, long *); 43bool GOMP_loop_ordered_guided_start (long, long, long, long, 44 long *, long *); 45bool GOMP_loop_ordered_runtime_start (long, long, long, long *, long *); 46 47bool GOMP_loop_static_next (long *, long *); 48bool GOMP_loop_dynamic_next (long *, long *); 49bool GOMP_loop_guided_next (long *, long *); 50bool GOMP_loop_runtime_next (long *, long *); 51 52bool GOMP_loop_ordered_static_next (long *, long *); 53bool GOMP_loop_ordered_dynamic_next (long *, long *); 54bool GOMP_loop_ordered_guided_next (long *, long *); 55bool GOMP_loop_ordered_runtime_next (long *, long *); 56 57void GOMP_parallel_loop_static_start (void (*)(void *), void *, 58 unsigned, long, long, long, long); 59void GOMP_parallel_loop_dynamic_start (void (*)(void *), void *, 60 unsigned, long, long, long, long); 61void GOMP_parallel_loop_guided_start (void (*)(void *), void *, 62 unsigned, long, long, long, long); 63void GOMP_parallel_loop_runtime_start (void (*)(void *), void *, 64 unsigned, long, long, long); 65void GOMP_parallel_loop_static (void (*)(void *), void *, 66 unsigned, long, long, long, long, 67 unsigned); 68void GOMP_parallel_loop_dynamic (void (*)(void *), void *, 69 unsigned, long, long, long, long, 70 unsigned); 71void GOMP_parallel_loop_guided (void (*)(void *), void *, 72 unsigned, long, long, long, long, 73 unsigned); 74void GOMP_parallel_loop_runtime (void (*)(void *), void *, 75 unsigned, long, long, long, 76 unsigned); 77 78void GOMP_loop_end (void); 79void GOMP_loop_end_nowait (void); 80bool GOMP_loop_end_cancel (void); 81 82/* ordered.c */ 83void GOMP_ordered_start(void); 84void GOMP_ordered_end(void); 85 86/* parallel.c */ 87void GOMP_parallel(void (*fn)(void *), void *data, unsigned num_threads, unsigned int flags); 88void GOMP_parallel_start(void (*) (void *), void *, unsigned); 89void GOMP_parallel_end(void); 90bool GOMP_cancel(int which, bool do_cancel); 91bool GOMP_cancellation_point(int which); 92 93/* sections.c */ 94unsigned GOMP_sections_start(unsigned count); 95unsigned GOMP_sections_next(void); 96void GOMP_parallel_sections_start(void (*fn)(void *), void *data, 97 unsigned num_threads, unsigned count); 98void GOMP_parallel_sections(void (*fn)(void *), void *data, unsigned num_threads, 99 unsigned count, unsigned flags); 100void GOMP_sections_end(void); 101bool GOMP_sections_end_cancel(void); 102void GOMP_sections_end_nowait(void); 103 104/* single.c */ 105bool GOMP_single_start(void); 106void *GOMP_single_copy_start (void); 107void GOMP_single_copy_end (void *data); 108 109/* target.c */ 110void GOMP_target (int, void (*) (void *), const void *, 111 size_t, void **, size_t *, unsigned char *); 112void GOMP_target_data (int, const void *, 113 size_t, void **, size_t *, unsigned char *); 114void GOMP_target_end_data (void); 115void GOMP_target_update (int, const void *, 116 size_t, void **, size_t *, unsigned char *); 117void GOMP_teams (unsigned int, unsigned int); 118 119#endif /* __GOMP_ABI_H */ 120