UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FGrowOnlySpanAllocator Class Reference

#include <GrowOnlySpanAllocator.h>

Public Member Functions

 FGrowOnlySpanAllocator ()
 
ENGINE_API int32 Allocate (int32 Num)
 
ENGINE_API void Free (int32 BaseOffset, int32 Num)
 
int32 GetSparselyAllocatedSize () const
 
int32 GetMaxSize () const
 
int32 GetNumFreeSpans () const
 
ENGINE_API void BeginDeferMerges ()
 
ENGINE_API void EndDeferMerges ()
 

Constructor & Destructor Documentation

◆ FGrowOnlySpanAllocator()

FGrowOnlySpanAllocator::FGrowOnlySpanAllocator ( )
inline

Member Function Documentation

◆ Allocate()

int32 FGrowOnlySpanAllocator::Allocate ( int32  Num)

◆ BeginDeferMerges()

void FGrowOnlySpanAllocator::BeginDeferMerges ( )

Between these calls to Free just appends the allocation to the free list, rather than trying to merge with existing allocations. At EndDeferMerges the free list is consolidated by sorting and merging all spans. This amortises the cost of the merge over many calls.

◆ EndDeferMerges()

void FGrowOnlySpanAllocator::EndDeferMerges ( )

◆ Free()

void FGrowOnlySpanAllocator::Free ( int32  BaseOffset,
int32  Num 
)

◆ GetMaxSize()

int32 FGrowOnlySpanAllocator::GetMaxSize ( ) const
inline

◆ GetNumFreeSpans()

int32 FGrowOnlySpanAllocator::GetNumFreeSpans ( ) const
inline

◆ GetSparselyAllocatedSize()

int32 FGrowOnlySpanAllocator::GetSparselyAllocatedSize ( ) const
inline

The documentation for this class was generated from the following files: