]> git.proxmox.com Git - mirror_frr.git/commit - lib/plist.c
lib: Convert prefix_master->str to a RB Tree
authorDonald Sharp <sharpd@nvidia.com>
Wed, 9 Mar 2022 01:52:45 +0000 (20:52 -0500)
committerDonald Sharp <sharpd@nvidia.com>
Fri, 11 Mar 2022 19:18:13 +0000 (14:18 -0500)
commite92508a741e03b8721ccb3424cbebe4d5476e9d0
tree25dc75ca3adc00fc302536d71fea67069d3549f0
parent89ee4bbb21d628b7cabbc54c9cf23064d3295484
lib: Convert prefix_master->str to a RB Tree

The prefix_master->str data structure was a sorted
list of the prefix names.  Not that big of a deal
other than insertion and deletion is insanely expensive
when you have a large number of unique prefix-lists.

In my test config file that I discovered this,
I have 587 unique prefix lists spread out acros
~26k lines of prefix-lists.  When reading
this config file into FRR the read time goes
from 690 seconds to 650 seconds.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
lib/plist.c
lib/plist_int.h