diff options
author | Jonathan Peyton <jonathan.l.peyton@intel.com> | 2015-05-26 17:32:53 +0000 |
---|---|---|
committer | Jonathan Peyton <jonathan.l.peyton@intel.com> | 2015-05-26 17:32:53 +0000 |
commit | 99016999703149a91127bc811d81a356441b9bfd (patch) | |
tree | df1777135854d05a67767f1cda46a24d9f89481c /openmp/runtime/src | |
parent | 5b30b0aaaeeb2a5bf67f2883eb3cd3787be44756 (diff) | |
download | bcm5719-llvm-99016999703149a91127bc811d81a356441b9bfd.tar.gz bcm5719-llvm-99016999703149a91127bc811d81a356441b9bfd.zip |
Change macro GUIDEDLL_EXPORTS to KMP_DYNAMIC_LIB
A while back, Hal suggested updating the GUIDEDLL_EXPORTS macro guard to
a more descriptive name. It represents a dynamic library build so
KMP_DYNAMIC_LIB is a more suitable name.
Differential Revision: http://reviews.llvm.org/D9899
llvm-svn: 238221
Diffstat (limited to 'openmp/runtime/src')
-rw-r--r-- | openmp/runtime/src/kmp_ftn_cdecl.c | 2 | ||||
-rw-r--r-- | openmp/runtime/src/kmp_runtime.c | 12 | ||||
-rw-r--r-- | openmp/runtime/src/kmp_version.c | 2 | ||||
-rw-r--r-- | openmp/runtime/src/makefile.mk | 2 | ||||
-rw-r--r-- | openmp/runtime/src/z_Windows_NT_util.c | 4 |
5 files changed, 11 insertions, 11 deletions
diff --git a/openmp/runtime/src/kmp_ftn_cdecl.c b/openmp/runtime/src/kmp_ftn_cdecl.c index b8f00685830..51fa1bf8954 100644 --- a/openmp/runtime/src/kmp_ftn_cdecl.c +++ b/openmp/runtime/src/kmp_ftn_cdecl.c @@ -16,7 +16,7 @@ #include "kmp.h" #if KMP_OS_WINDOWS -# if defined KMP_WIN_CDECL || !defined GUIDEDLL_EXPORTS +# if defined KMP_WIN_CDECL || !defined KMP_DYNAMIC_LIB # define KMP_FTN_ENTRIES KMP_FTN_UPPER # endif #elif KMP_OS_UNIX diff --git a/openmp/runtime/src/kmp_runtime.c b/openmp/runtime/src/kmp_runtime.c index 195f8a1db61..46a50e07c91 100644 --- a/openmp/runtime/src/kmp_runtime.c +++ b/openmp/runtime/src/kmp_runtime.c @@ -557,7 +557,7 @@ static void __kmp_fini_allocator_thread() {} /* ------------------------------------------------------------------------ */ -#ifdef GUIDEDLL_EXPORTS +#ifdef KMP_DYNAMIC_LIB # if KMP_OS_WINDOWS @@ -681,7 +681,7 @@ DllMain( HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpReserved ) { } # endif /* KMP_OS_WINDOWS */ -#endif /* GUIDEDLL_EXPORTS */ +#endif /* KMP_DYNAMIC_LIB */ /* ------------------------------------------------------------------------ */ @@ -3507,7 +3507,7 @@ __kmp_expand_threads(int nWish, int nNeed) { if(nNeed > nWish) /* normalize the arguments */ nWish = nNeed; -#if KMP_OS_WINDOWS && !defined GUIDEDLL_EXPORTS +#if KMP_OS_WINDOWS && !defined KMP_DYNAMIC_LIB /* only for Windows static library */ /* reclaim array entries for root threads that are already dead */ added = __kmp_reclaim_dead_roots(); @@ -5611,7 +5611,7 @@ __kmp_internal_end_dest( void *specific_gtid ) __kmp_internal_end_thread( gtid ); } -#if KMP_OS_UNIX && GUIDEDLL_EXPORTS +#if KMP_OS_UNIX && KMP_DYNAMIC_LIB // 2009-09-08 (lev): It looks the destructor does not work. In simple test cases destructors work // perfectly, but in real libiomp5.so I have no evidence it is ever called. However, -fini linker @@ -6072,7 +6072,7 @@ __kmp_internal_end_thread( int gtid_req ) return; } } - #if defined GUIDEDLL_EXPORTS + #if defined KMP_DYNAMIC_LIB // AC: lets not shutdown the Linux* OS dynamic library at the exit of uber thread, // because we will better shutdown later in the library destructor. // The reason of this change is performance problem when non-openmp thread @@ -6519,7 +6519,7 @@ __kmp_do_serial_initialize( void ) __kmp_register_atfork(); #endif - #if ! defined GUIDEDLL_EXPORTS + #if ! defined KMP_DYNAMIC_LIB { /* Invoke the exit handler when the program finishes, only for static library. For dynamic library, we already have _fini and DllMain. diff --git a/openmp/runtime/src/kmp_version.c b/openmp/runtime/src/kmp_version.c index 581909a7fde..42f0a0f836f 100644 --- a/openmp/runtime/src/kmp_version.c +++ b/openmp/runtime/src/kmp_version.c @@ -69,7 +69,7 @@ #endif // KMP_LIB_TYPE // Detect link type (static, dynamic). -#ifdef GUIDEDLL_EXPORTS +#ifdef KMP_DYNAMIC_LIB #define KMP_LINK_TYPE "dynamic" #else #define KMP_LINK_TYPE "static" diff --git a/openmp/runtime/src/makefile.mk b/openmp/runtime/src/makefile.mk index 1d1b9aa694a..dfbd8dad3f4 100644 --- a/openmp/runtime/src/makefile.mk +++ b/openmp/runtime/src/makefile.mk @@ -513,7 +513,7 @@ ifeq "$(os)" "win" cpp-flags += -D KMP_WIN_CDECL endif ifeq "$(LINK_TYPE)" "dyna" - cpp-flags += -D GUIDEDLL_EXPORTS + cpp-flags += -D KMP_DYNAMIC_LIB endif ifeq "$(LIB_TYPE)" "stub" cpp-flags += -D KMP_STUB diff --git a/openmp/runtime/src/z_Windows_NT_util.c b/openmp/runtime/src/z_Windows_NT_util.c index 01a0156bff1..d60f3c50905 100644 --- a/openmp/runtime/src/z_Windows_NT_util.c +++ b/openmp/runtime/src/z_Windows_NT_util.c @@ -835,7 +835,7 @@ __kmp_runtime_initialize( void ) return; }; -#if GUIDEDLL_EXPORTS +#if KMP_DYNAMIC_LIB /* Pin dynamic library for the lifetime of application */ { // First, turn off error message boxes @@ -863,7 +863,7 @@ __kmp_runtime_initialize( void ) #endif /* KMP_ARCH_X86 || KMP_ARCH_X86_64 */ /* Set up minimum number of threads to switch to TLS gtid */ - #if KMP_OS_WINDOWS && ! defined GUIDEDLL_EXPORTS + #if KMP_OS_WINDOWS && ! defined KMP_DYNAMIC_LIB // Windows* OS, static library. /* New thread may use stack space previously used by another thread, currently terminated. |