Re: recent fixes in devel tree

2 messages, 2 authors, 2000-09-16 · open the first message on its own page

Re: recent fixes in devel tree

From: Holger Bettag <hidden>
Date: 2000-09-16 11:16:48

Paul Mackerras [off-list ref] writes:

[...]
Copy speedups using cache prefetching.  I found that on the G4,
using the dcbt instruction to prefetch data into the cache in the
inner loop of copy_to/from_user and copy_page gives very substantial
speedups.  For example, `cat largefile >/dev/null' used to go at
around 140MB/s on my 450MHz G4 cube (assuming largefile fits into
memory) and now it goes at around 400MB/s. :-) Interestingly, dcbt
makes no difference at all on the G3 machines I tried.  I presume it
is a no-op on the G3.
It shouldn't be a no-op on the G3, although the cache touch
instructions can be "turned off" globally by a bit in some HID
register.

There is one more quirk concerning memory bandwidth of the G4:
prefetching operations (both dcbt and dst) seem to be treated more
favourably by the bus interface than fetches generated by actual load
instructions, i.e. you get higher bandwidth by using cache touch
instructions even if the code consists of an endless sequence of, say,
vector loads, which should easily consume all available bandwidth on
their own.

I assume that the G4 does use pipelined, split transactions on the
MPX bus for prefetches, but not for actual loads. Maybe this is a
tradeoff between latency and throughput, or maybe it is somehow
related to a known bug in the G4's implementation of the MPX
protocol (namely, the number of outstanding transactions must be
limited to four or five, instead of the specified six).

  Holger

P.S.: BTW, is there a general consensus wether or not AltiVec
      enhancements in the kernel would be a good thing or too much
      hassle, or of interest for too few people, etc.? I don't think
      that the currently available patched gcc is reliable enough yet,
      but one day it might be.

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

Re: recent fixes in devel tree

From: Dan Malek <hidden>
Date: 2000-09-16 14:25:35

Holger Bettag wrote:
P.S.: BTW, is there a general consensus wether or not AltiVec
      enhancements in the kernel would be a good thing.....

What kind of enhancements?  I do a fair amount of audio/video
processing on my G4 with the current gcc/Altivec tools.  I found only
one minor bug in the exception handler that I fixed a while back.

We have been discussing some of the vector load/store/touch as both
enhancements to the kernel and glibc.  It is a little more challenging
in the kernel because we would have to then keep some of the vector
context around for the kernel, but in a very constrained case we could
probably get some speed ups with that.


	-- Dan

** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help