template <size_t AllocSize, size_t MaxAllocs>

class FixedIdSlabAllocator

Defined at line 265 of file ../../zircon/kernel/vm/include/vm/page_slab_allocator.h

An implementation of the BaseIdSlabAllocator that supports a fixed amount of slabs, as determined

by MaxAllocs, and statically pre-allocates all the metadata for those slabs. The metadata is 8

bytes per slab.

This allocator guarantees that all IDs are within [0, MaxAllocs). To achieve this it is a

restriction that the maximum number of requested allocations be a multiple of the number of

allocations per slab.

Due to the static overhead per potential slab required this object can become quite large as

MaxAllocs grows. Users should check the resulting size of the object, based on the provided

allocation size and MaxAllocs, to ensure it is within acceptable limits.

Most likely this allocator is not what you are looking for, and you want the IdSlabAllocator.

Public Methods

void FixedIdSlabAllocator<AllocSize, MaxAllocs> ()

Defined at line 268 of file ../../zircon/kernel/vm/include/vm/page_slab_allocator.h

void ~FixedIdSlabAllocator<AllocSize, MaxAllocs> ()

Defined at line 269 of file ../../zircon/kernel/vm/include/vm/page_slab_allocator.h