Re: [PATCH] 2.6 workaround for Athlon/Opteron prefetch errata

From: Bill Davidsen
Date: Mon Sep 15 2003 - 07:21:04 EST


On Mon, 15 Sep 2003, Alan Cox wrote:

> On Llu, 2003-09-15 at 04:55, Bill Davidsen wrote:
> > 1 - the code is not needed for Athlon, prefetch is turned off on broken
> > CPUs now. A generic kernel runs fine on Athlon.
>
> That disable you talk about is bloat. It also trashes the performance of
> PIV boxes. In fact I checked out of interest - the disable hack
> currently being used is adding *over* 300 bytes to my kernel as its
> inlined repeatedly. So its larger, and it ruins performance for all
> processors.

The code to disable prefetch on Athlon is 300 bytes and hurts your PIV?
Really? I'll dig back through the code, but I recall it as adding or
deleting an entry in a table to enable prefetch. If it's affecting PIV the
code to use prefetch is seriously broken.

And since this only buys 2-5% in the kernel, I really question your "ruins
performance" claim.

>
> You also need it for userspace prefetch fault fixup for a kernel without
> CONFIG_MK7 to run stuff perfectly on Athlon.

You mean you have a program which enables userspace prefetch and doesn't
handle the botch? Or that you have programs which you compiled for PIV and
which don't run properly on Athlon. It's called misconfigured, they won't
run on 386 either.

--
bill davidsen <davidsen@xxxxxxx>
CTO, TMR Associates, Inc
Doing interesting things with little computers since 1979.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/