]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
[fib_algo][dxr] Improve incremental updating strategy
authorMarko Zec <zec@FreeBSD.org>
Sat, 9 Oct 2021 11:22:27 +0000 (13:22 +0200)
committerMarko Zec <zec@FreeBSD.org>
Sat, 9 Oct 2021 11:22:27 +0000 (13:22 +0200)
commit1549575f22d14b3ac89a73627618a63132217460
treeb01cf83247e7087871af6ed4eb8a43ca09cb1d7c
parent032448cd2c52161aa03fd4ee5bf243d78d61b53e
[fib_algo][dxr] Improve incremental updating strategy

Tracking the number of unused holes in the trie and the range table
was a bad metric based on which full trie and / or range rebuilds
were triggered, which would happen in vain by far too frequently,
particularly with live BGP feeds.

Instead, track the total unused space inside the trie and range table
structures, and trigger rebuilds if the percentage of unused space
exceeds a sysctl-tunable threshold.

MFC after: 3 days
PR: 257965
sys/netinet/in_fib_dxr.c