tailscale/net/packet
Brad Fitzpatrick 9e0a5cc551 net/flowtrack: optimize Tuple type for use as map key
This gets UDP filter overhead closer to TCP. Still ~2x, but no longer ~3x.

    goos: darwin
    goarch: arm64
    pkg: tailscale.com/wgengine/filter
                                       │   before    │                after                │
                                       │   sec/op    │   sec/op     vs base                │
    FilterMatch/tcp-not-syn-v4-8         15.43n ± 3%   15.38n ± 5%        ~ (p=0.339 n=10)
    FilterMatch/udp-existing-flow-v4-8   42.45n ± 0%   34.77n ± 1%  -18.08% (p=0.000 n=10)
    geomean                              25.59n        23.12n        -9.65%

Updates #12486

Change-Id: I595cfadcc6b7234604bed9c4dd4261e087c0d4c4
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2024-06-18 21:31:48 -07:00
..
checksum net/packet: split off checksum munging into different pkg 2023-10-11 14:25:58 -07:00
doc.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
header.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
icmp4.go net/packet: allow more ICMP errors 2024-04-02 11:31:49 -07:00
icmp6_test.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
icmp6.go net/packet: allow more ICMP errors 2024-04-02 11:31:49 -07:00
icmp.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
ip4.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
ip6.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
packet_test.go all: use Go 1.22 range-over-int 2024-04-16 15:32:38 -07:00
packet.go net/packet: allow more ICMP errors 2024-04-02 11:31:49 -07:00
tsmp_test.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
tsmp.go net/flowtrack: optimize Tuple type for use as map key 2024-06-18 21:31:48 -07:00
udp4.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00
udp6.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00