diff options
author | hjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-04-07 23:06:50 +0000 |
---|---|---|
committer | hjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-04-07 23:06:50 +0000 |
commit | 8fac2565cf5ef89c4485eff482ffc65277e71dd6 (patch) | |
tree | b14a2e1925835690b0117b02622292e1591b3335 | |
parent | 900b6caad479de5fd2af66391bb9f7ce4b9a2e65 (diff) | |
download | gcc-8fac2565cf5ef89c4485eff482ffc65277e71dd6.tar.gz |
2004-04-07 H.J. Lu <hongjiu.lu@intel.com>
* include/private/gcconfig.h (PREFETCH): Use __builtin_prefetch
for gcc >= 3.0.
(PREFETCH_FOR_WRITE): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-3_3-branch@80491 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | boehm-gc/ChangeLog | 6 | ||||
-rw-r--r-- | boehm-gc/include/private/gcconfig.h | 8 |
2 files changed, 10 insertions, 4 deletions
diff --git a/boehm-gc/ChangeLog b/boehm-gc/ChangeLog index 31d9cab33a8..e386223bc6f 100644 --- a/boehm-gc/ChangeLog +++ b/boehm-gc/ChangeLog @@ -1,3 +1,9 @@ +2004-04-07 H.J. Lu <hongjiu.lu@intel.com> + + * include/private/gcconfig.h (PREFETCH): Use __builtin_prefetch + for gcc >= 3.0. + (PREFETCH_FOR_WRITE): Likewise. + 2004-02-14 Release Manager * GCC 3.3.3 Released. diff --git a/boehm-gc/include/private/gcconfig.h b/boehm-gc/include/private/gcconfig.h index b07d4b9a18e..3ecbcdf5ffe 100644 --- a/boehm-gc/include/private/gcconfig.h +++ b/boehm-gc/include/private/gcconfig.h @@ -1667,10 +1667,10 @@ extern int etext[]; # define DATASTART ((ptr_t)((((word) (etext)) + 0xfff) & ~0xfff)) # endif -# define PREFETCH(x) \ - __asm__ __volatile__ (" prefetch %0": : "m"(*(char *)(x))) -# define PREFETCH_FOR_WRITE(x) \ - __asm__ __volatile__ (" prefetchw %0": : "m"(*(char *)(x))) +# if defined(__GNUC__) && __GNUC__ >= 3 +# define PREFETCH(x) __builtin_prefetch ((x), 0, 0) +# define PREFETCH_FOR_WRITE(x) __builtin_prefetch ((x), 1) +# endif # endif # endif |