forked from quic-go/quic-go
increase send and receive buffer size to 7 MiB (#4455)
This increases throughput on high-bandwidth connections.
7 MB is the value that WireGuard uses, see
f26efb65f2
for details.
This commit is contained in:
@@ -3,10 +3,10 @@ package protocol
|
||||
import "time"
|
||||
|
||||
// DesiredReceiveBufferSize is the kernel UDP receive buffer size that we'd like to use.
|
||||
const DesiredReceiveBufferSize = (1 << 20) * 2 // 2 MB
|
||||
const DesiredReceiveBufferSize = (1 << 20) * 7 // 7 MB
|
||||
|
||||
// DesiredSendBufferSize is the kernel UDP send buffer size that we'd like to use.
|
||||
const DesiredSendBufferSize = (1 << 20) * 2 // 2 MB
|
||||
const DesiredSendBufferSize = (1 << 20) * 7 // 7 MB
|
||||
|
||||
// InitialPacketSizeIPv4 is the maximum packet size that we use for sending IPv4 packets.
|
||||
const InitialPacketSizeIPv4 = 1252
|
||||
|
||||
Reference in New Issue
Block a user