Re: Memory-mapping TCP/UDP send/recv buffer?
From: Stanley Feng \(MSFT\) (sfeng_at_microsoft_dot_com)
Date: 03/30/04
- Next message: nicolasr: "Detecting OS version on LAN computers"
- Previous message: jsk_at_newsgroups.nospam: "changing NAT settings using mprapi.dll"
- In reply to: Olaf van der Spek: "Re: Memory-mapping TCP/UDP send/recv buffer?"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 30 Mar 2004 12:32:15 -0800
Setting send buffer size to zero can give you zero copy on the send side.
Setting receive buffer size to zero can *not* give you zero copy on the
receive side. If data comes in and there is no pre-posted receive request,
TCP will have to buffer data in its receive window.
Article http://msdn.microsoft.com/msdnmag/issues/1000/Winsock/default.aspx,
section "Who managers the buffers" give you some brief ideas of what is
going on.
RE Memory mapping technique to achieve zero copy -
This has been widely deemed as a "software" solution to zero-copy along with
other techniques like "indicate-and-post", etc. They all have their
restrictions and limitations.
To obtain true zero copy, you will need hardware support. There are two
active tech. communities working on this -
www.rdmaconsortium.org
and the Rddp work group of IETF.
-- This posting is provided "AS IS" with no warranties, and confers no rights. Use of included script samples (if any) are subject to the terms specified at http://www.microsoft.com/info/cpyright.htm" "Olaf van der Spek" <OvdSpek@LIACS.NL> wrote in message news:%23m8kdtZFEHA.3424@tk2msftngp13.phx.gbl... > > "Louis Solomon [SteelBytes]" <louis@steelbytes.spam-is-bad.com> schreef in > bericht news:O1C9$abEEHA.3568@tk2msftngp13.phx.gbl... > > from memory, setting the socket buffer size to 0 has this affect. > > > But that has other effects as well and you still have to manage the buffers > at the application level. > > One reason memory-mapping looked nice is that you could map the buffer > twice, so that you can always do a full sequential read in a circular buffer > without dealing with the wrapping yourself. > > > -- > > Louis Solomon > > www.steelbytes.com > > > > > > "Olaf van der Spek" <OvdSpek@LIACS.NL> wrote in message > > news:u8qjPXaEEHA.3672@TK2MSFTNGP09.phx.gbl... > > > Hi, > > > > > > I'm wondering, is it possible to somehow memory-map the TCP/UDP > send/recv > > > buffers so the kernel does not have to copy data from kernel- to > > > user-space > > > and the other way around? > > > > > > -- > > > > > > Olaf van der Spek > > > Almere, Holland > > > http://xccu.sourceforge.net/ > > > > > > > > > > > >
- Next message: nicolasr: "Detecting OS version on LAN computers"
- Previous message: jsk_at_newsgroups.nospam: "changing NAT settings using mprapi.dll"
- In reply to: Olaf van der Spek: "Re: Memory-mapping TCP/UDP send/recv buffer?"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|