mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
MDEV-8791 - AIX: Unresolved Symbols during linking
Clean-up nolock.h: it doesn't serve any purpose anymore. Appropriate code moved to x86-gcc.h and my_atomic.h. If gcc sync bultins were detected, we want to make use of them independently of __GNUC__ definition. E.g. XLC simulates those, but doesn't define __GNUC__. HS/Spider: According to AIX manual alloca() returns char*, which cannot be casted to any type with static_cast. Use explicit cast instead. MDL: Removed namemangling pragma, which didn't let MariaDB build with XLC. WSREP: _int64 seem to be conflicting name with XLC, replaced with _integer64. CONNECT: RTLD_NOLOAD is GNU extention. Removed rather meaningless check if library is loaded. Multiple dlopen()'s of the same library are permitted, and it never gets closed anyway. Except for error, which was a bug: it may close library, which can still be referenced by other subsystems. InnoDB: __ppc_get_timebase() is GNU extention. Only use it when __GLIBC__ is defined. Based on contribution by flynn1973.
This commit is contained in:
@@ -112,9 +112,26 @@
|
||||
#undef MY_ATOMIC_HAS_8_16
|
||||
|
||||
/*
|
||||
* Attempt to do atomic ops without locks
|
||||
*/
|
||||
#include "atomic/nolock.h"
|
||||
We choose implementation as follows:
|
||||
------------------------------------
|
||||
On Windows using Visual C++ the native implementation should be
|
||||
preferrable. When using gcc we prefer the Solaris implementation
|
||||
before the gcc because of stability preference, we choose gcc
|
||||
builtins if available, otherwise we choose the somewhat broken
|
||||
native x86 implementation. If neither Visual C++ or gcc we still
|
||||
choose the Solaris implementation on Solaris (mainly for SunStudio
|
||||
compilers).
|
||||
*/
|
||||
#if defined(_MSC_VER)
|
||||
#include "atomic/generic-msvc.h"
|
||||
#elif defined(HAVE_SOLARIS_ATOMIC)
|
||||
#include "atomic/solaris.h"
|
||||
#elif defined(HAVE_GCC_ATOMIC_BUILTINS)
|
||||
#include "atomic/gcc_builtins.h"
|
||||
#elif defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__))
|
||||
#include "atomic/x86-gcc.h"
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef make_atomic_cas_body
|
||||
/* nolock.h was not able to generate even a CAS function, fall back */
|
||||
|
Reference in New Issue
Block a user