![]() |
Pixie
|
Experimental ordering of 256 pointer slots in one 16x16 node. More...
#include <grouped_slot_order256.h>
Public Member Functions | |
| GroupedSlotOrder256 (std::size_t count=0) noexcept | |
| Identity ordering of count live slots; requires count <= 256. | |
| std::size_t | size () const noexcept |
| Number of live logical slots in [0, 256]. | |
| unsigned | operator[] (std::size_t index) const noexcept |
| Physical slot for zero-based index; requires index < size(). | |
| bool | occupied (std::size_t slot) const noexcept |
| Whether physical slot is live; requires slot < capacity. | |
| bool | valid () const noexcept |
| Check mapping uniqueness and occupancy without allocation. | |
| std::size_t | rotate_children (std::array< void *, capacity > &pointers, std::size_t left, std::size_t right, std::size_t distance) noexcept |
| Rotate logical [left,right) left, updating order and pointer slots. | |
Static Public Attributes | |
| static constexpr std::size_t | capacity = 256 |
| Maximum occupied child count. | |
Experimental ordering of 256 pointer slots in one 16x16 node.
Seventeen packed 64-bit permutations select the physical group and the physical slot within it. Per-group occupancy bitmaps describe live physical slots. Only the final logical group may be partial. This is one node allocation, not sixteen separately allocated intermediate nodes.
Whole-group and within-group rotations move only ordering metadata. A rotation of full groups with a non-group-aligned distance exchanges at most eight pointers per group. Other boundary combinations use bounded scratch pointer storage. No operation allocates, owns, or destroys pointees; callers supply live slots and retain ownership. Subtree sizes are maintained by the caller in logical order. Invalid arguments violate asserted preconditions.
|
inlinenoexcept |
Rotate logical [left,right) left, updating order and pointer slots.
Requires left <= right <= size(). Distance is reduced modulo length; empty ranges are unchanged. Inactive pointers are never read or written. No pointee moves. Scratch storage is bounded by 256 pointers.