mirror of
https://github.com/zebrajr/postgres.git
synced 2025-12-07 12:20:31 +01:00
Fix memory barrier support on icc on ia64, 2nd attempt.
Itanium doesn't have the mfence instruction - that's a 386 thing. Use the "mf" instruction instead. This reverts the previous commit to add "#include <emmintrinsic.h>"; the problem was not with a missing #include.
This commit is contained in:
parent
6052bceba5
commit
e5592c61ad
|
|
@ -53,8 +53,12 @@ extern slock_t dummy_spinlock;
|
||||||
/*
|
/*
|
||||||
* icc defines __GNUC__, but doesn't support gcc's inline asm syntax
|
* icc defines __GNUC__, but doesn't support gcc's inline asm syntax
|
||||||
*/
|
*/
|
||||||
#include <emmintrin.h>
|
#if defined(__ia64__) || defined(__ia64)
|
||||||
|
#define pg_memory_barrier() __mf()
|
||||||
|
#else if defined(__i386__) || defined(__x86_64__)
|
||||||
#define pg_memory_barrier() _mm_mfence()
|
#define pg_memory_barrier() _mm_mfence()
|
||||||
|
#endif
|
||||||
|
|
||||||
#define pg_compiler_barrier() __memory_barrier()
|
#define pg_compiler_barrier() __memory_barrier()
|
||||||
#elif defined(__GNUC__)
|
#elif defined(__GNUC__)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user