9b803f9625
The goal here was to add the option to show the combined rbyd trees in
dbgbtree.py/dbgmtree.py.
This was quite tricky, (and not really helped by the hackiness of these
scripts), but was made a bit easier by adding a general purpose tree renderer
that can render a precomputed set of branches into the tag output.
For example, a 2-deep rendering of a simple btree with a block size of
1KiB, where you can see a bit of the emergent data-structure:
$ ./scripts/dbgbtree.py disk -B1024 0x223 -t -Z2 -i
btree 0x223.90, rev 46, weight 1024
rbyd ids tag ...
0223.0090: .-+ 0-199 btree w200 9 ...
00cb.0048: | | .-> 0-39 btree w40 7 ...
| | .---+-> 40-79 btree w40 7 ...
| | | .---> 80-119 btree w40 7 ...
| | | | .-> 120-159 btree w40 7 ...
| '-+-+-+-> 160-199 btree w40 7 ...
0223.0090: .---+-+ 200-399 btree w200 9 ...
013e.004b: | | .-> 200-239 btree w40 7 ...
| | .---+-> 240-279 btree w40 8 ...
| | | .---> 280-319 btree w40 8 ...
| | | | .-> 320-359 btree w40 8 ...
| '-+-+-+-> 360-399 btree w40 8 ...
0223.0090: | .---+ 400-599 btree w200 9 ...
01a7.004c: | | | .-> 400-439 btree w40 8 ...
| | | .---+-> 440-479 btree w40 8 ...
| | | | .---> 480-519 btree w40 8 ...
| | | | | .-> 520-559 btree w40 8 ...
| | '-+-+-+-> 560-599 btree w40 8 ...
0223.0090: | | .-+ 600-799 btree w200 9 ...
021e.004c: | | | | .-> 600-639 btree w40 8 ...
| | | | .---+-> 640-679 btree w40 8 ...
| | | | | .---> 680-719 btree w40 8 ...
| | | | | | .-> 720-759 btree w40 8 ...
| | | '-+-+-+-> 760-799 btree w40 8 ...
0223.0090: +-+-+-+ 800-1023 btree w224 10 ...
021f.0298: | .-> 800-839 btree w40 8 ...
| .-+-> 840-879 btree w40 8 ...
| | .-> 880-919 btree w40 8 ...
'---+-+-> 920-1023 btree w104 9 ...
This tree renderer also replaces the adhoc tree rendere in dbgrbyd.py
for consistency.