TLockFreeClassAllocator_TLSCache

Inheritance Hierarchy

Syntax

template<class T, int TPaddingForCacheContention>
class TLockFreeClassAllocator_TLSCache : private TLockFreeFixedSizeAllocator_TLSCache< sizeof(T), TPaddingForCacheContention >

Remarks

Thread safe, lock free pooling allocator of memory for instances of T.

Never returns free space until program shutdown.

Functions

Name Description

Public function

void *

 

Allocate()

Returns a memory block of size sizeof(T).

Public function

void

 

Free

(
    T* Item
)

Calls a destructor on Item and returns the memory to the free list for recycling.

Public function

T *

 

New()

Returns a new T using the default constructor.

References

Module

Core

Header

Runtime/Core/Public/Containers/LockFreeFixedSizeAllocator.h