Improved copy_page() function, about 30% speed up for mpc860!
Paul Mackerras
paulus at samba.org
Tue Mar 4 11:19:11 EST 2003
Dan Malek writes:
> And don't forget....many applications aren't heavily 'copy-centric' and it
> may be beneficial to not blow away the caches in those cases. That is, if
Using dcbz on the destination won't blow away the caches any more than
doing the copy without dcbz would anyway.
The thing you have to be careful of when using dcbz, particularly when
you are dbcz'ing one or more cache lines ahead, is that you only dcbz
cache lines that are completely contained within the destination area.
That introduces extra complexity and makes the code bigger, so you
have to be careful that you don't make small copies slower.
I did some measurements once and found that almost all of the copies
in the kernel (memcpy and copy_tofrom_user) were either relatively
small, i.e. less than 256 bytes, or were page-sized and page-aligned.
In the optimized copy routines I did in the ppc64 kernel.
Paul.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
More information about the Linuxppc-embedded
mailing list