From 802227a04449c3afec3685659a2c882c933e329f Mon Sep 17 00:00:00 2001 From: Tony Finch Date: Wed, 30 Mar 2022 11:11:41 +0100 Subject: [PATCH] preen data structure survey --- Data-structure-survey.md | 49 ++++++++++++++++++++-------------------- 1 file changed, 25 insertions(+), 24 deletions(-) diff --git a/Data-structure-survey.md b/Data-structure-survey.md index 4b925ec..16780de 100644 --- a/Data-structure-survey.md +++ b/Data-structure-survey.md @@ -28,58 +28,59 @@ disclaimers ----------- My personal interest is the work I have done over the last several -years on my "[qp-trie][]" data structure, and the variants that have -been tuned to work well with DNS names as keys, and for copy-on-write -concurrency. I prototyped these variants in [my fork of NSD][], -because it is simpler than BIND, and it already has a choice between a -red-black tree and a radix tree, so adding a qp-trie was not too hard. +years on my "[qp-trie][]" data structure, and the qp-trie variants +that have been tuned to work well with DNS names as keys, and for +copy-on-write concurrency. I prototyped these variants in [my fork of +NSD][], because it is simpler than BIND, and it already has a choice +between a red-black tree and a radix tree, so adding a qp-trie was not +too hard. [qp-trie]: https://dotat.at/prog/qp [my fork of NSD]: QP‑trie-in-NSD -I am writing these notes as myself because they are primarily a -learning exercise for myself, though I hope they might also be useful -to others. It is easier not to worry about mistakes or inaccuracies if -I am not trying to present this as the consensus of the BIND -developers. And there is a date at the top because there's a fair -chance this will become a historical document rather than being +I am writing these notes with a personal point of view because they +are primarily a learning exercise for myself, though I hope they might +also be useful to others. (It is easier not to worry about mistakes or +inaccuracies if I am not trying to present this as the consensus of +the BIND developers.) And there is a date at the top because there's a +fair chance this will become a historical document rather than being maintained as a current one. -# `lib/isc/astack` +# `isc/astack` Fixed-size array stack ## used by - * `lib/isc/netmgr/netmgr` + * `isc/netmgr/netmgr` -# `lib/isc/heap` +# `isc/heap` Priority queue ## used by - * `lib/dns/rbtdb` - * `lib/dns/zoneverify` - * `lib/isc/timer` + * `dns/rbtdb` + * `dns/zoneverify` + * `isc/timer` ## notes No locking / single-threaded. -# `lib/isc/ht` +# `isc/ht` Hash table ## used by * `bin/plugins/filter-a` and `bin/plugins/filter-aaaa` - * `lib/dns/catz` (which leaks into `bin/named/server`) - * `lib/dns/rpz` - * `lib/isc/tls` + * `dns/catz` (which leaks into `bin/named/server`) + * `dns/rpz` + * `isc/tls` ## notes @@ -89,14 +90,14 @@ Uses chaining, so it is heavy on indirection and heavy on allocation. Modern hash tables use open addressing. -# `lib/isc/radix` +# `isc/radix` Radix tree for IP address prefix matching ## used by - * `lib/dns/acl` - * `lib/dns/iptable` + * `dns/acl` + * `dns/iptable` ## notes