tailscale/net
David Anderson 4d1b3bc26f net/art: implement the stride table building block of ART
A stride table is an 8-bit routing table implemented as an array binary
tree, with a special tree updating function (allot) that enables lightning
fast address lookups and reasonably fast insertion and deletion.

Insertion, deletion and lookup are all allocation-free.

Updates #7781

                                        │    sec/op    │
StrideTableInsertion/10/random_order       16.79n ± 2%
StrideTableInsertion/10/largest_first      16.83n ± 1%
StrideTableInsertion/10/smallest_first     16.83n ± 0%
StrideTableInsertion/50/random_order       17.84n ± 1%
StrideTableInsertion/50/largest_first      20.04n ± 1%
StrideTableInsertion/50/smallest_first     16.39n ± 0%
StrideTableInsertion/100/random_order      14.63n ± 0%
StrideTableInsertion/100/largest_first     17.45n ± 4%
StrideTableInsertion/100/smallest_first    12.98n ± 0%
StrideTableInsertion/200/random_order      12.51n ± 4%
StrideTableInsertion/200/largest_first     18.36n ± 3%
StrideTableInsertion/200/smallest_first    9.609n ± 3%
StrideTableDeletion/10/random_order        19.50n ± 1%
StrideTableDeletion/10/largest_first       19.34n ± 0%
StrideTableDeletion/10/smallest_first      19.43n ± 0%
StrideTableDeletion/50/random_order        14.58n ± 1%
StrideTableDeletion/50/largest_first       14.27n ± 2%
StrideTableDeletion/50/smallest_first      15.51n ± 0%
StrideTableDeletion/100/random_order       12.02n ± 3%
StrideTableDeletion/100/largest_first      10.64n ± 0%
StrideTableDeletion/100/smallest_first     13.21n ± 3%
StrideTableDeletion/200/random_order       14.05n ± 4%
StrideTableDeletion/200/largest_first      9.288n ± 5%
StrideTableDeletion/200/smallest_first     18.51n ± 1%
StrideTableGet                            0.5010n ± 0%

                                        │  routes/s   │
StrideTableInsertion/10/random_order      59.55M ± 2%
StrideTableInsertion/10/largest_first     59.42M ± 1%
StrideTableInsertion/10/smallest_first    59.43M ± 0%
StrideTableInsertion/50/random_order      56.04M ± 1%
StrideTableInsertion/50/largest_first     49.91M ± 1%
StrideTableInsertion/50/smallest_first    61.00M ± 0%
StrideTableInsertion/100/random_order     68.35M ± 0%
StrideTableInsertion/100/largest_first    57.32M ± 3%
StrideTableInsertion/100/smallest_first   77.06M ± 0%
StrideTableInsertion/200/random_order     79.93M ± 4%
StrideTableInsertion/200/largest_first    54.47M ± 3%
StrideTableInsertion/200/smallest_first   104.1M ± 3%
StrideTableDeletion/10/random_order       51.28M ± 1%
StrideTableDeletion/10/largest_first      51.70M ± 0%
StrideTableDeletion/10/smallest_first     51.48M ± 0%
StrideTableDeletion/50/random_order       68.60M ± 1%
StrideTableDeletion/50/largest_first      70.09M ± 2%
StrideTableDeletion/50/smallest_first     64.45M ± 0%
StrideTableDeletion/100/random_order      83.21M ± 3%
StrideTableDeletion/100/largest_first     94.03M ± 0%
StrideTableDeletion/100/smallest_first    75.69M ± 3%
StrideTableDeletion/200/random_order      71.20M ± 5%
StrideTableDeletion/200/largest_first     107.7M ± 5%
StrideTableDeletion/200/smallest_first    54.02M ± 1%
StrideTableGet                            1.996G ± 0%

Signed-off-by: David Anderson <danderson@tailscale.com>
2023-04-04 09:00:24 -07:00
..
art net/art: implement the stride table building block of ART 2023-04-04 09:00:24 -07:00
connstats net/connstats: fix ticker in NewStatistics (#7225) 2023-02-09 01:24:52 -08:00
dns net/dns: don't send on closed channel in resolvedManager 2023-03-24 15:34:54 -04:00
dnscache tstest: add method to Replace values for tests 2023-03-03 17:02:33 -08:00
dnsfallback various: pass logger.Logf through to more places 2023-03-12 12:38:38 -04:00
flowtrack all: update copyright and license headers 2023-01-27 15:36:29 -08:00
interfaces net/interfaces: also allow link-local for AzureAppServices. 2023-03-20 13:40:38 -07:00
memnet net/memnet: rename from net/nettest 2023-01-30 13:03:32 -08:00
netaddr all: update copyright and license headers 2023-01-27 15:36:29 -08:00
netcheck net/netcheck: improve determinism in hairpinning test 2023-03-24 12:01:23 -04:00
neterror all: update copyright and license headers 2023-01-27 15:36:29 -08:00
netknob all: update copyright and license headers 2023-01-27 15:36:29 -08:00
netns net/interfaces, net/netns: add node attributes to control default interface getting and binding 2023-02-08 13:15:10 -08:00
netstat net/{netns,netstat}: use new x/sys/cpu.IsBigEndian 2023-02-02 07:41:49 -08:00
netutil all: replace /kb/ links with /s/ equivalents 2023-03-13 14:21:15 -07:00
packet net/packet: add checksum update tests 2023-03-23 16:54:12 -07:00
ping all: update copyright and license headers 2023-01-27 15:36:29 -08:00
portmapper sockstats: switch label to enum 2023-03-06 15:54:35 -08:00
proxymux all: update copyright and license headers 2023-01-27 15:36:29 -08:00
routetable net/routetable: include unknown flags in the routetable doctor output 2023-02-10 15:54:31 -08:00
socks5 net/socks5: add password auth support 2023-03-05 14:08:34 -08:00
sockstats sockstats: add labels for netlog and sockstatlog packages 2023-03-29 14:53:07 -07:00
speedtest all: update copyright and license headers 2023-01-27 15:36:29 -08:00
stun all: use Go 1.20's bytes.Clone 2023-02-01 17:39:18 -08:00
tlsdial health, net/tlsdial: add healthcheck for self-signed cert 2023-02-01 23:17:41 -05:00
tsaddr all: replace /kb/ links with /s/ equivalents 2023-03-13 14:21:15 -07:00
tsdial all: update copyright and license headers 2023-01-27 15:36:29 -08:00
tshttpproxy net/tshttpproxy: don't proxy through ourselves 2023-03-29 17:09:45 -04:00
tstun envknob,net/tstun,wgengine: use TS_DEBUG_MTU consistently 2023-03-30 14:26:10 -07:00
wsconn all: update copyright and license headers 2023-01-27 15:36:29 -08:00