netstack_tcpbuf_ios.go 692 B

123456789101112131415161718192021222324
  1. // Copyright (c) Tailscale Inc & AUTHORS
  2. // SPDX-License-Identifier: BSD-3-Clause
  3. //go:build ios
  4. package netstack
  5. import (
  6. "gvisor.dev/gvisor/pkg/tcpip/transport/tcp"
  7. )
  8. const (
  9. // tcp{RX,TX}Buf{Min,Def,Max}Size mirror gVisor defaults. We leave these
  10. // unchanged on iOS for now as to not increase pressure towards the
  11. // NetworkExtension memory limit.
  12. // TODO(jwhited): test memory/throughput impact of collapsing to values in _default.go
  13. tcpRXBufMinSize = tcp.MinBufferSize
  14. tcpRXBufDefSize = tcp.DefaultSendBufferSize
  15. tcpRXBufMaxSize = tcp.MaxBufferSize
  16. tcpTXBufMinSize = tcp.MinBufferSize
  17. tcpTXBufDefSize = tcp.DefaultReceiveBufferSize
  18. tcpTXBufMaxSize = tcp.MaxBufferSize
  19. )