From 874f68bdbefcd9bc9d6e4344edab42c0eaae49b3 Mon Sep 17 00:00:00 2001 From: Andi Kleen Date: Fri, 19 Oct 2007 20:35:04 +0200 Subject: [PATCH] --- yaml --- r: 71702 b: refs/heads/master c: ab483570a13be2a34c0502b166df8f8b26802103 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/include/asm-x86/processor_64.h | 6 ------ trunk/include/linux/prefetch.h | 9 ++------- 3 files changed, 3 insertions(+), 14 deletions(-) diff --git a/[refs] b/[refs] index d188745daeb0..d770ef2e4cf4 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 124d395fd05efb65d00ca23c7bcc86c272bd8813 +refs/heads/master: ab483570a13be2a34c0502b166df8f8b26802103 diff --git a/trunk/include/asm-x86/processor_64.h b/trunk/include/asm-x86/processor_64.h index f422becbddd9..398c39160fce 100644 --- a/trunk/include/asm-x86/processor_64.h +++ b/trunk/include/asm-x86/processor_64.h @@ -390,12 +390,6 @@ static inline void sync_core(void) asm volatile("cpuid" : "=a" (tmp) : "0" (1) : "ebx","ecx","edx","memory"); } -#define ARCH_HAS_PREFETCH -static inline void prefetch(void *x) -{ - asm volatile("prefetcht0 (%0)" :: "r" (x)); -} - #define ARCH_HAS_PREFETCHW 1 static inline void prefetchw(void *x) { diff --git a/trunk/include/linux/prefetch.h b/trunk/include/linux/prefetch.h index 1adfe668d031..af7c36a5a521 100644 --- a/trunk/include/linux/prefetch.h +++ b/trunk/include/linux/prefetch.h @@ -34,17 +34,12 @@ */ -/* - * These cannot be do{}while(0) macros. See the mental gymnastics in - * the loop macro. - */ - #ifndef ARCH_HAS_PREFETCH -static inline void prefetch(const void *x) {;} +#define prefetch(x) __builtin_prefetch(x) #endif #ifndef ARCH_HAS_PREFETCHW -static inline void prefetchw(const void *x) {;} +#define prefetchw(x) __builtin_prefetch(x,1) #endif #ifndef ARCH_HAS_SPINLOCK_PREFETCH