[e2e] Need help: setting winsock receive low watermark while using completion port and TCP
Agarwal, Anil
Anil.Agarwal at viasat.com
Wed Aug 24 08:01:44 PDT 2005
All,
"Completion Port Model" is a Windows-specific mechanism. I suspect this
question requires some Windows expertise, rather than TCP expertise. See
links below for some info on this topic -
http://www.nevelsteen.com/coding/completion_ports_in_delphi.htm
http://www.sysinternals.com/Information/IoCompletionPorts.html
Anil Agarwal
Viasat Inc.
22300 Comsat Dr.
Clarksburg, MD 20871
(W) 301-428-4655
Anil.Agarwal at viasat.com
-----Original Message-----
From: end2end-interest-bounces at postel.org
[mailto:end2end-interest-bounces at postel.org]On Behalf Of Sireen Habib
Malik
Sent: Wednesday, August 24, 2005 9:30 AM
To: Alex Krivonosov (alexkr)
Cc: end2end-interest at postel.org
Subject: Re: [e2e] Need help: setting winsock receive low watermark
while using completion port and TCP
>
>I have a TCP connection handled by the completion port IO model. What is
>happening is in case I specify a large buffer for receiving (WSARecv),
>the operation completes only after the buffer is full, not after
>receiving about 500 bytes (a packet), so a significant delay is
>introduced. In case of small buffers, performance degrades. Any advice
>on this? Completion port model is a must.
>
>
No idea what a "completion port model" is! Here are some hints for your
question.
Large delay for large buffer is intuitively clear. For the small
buffers, consider the relation:
Maximum Window (Wmax) = BufferSize+ Capacity*RTT
(assuming error-free medium, and that Capacity is the speed of the ONLY
bottleneck).
For the more common TCP versions, Wmax should not be so small that TCP
does not get a chance to get out of the Slow-Start phase. For
triple-duplicates to arrive, there should be atleast 3 packets
successfully delievered after the lost packet. Otherwise, TCP time-outs.
If your client access-speed is small, give your connection enough
buffer-space to "atleast" get to the saw-tooth behavior.
The other possibility is that with a large buffer the connection can
operate at the Maximum Congestion Window, however, with a small buffer
you are forcing it go into the saw-tooth congestion control. So poorer
performance, relatively speaking.
Hope that helps.
--
SM
More information about the end2end-interest
mailing list