lkml.org 
[lkml]   [1996]   [Jun]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Speed of memcpy, csum_partial and csum_partial_copy

>>>>> "me" == Pedro Roque Marques <roque@di.fc.ul.pt> writes:
>>>>> "Alan" == Alan Cox <alan@lxorguk.ukuu.org.uk> writes:

Alan> There are three for TCP loopback unless someone has fiddled
Alan> recently. We copy:

sk_buff [with csum]
sk_buff to sk_buff
sk_buff-> user [skip csum]

Alan> While it seems a really dumb thing to do it makes sense as
Alan> there may be retransmissions and thus the receiver cannot go
Alan> using the queue pointers of the senders buffer copy. Its a
Alan> bad case solely applicable to loopback, and if we are going
Alan> to optimise loopback tcp we should do the solaris trick and
Alan> dump everything. In the mean time thats what AF_UNIX was
Alan> invented for.

me> On the TCP i've been seting up for 2.1 there is no need for
me> copy number 2 since the skb is cloned (the copy is restricted
me> to the skb header).

Well, i've been looking at the code and loopback does a clone of the
skb (the right thing to do) so there are really 2 data copies
only. There is the memcpy of the skb header but that does not seam
to show on Linus profile trace (it's 30-40 bytes for each 3k).

regards,
./Pedro.


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