diff options
| author | Donald Sharp <sharpd@nvidia.com> | 2023-03-15 13:51:19 -0400 |
|---|---|---|
| committer | Donald Sharp <sharpd@nvidia.com> | 2023-03-16 10:40:35 -0400 |
| commit | e2e8f8dd5136af2eada315c2f4060d2bae6a8694 (patch) | |
| tree | 2ecc7e656176cdd1cdb10a09d0a81fc05598facd /lib/filter_cli.c | |
| parent | c3ff85a7e250261f463b59b651229905f8803eba (diff) | |
lib: Speedup prefix-list readin by a large factor
Reading in prefix-lists is reading in the specified
prefix list and validating that the prefix is unique
2 times. This makes no sense. Relax the requirement
that a prefix list can limit this as well as completely
remove this check. Validation then just becomes
does this prefix-list specified actually make sense
and that is taken care of by the the cli code.
Reading in prefix-lists was looking for duplicate prefixes
2 times instead of doing it just one time. Let's just
not do it at all.
By doing this change, The code changes from never
completing for a 27k long prefix-list to taking
just under 30 seconds, with 4 daemons processing
this data.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'lib/filter_cli.c')
| -rw-r--r-- | lib/filter_cli.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/lib/filter_cli.c b/lib/filter_cli.c index 7ef0d47f67..07dd939f71 100644 --- a/lib/filter_cli.c +++ b/lib/filter_cli.c @@ -1272,9 +1272,6 @@ DEFPY_YANG( pda.any = true; } - if (plist_is_dup(vty->candidate_config->dnode, &pda)) - return CMD_SUCCESS; - /* * Create the prefix-list first, so we can generate sequence if * none given (backward compatibility). @@ -1476,9 +1473,6 @@ DEFPY_YANG( pda.any = true; } - if (plist_is_dup(vty->candidate_config->dnode, &pda)) - return CMD_SUCCESS; - /* * Create the prefix-list first, so we can generate sequence if * none given (backward compatibility). |
