xref: /freebsd/contrib/llvm-project/openmp/runtime/src/kmp_ftn_cdecl.cpp (revision 0b57cec536236d46e3dba9bd041533462f33dbb7)
1*0b57cec5SDimitry Andric /*
2*0b57cec5SDimitry Andric  * kmp_ftn_cdecl.cpp -- Fortran __cdecl linkage support for OpenMP.
3*0b57cec5SDimitry Andric  */
4*0b57cec5SDimitry Andric 
5*0b57cec5SDimitry Andric //===----------------------------------------------------------------------===//
6*0b57cec5SDimitry Andric //
7*0b57cec5SDimitry Andric // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
8*0b57cec5SDimitry Andric // See https://llvm.org/LICENSE.txt for license information.
9*0b57cec5SDimitry Andric // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
10*0b57cec5SDimitry Andric //
11*0b57cec5SDimitry Andric //===----------------------------------------------------------------------===//
12*0b57cec5SDimitry Andric 
13*0b57cec5SDimitry Andric #include "kmp.h"
14*0b57cec5SDimitry Andric #include "kmp_affinity.h"
15*0b57cec5SDimitry Andric 
16*0b57cec5SDimitry Andric #if KMP_OS_WINDOWS
17*0b57cec5SDimitry Andric #if defined KMP_WIN_CDECL || !KMP_DYNAMIC_LIB
18*0b57cec5SDimitry Andric #define KMP_FTN_ENTRIES KMP_FTN_UPPER
19*0b57cec5SDimitry Andric #endif
20*0b57cec5SDimitry Andric #elif KMP_OS_UNIX
21*0b57cec5SDimitry Andric #define KMP_FTN_ENTRIES KMP_FTN_PLAIN
22*0b57cec5SDimitry Andric #endif
23*0b57cec5SDimitry Andric 
24*0b57cec5SDimitry Andric // Note: This string is not printed when KMP_VERSION=1.
25*0b57cec5SDimitry Andric char const __kmp_version_ftncdecl[] =
26*0b57cec5SDimitry Andric     KMP_VERSION_PREFIX "Fortran __cdecl OMP support: "
27*0b57cec5SDimitry Andric #ifdef KMP_FTN_ENTRIES
28*0b57cec5SDimitry Andric                        "yes";
29*0b57cec5SDimitry Andric #define FTN_STDCALL /* no stdcall */
30*0b57cec5SDimitry Andric #include "kmp_ftn_os.h"
31*0b57cec5SDimitry Andric #include "kmp_ftn_entry.h"
32*0b57cec5SDimitry Andric #else
33*0b57cec5SDimitry Andric                        "no";
34*0b57cec5SDimitry Andric #endif /* KMP_FTN_ENTRIES */
35