lkml.org 
[lkml]   [2000]   [Sep]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: zero-copy TCP

The entire Linux Network subsystem needs an overhaul. The code copies
data all over the place. I am at present pulling it apart and porting it
to MANOS, and what a mess indeed. In NetWare, the only time data ever
gets copied from incoming packets is:

1. A copy to userspace at a stream head.
2. An incoming write that gets copied into the file cache.

Reads from cache are never copied. In fact, the network server locks a
file cache page and sends it unaltered to the network drivers and DMA's
directly from it. Since NetWare has WTD's these I/O requests get
processed at the highest possible priority. In networking, the enemy is
LATENCY for fast performance. That's why NetWare can handle 5000 users
and Linux barfs on 100 in similiar tests. Copying increases latency,
and the long code paths in the Linux Network layer.

Jeff

Jes Sorensen wrote:
>
> >>>>> "Ingo" == Ingo Molnar <mingo@elte.hu> writes:
>
> Ingo> On Sat, 2 Sep 2000, Dan Maas wrote:
>
> >> There are various other tricks that can be done to speed up network
> >> servers, like passing files directly from the buffer cache to the
> >> network card. This one is currently frowned upon by the Linux
> >> community, [...]
>
> Ingo> FYI, the TUX patch (released yesterday) includes a lightweight
> Ingo> zero-copy TCP implementation for the 2.4 Linux kernel. The
> Ingo> interface is not yet exported to user-space (simply because TUX
> Ingo> uses it from kernel-space so the user-space bits were not
> Ingo> needed), but the network driver framework and TCP-stack bits are
> Ingo> there, so the hard part is done. The two most widely used
> Ingo> gigabit drivers are 'converted' to support zero-copy, the
> Ingo> SysKonnect and the Acenic driver (the modifications are well
> Ingo> tested). I plan to add the user-space bits in the near future.
>
> Could you comment a bit on the design you used or do I have to go read
> the code? Some of us had a good chat at OLS about how to do zero copy
> TCP xmits by kiobufifying the skb's.
>
> Jes
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> Please read the FAQ at http://www.tux.org/lkml/
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:38    [W:0.149 / U:24.372 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site