Opened 3 years ago

Closed 3 years ago

#13089 closed enhancement (invalid)

Implement rfc 1323 in our TCP stack

Reported by: kallisti5 Owned by: axeld
Priority: high Milestone: Unscheduled
Component: Network & Internet/TCP Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All

Description

haiku/src/add-ons/kernel/network/protocols/tcp/TCPEndpoint.cpp

Things this implementation currently doesn't implement: - TCP Extensions for High Performance, RFC 1323

We're seeing low network stack performance, missing RFC 1323 (TCP window scaling) could be a cause and should be investigated.

Change History (4)

comment:1 Changed 3 years ago by kallisti5

In my tests in #13088 we see 8MB/s transfers max in Haiku. Linux tests give 60MB/s+. If I disable TCP window scaling in Linux, i get 8MB/s transfers :-)

sudo sysctl -w net.ipv4.tcp_window_scaling=0

comment:2 Changed 3 years ago by kallisti5

Priority: normalhigh

comment:3 Changed 3 years ago by kallisti5

at face value, it looks like our tcp protocol add-on already supports window scaling...

http://cgit.haiku-os.org/haiku/tree/src/add-ons/kernel/network/protocols/tcp/TCPEndpoint.cpp#n444

FreeBSD, sys/netinet/tcp_subr.c

tcp_newtcpcb
    if (V_tcp_do_rfc1323)
        tp->t_flags = (TF_REQ_SCALE|TF_REQ_TSTMP);

FreeBSD, sys/netinet/tcp_subr.c

tcp_maxseg
        if (tp->t_flags & TF_REQ_SCALE)
            optlen += PAD(TCPOLEN_WINDOW);

comment:4 Changed 3 years ago by kallisti5

Resolution: invalid
Status: newclosed

Ok... that comment in our tcp stack is wrong. We *do* support window scaling. The code is there and I can SCP a file from another machine and get the 80MB/s (and window size multiplier is set to non-negative )

It seems the issue is wget isn't telling the OS to use window scaling?

Note: See TracTickets for help on using tickets.