]> git.puffer.fish Git - matthieu/frr.git/commit
lib: optimise prefix list setup
authorDavid Lamparter <equinox@opensourcerouting.org>
Mon, 13 Apr 2015 08:21:37 +0000 (10:21 +0200)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Tue, 3 Nov 2015 13:54:27 +0000 (05:54 -0800)
commit20b8a998aa1be595b737c25d3fc0991628bfa3c2
treeb7a6998d487d77d3dfc542cd892fdfa62a82a5e4
parent7e111b6b0de44a9d351cdfeda4c674224a65ec3b
lib: optimise prefix list setup

- duplicate prefix check can use the trie structure
- appending with a seq# beyond the end of the list can shortcut

Configuration load is now bottlenecked by cmd_element_match() and
strcmp().  For a real-world routeserver prefix list configuration
(38668 lines of config for multiple prefix lists):
  before: 4.73s
  after:  1.92s    x 2.46

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
lib/plist.c