Practical guide to predicting latency effects?

I’m looking for a practical guide – i.e. specifically NOT an academic paper, thanks anyway – to predicting the effect of increased (or decreased) latency on my user’s applications.

Specifically, I want to estimate how much improvement there will be in {bandwidth, application XYZ responsiveness, protocol ABC goodput, whatever} if I decrease the RTT between the user and the server by 10msec, or by 20msec, or by 40msec.

My googling has come up with lots of research articles discussing theoretical frameworks for figuring this out, but nothing concrete in terms of a calculator or even a rule-of-thumb.

Ultimately, this goes into MY calculator – we have the usual north-american duopoly on last-mile consumer internet here; I’m connected directly to only one of the two. There’s a cost $X to improve connectivity so I’m peered with both, how do I tell if it will be worthwhile?

Anyone got anything at all that might help me?

Thanks in advance,

-Adam

Adam Thompson
Consultant, Infrastructure Services
[MERLIN LOGO]
100 - 135 Innovation Drive
Winnipeg, MB, R3T 6A8
(204) 977-6824 or 1-800-430-6404 (MB only)
athompson@merlin.mb.ca
www.merlin.mb.ca

Hey Adam,

I’m looking for a practical guide – i.e. specifically NOT an academic paper, thanks anyway – to predicting the effect of increased (or decreased) latency on my user’s applications.

This makes answering difficult. Because you may be looking for a simpler answer than what is available.

Specifically, I want to estimate how much improvement there will be in {bandwidth, application XYZ responsiveness, protocol ABC goodput, whatever} if I decrease the RTT between the user and the server by 10msec, or by 20msec, or by 40msec.

TCP single flow throughput is TcpWindow / RTT. But all modern stacks have TcpWindow scaling (does not mean all devices have), allowing it to grow beyond the default 0xffff. However, most TCP implementations burst window growth, and window grows exponentially, this means if there is speed step-down in-transit (100G => 10G, or such, which is below sender’s rate) then transit device needs to be able to slurp the window growth amount of bytes, otherwise there is packet loss and window cannot grow and single flow cannot attain the max_rate. This means with lower RTT you need to buffer less, and devices with tiny buffers can be a lot cheaper than devices with large buffers.
Even though most OS support window scaling, there is often a limit to how large it is allowed to grow, because it’s an attack vector for DRAM DOS.

Example1, no window scaling, 100ms:
0xffff bytes / 100ms == 5.2Mbps

Example2, no window scaling, 60ms:
0xffff bytes / 60ms == 8.7Mbps

Example3, no window scaling, 5ms:
0xffff bytes / 5ms == 104.8Mbps

I believe you can multiply the numbers by 8x, to get performance your modern window users experience. As I believe windows restricts window-size by limiting allowable scaling factor to 8x.

Example4, arbitrary window scaling, 100ms, 10Gbps receiver, 100Gbps sender:
100ms * 10Gbps == 125MB, you need tcp window to scale to 125MB to achieve 10Gbps on this path, and you need step-down device 100G=>10G to have 62.5MB buffer, while window grows from 62.5MB to 125MB and sender burst that data @ 100Gbps.

The Example4 is easy to fix, by not bursting the window growth, but by rather doing bandwidth estimation and send the window growth at estimated receiver rate, removing almost all need for transit buffering. However if we were to migrate to such congestion control, classical congestion control like reno, would out-compete it during congestion, so well behaved TCP streams would get increasingly little capacity as their bandwidth estimation would keep going down, and reno would win increasingly more capacity.

Ultimately, this goes into MY calculator – we have the usual north-american duopoly on last-mile consumer internet here; I’m connected directly to only one of the two. There’s a cost $X to improve connectivity so I’m peered with both, how do I tell if it will be worthwhile?

Based on your questions I’d estimate you do not have a business case to latency optimize if it carries a premium. The most to benefit would probably be for competitive gamers, but they may be bad users on average being subsidized by light users, so it’s not entirely clear if you want to invest to attract them.

I’m looking for a practical guide – i.e. specifically NOT an academic paper,
thanks anyway – to predicting the effect of increased (or decreased) latency
on my user’s applications.

Specifically, I want to estimate how much improvement there will be in
{bandwidth, application XYZ responsiveness, protocol ABC goodput, whatever}
if I decrease the RTT between the user and the server by 10msec, or by
20msec, or by 40msec.

My googling has come up with lots of research articles discussing
theoretical frameworks for figuring this out, but nothing concrete in terms
of a calculator or even a rule-of-thumb.

There used to be network simulators that claimed to figure that out for you - eg

  "Predict application performance using real traffic in a simulated mode"

I suspect all that died after encryption became the norm, since you
have to be able to see and understand what's going on before you can
predict what will happen after changing the network. Take a look at
https://www.cse.wustl.edu/~jain/cse567-08/ftp/simtools/index.html
  the date is 2008 and all the references are http://xxx (or maybe I
can't search worth beans & missed all the current references)

Or maybe simulation just got too expensive? I vaguely recall sitting
through a few OPNET sales pitches in the early 2000s & people getting
excited about the product until they found out how much it cost :frowning:

Regards,
Lee

There is still one in XCode tools. It’s a alternate download: [https://developer.apple.com/download/more/?q=Additional%20Tools%20for%20Xcode](https://developer.apple.com/download/more/?q=Additional Tools for Xcode)
Of course this is limited to OSX, but it’s there.