forked from OSchip/llvm-project
[sanitizer][mips] Fix the condition to include sanitizer_atomic_clang_mips.h
The Glibc header [1] define _ABIO32 unconditionally on MIPS. So we need to compare _MIPS_SIM and _ABIO32 to know if we are actually building for MIPS32. Using sanitizer_atomic_clang_mips.h can cause test failures and hangs on MIPS64. [1]: https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/mips/sgidefs.h Reviewed By: dvyukov, vitalybuka, MaskRay Differential Revision: https://reviews.llvm.org/D121207
This commit is contained in:
parent
341623653d
commit
db7bca2863
|
@ -95,8 +95,8 @@ inline bool atomic_compare_exchange_weak(volatile T *a,
|
|||
// This include provides explicit template instantiations for atomic_uint64_t
|
||||
// on MIPS32, which does not directly support 8 byte atomics. It has to
|
||||
// proceed the template definitions above.
|
||||
#if defined(_MIPS_SIM) && defined(_ABIO32)
|
||||
#include "sanitizer_atomic_clang_mips.h"
|
||||
#if defined(_MIPS_SIM) && defined(_ABIO32) && _MIPS_SIM == _ABIO32
|
||||
# include "sanitizer_atomic_clang_mips.h"
|
||||
#endif
|
||||
|
||||
#undef ATOMIC_ORDER
|
||||
|
|
Loading…
Reference in New Issue