asan: correct non-temporal prefetch for memory allocator
authorDmitry Vyukov <dvyukov@google.com>
Tue, 15 Jan 2013 09:03:20 +0000 (09:03 +0000)
committerDmitry Vyukov <dvyukov@google.com>
Tue, 15 Jan 2013 09:03:20 +0000 (09:03 +0000)
llvm-svn: 172522

compiler-rt/lib/sanitizer_common/sanitizer_internal_defs.h

index bd9e462..64313c0 100644 (file)
@@ -52,7 +52,7 @@ using namespace __sanitizer;  // NOLINT
 # define UNLIKELY(x)   __builtin_expect(!!(x), 0)
 # define UNUSED __attribute__((unused))
 # define USED __attribute__((used))
-# define PREFETCH(x) __builtin_prefetch(x)
+# define PREFETCH(x) __asm__("prefetchnta (%0)" : : "r" (x))
 #endif  // _MSC_VER
 
 #if defined(_WIN32)