lkml.org 
[lkml]   [2002]   [Nov]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] 2/2 2.5.45 cleanup & add original copy_ro/from_user
Date
On 2 November 2002 08:58, Andi Kleen wrote:
> Andrew Morton <akpm@digeo.com> writes:
> > (That is, using the movnta instructions for well-aligned copies
> > and clears so that we don't read the destination memory while
> > overwriting it).
>
> I did some experiments with movnta and it was near always a loss for
> memcpy/copy_*_user type stuff. The reason is that it flushes the
> destination out of cache and when you try to read it afterwards for
> some reason (which happens often - e.g. most copy_*_user uses
> actually do access it afterwards) then you eat a full cache miss for
> them and that is costly and kills all other advantages.

That depends on size. If you do huge memcpy (say 1 mb) it still
wins by wide margin. Not that we do such huge operations often,
but code can check size and pick different routines for small
and big blocks
--
vda
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:30    [W:0.065 / U:0.152 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site