[Gc] gcc prefetch accidentally disabled

Hans Boehm Hans.Boehm at hp.com
Wed Jul 19 22:15:27 PDT 2006


Thanks.  I checked the patch into 7.0 CVS.  If there is a 6.9 release
I'll include it there, too.

Any idea whether there is a significant performance impact?  It
seems to vary greatly across platforms.

Hans

On Thu, 20 Jul 2006, Peter Wang wrote:

> Hi, there is a typo in gcconfig.h causing gcc prefetch builtins
> not to be used on Linux x86-64.
>
> Index: include/private/gcconfig.h
> ===================================================================
> RCS file: /cvsroot/bdwgc/bdwgc/include/private/gcconfig.h,v
> retrieving revision 1.16
> diff -u -r1.16 gcconfig.h
> --- include/private/gcconfig.h  7 Jul 2006 21:14:17 -0000       1.16
> +++ include/private/gcconfig.h  20 Jul 2006 01:44:49 -0000
> @@ -1857,7 +1857,7 @@
>              extern int etext[];
>  #            define DATASTART ((ptr_t)((((word) (etext)) + 0xfff) & ~0xfff))
>  #       endif
> -#       if defined(__GNUC__) && __GNUC >= 3
> +#       if defined(__GNUC__) && __GNUC__ >= 3
>  #          define PREFETCH(x) __builtin_prefetch((x), 0, 0)
>  #          define PREFETCH_FOR_WRITE(x) __builtin_prefetch((x), 1)
>  #      endif
>
>
> _______________________________________________
> Gc mailing list
> Gc at linux.hpl.hp.com
> http://www.hpl.hp.com/hosted/linux/mail-archives/gc/
>


More information about the Gc mailing list