[PATCH] data prefetch support and __builtin_prefetch (take 2)

Richard Henderson rth@redhat.com
Wed Dec 5 13:06:00 GMT 2001


On Wed, Dec 05, 2001 at 05:49:49PM +0000, Richard Earnshaw wrote:
> It might also be possible to do some overloading (ie allow both 
> __builtin_prefetch(addr) and __builtin_prefetch(addr, rw, loc) ), but I 
> don't know if the compiler will allow that.

It will.  You prototype the function as prefetch(void *, ...) and 
then check the subsequent argument in the builtin expander.

In fact, I think this is a useful thing anyway, since I doubt that
most folks will know what to put for the temporal locality argument.


r~



More information about the Gcc-patches mailing list