IceShard 1
A personal game engine project, with development focused on 2D/2.5D games.
Loading...
Searching...
No Matches
ice::RingAllocator Struct Reference

#include <ice/mem_allocator_ring.hxx>

Inheritance diagram for ice::RingAllocator:
ice::AllocatorBase< ice::build::is_debug||ice::build::is_develop >

Public Member Functions

 RingAllocator (ice::Allocator &backing_allocator, ice::RingAllocatorParams params={ }, std::source_location=std::source_location::current()) noexcept
 RingAllocator (ice::Allocator &backing_allocator, std::string_view name, ice::RingAllocatorParams params={ }, std::source_location=std::source_location::current()) noexcept
 ~RingAllocator () noexcept
void reset () noexcept
 Releases all memory blocks not in-use.
Public Member Functions inherited from ice::AllocatorBase< ice::build::is_debug||ice::build::is_develop >
 AllocatorBase (std::source_location const &) noexcept
 AllocatorBase (std::source_location const &, std::string_view) noexcept
 AllocatorBase (std::source_location const &, AllocatorBase &) noexcept
 AllocatorBase (std::source_location const &, AllocatorBase &, std::string_view) noexcept
auto allocate (ice::AllocRequest request) noexcept -> ice::AllocResult
auto allocate (ice::ChunkedAllocRequest const &request) noexcept -> ice::AllocResult
auto allocate (ice::u64 count=1) noexcept -> T *
void deallocate (void *pointer) noexcept
void deallocate (ice::Memory result) noexcept
auto create (Args &&... args) noexcept -> T *
void destroy (T *object) noexcept
auto allocation_count () const noexcept -> ice::u32
auto allocation_total_count () const noexcept -> ice::u32
auto allocation_size_inuse () const noexcept -> ice::usize
auto allocation_size_watermark () const noexcept -> ice::usize
virtual auto allocation_size (void *ptr) const noexcept -> ice::usize
auto debug_info () const noexcept -> ice::AllocatorDebugInfo const &
 Gives access to debug information for an allocator.

Protected Member Functions

auto do_allocate (ice::AllocRequest request) noexcept -> ice::AllocResult override
void do_deallocate (void *pointer) noexcept override
bool is_locked (void *ptr) const noexcept
bool is_backed (void *ptr) const noexcept
Protected Member Functions inherited from ice::AllocatorBase< ice::build::is_debug||ice::build::is_develop >
virtual ~AllocatorBase () noexcept=default

Additional Inherited Members

Static Public Attributes inherited from ice::AllocatorBase< ice::build::is_debug||ice::build::is_develop >
static constexpr ice::usize SizeNotTracked
static constexpr ice::u32 CountNotTracked
static constexpr bool HasDebugInformation

Constructor & Destructor Documentation

◆ RingAllocator() [1/2]

ice::RingAllocator::RingAllocator ( ice::Allocator & backing_allocator,
ice::RingAllocatorParams params = { },
std::source_location = std::source_location::current() )
noexcept

◆ RingAllocator() [2/2]

ice::RingAllocator::RingAllocator ( ice::Allocator & backing_allocator,
std::string_view name,
ice::RingAllocatorParams params = { },
std::source_location = std::source_location::current() )
noexcept

◆ ~RingAllocator()

ice::RingAllocator::~RingAllocator ( )
noexcept

Member Function Documentation

◆ do_allocate()

auto ice::RingAllocator::do_allocate ( ice::AllocRequest request) -> ice::AllocResult
overrideprotectedvirtualnoexcept

◆ do_deallocate()

void ice::RingAllocator::do_deallocate ( void * pointer)
overrideprotectedvirtualnoexcept

◆ is_backed()

bool ice::RingAllocator::is_backed ( void * ptr) const
protectednoexcept

◆ is_locked()

bool ice::RingAllocator::is_locked ( void * ptr) const
protectednoexcept

◆ reset()

void ice::RingAllocator::reset ( )
noexcept

Releases all memory blocks not in-use.


The documentation for this struct was generated from the following file: