Index: base/atomicops.h |
diff --git a/base/atomicops.h b/base/atomicops.h |
index de5554ebb9bea28c529e0ef38050320b69b4367d..13fb7e412ded1e0abbde87362b52c8900d58bc42 100644 |
--- a/base/atomicops.h |
+++ b/base/atomicops.h |
@@ -31,6 +31,15 @@ |
#include "base/basictypes.h" |
#include "build/build_config.h" |
+#if defined(OS_WIN) && defined(ARCH_CPU_64_BITS) |
+// windows.h #defines this (only on x64). This causes problems because the |
+// public API also uses MemoryBarrier at the public name for this fence. So, on |
+// X64, undef it, and call its documented |
+// (http://msdn.microsoft.com/en-us/library/windows/desktop/ms684208.aspx) |
+// implementation directly. |
+#undef MemoryBarrier |
+#endif |
+ |
namespace base { |
namespace subtle { |