xref: /freebsd/contrib/llvm-project/openmp/runtime/src/kmp_stub.h (revision 094517119c62c23369d545a7475ae982d86330a3)
1 /*
2  * kmp_stub.h
3  */
4 
5 //===----------------------------------------------------------------------===//
6 //
7 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
8 // See https://llvm.org/LICENSE.txt for license information.
9 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
10 //
11 //===----------------------------------------------------------------------===//
12 
13 #ifndef KMP_STUB_H
14 #define KMP_STUB_H
15 
16 #ifdef __cplusplus
17 extern "C" {
18 #endif // __cplusplus
19 
20 void __kmps_set_blocktime(int arg);
21 int __kmps_get_blocktime(void);
22 void __kmps_set_dynamic(int arg);
23 int __kmps_get_dynamic(void);
24 void __kmps_set_library(int arg);
25 int __kmps_get_library(void);
26 void __kmps_set_nested(int arg);
27 int __kmps_get_nested(void);
28 void __kmps_set_stacksize(size_t arg);
29 size_t __kmps_get_stacksize();
30 
31 #ifndef KMP_SCHED_TYPE_DEFINED
32 #define KMP_SCHED_TYPE_DEFINED
33 typedef enum kmp_sched {
34   kmp_sched_static = 1, // mapped to kmp_sch_static_chunked           (33)
35   kmp_sched_dynamic = 2, // mapped to kmp_sch_dynamic_chunked          (35)
36   kmp_sched_guided = 3, // mapped to kmp_sch_guided_chunked           (36)
37   kmp_sched_auto = 4, // mapped to kmp_sch_auto                     (38)
38   kmp_sched_default = kmp_sched_static // default scheduling
39 } kmp_sched_t;
40 #endif
41 void __kmps_set_schedule(kmp_sched_t kind, int modifier);
42 void __kmps_get_schedule(kmp_sched_t *kind, int *modifier);
43 
44 kmp_proc_bind_t __kmps_get_proc_bind(void);
45 
46 double __kmps_get_wtime();
47 double __kmps_get_wtick();
48 
49 #ifdef __cplusplus
50 } // extern "C"
51 #endif // __cplusplus
52 
53 #endif // KMP_STUB_H
54 
55 // end of file //
56