1
0
mirror of https://gitlab.labs.nic.cz/labs/bird.git synced 2024-05-11 16:54:54 +00:00

Nest: Use bitmaps to keep track of exported routes

Use a hierarchical bitmap in a routing table to assign ids to routes, and
then use bitmaps (indexed by route id) in channels to keep track whether
routes were exported. This avoids unreliable and inefficient re-evaluation
of filters for old routes in order to determine whether they were exported.
This commit is contained in:
Ondrej Zajicek (work)
2019-09-09 02:55:32 +02:00
parent af02b83b88
commit 5ea39eaa96
9 changed files with 256 additions and 329 deletions

View File

@@ -26,6 +26,13 @@ bmap_init(struct bmap *b, pool *p, uint size)
b->data = mb_allocz(p, b->size);
}
void
bmap_reset(struct bmap *b, uint size)
{
b->size = BIRD_ALIGN(size, 4);
memset(b->data, 0, b->size);
}
void
bmap_grow(struct bmap *b, uint need)
{