Module large_space

Source

Structs§

LargeObjectSpace
This space contains objects which are larger than the size limits of other spaces. Each object gets its own malloc’d region of memory. Large objects are never moved by the garbage collector.
PreciseAllocation
Precise allocation used for large objects (>= LARGE_CUTOFF). Starlight uses mimalloc that already knows what to do for large allocations. The GC shouldn’t have to think about such things. That’s where PreciseAllocation comes in. We will allocate large objects directly using mi_malloc, and put the PreciseAllocation header just before them. We can detect when a *mut GcPointerBase is a PreciseAllocation because it will have the ATOM_SIZE / 2 bit set.

Functions§

is_aligned_for_precise_allocation
Check if mem is aligned for precise allocation