24.02.1
|
Offset based memory pool. More...
#include <OffsetMemoryPool.h>
Public Member Functions | |
OffsetMemoryPool (IAllocator *allocator, BlobInfo blob_info) | |
Default Constructor. More... | |
~OffsetMemoryPool ()=default | |
Default Destructor. More... | |
OffsetMemoryPool (const OffsetMemoryPool &)=delete | |
Prevent instances of this class to be copy constructed. More... | |
OffsetMemoryPool & | operator= (const OffsetMemoryPool &)=delete |
Prevent instances of this class to be copy assigned. More... | |
OffsetMemoryPool (OffsetMemoryPool &&)=default | |
Allow instances of this class to be move constructed. More... | |
OffsetMemoryPool & | operator= (OffsetMemoryPool &&)=default |
Allow instances of this class to be move assigned. More... | |
const BlobInfo & | info () const |
Accessor to the pool internal configuration meta-data. More... | |
void | acquire (MemoryMappings &handles) override |
Sets occupant to the memory pool. More... | |
void | release (MemoryMappings &handles) override |
Releases a memory block. More... | |
MappingType | mapping_type () const override |
Returns the mapping types that this pool accepts. More... | |
std::unique_ptr< IMemoryPool > | duplicate () override |
Duplicates the existing memory pool. More... | |
Public Member Functions inherited from IMemoryPool | |
virtual | ~IMemoryPool ()=default |
Default Virtual Destructor. More... | |
Offset based memory pool.
Definition at line 39 of file OffsetMemoryPool.h.
OffsetMemoryPool | ( | IAllocator * | allocator, |
BlobInfo | blob_info | ||
) |
Default Constructor.
[in] | allocator | Backing memory allocator |
[in] | blob_info | Configuration information of the blob to be allocated |
Definition at line 36 of file OffsetMemoryPool.cpp.
References BlobInfo::alignment, arm_compute::test::validation::allocator(), ARM_COMPUTE_ERROR_ON, IAllocator::make_region(), and BlobInfo::size.
|
default |
Default Destructor.
|
delete |
Prevent instances of this class to be copy constructed.
|
default |
Allow instances of this class to be move constructed.
|
overridevirtual |
Sets occupant to the memory pool.
[in] | handles | A vector of pairs (handle, index) |
Implements IMemoryPool.
Definition at line 48 of file OffsetMemoryPool.cpp.
References ARM_COMPUTE_ERROR_ON, and BlobInfo::size.
|
overridevirtual |
Duplicates the existing memory pool.
Implements IMemoryPool.
Definition at line 74 of file OffsetMemoryPool.cpp.
References ARM_COMPUTE_ERROR_ON.
const BlobInfo & info | ( | ) | const |
Accessor to the pool internal configuration meta-data.
Definition at line 43 of file OffsetMemoryPool.cpp.
|
overridevirtual |
Returns the mapping types that this pool accepts.
Implements IMemoryPool.
Definition at line 69 of file OffsetMemoryPool.cpp.
References arm_compute::OFFSETS.
|
delete |
Prevent instances of this class to be copy assigned.
|
default |
Allow instances of this class to be move assigned.
|
overridevirtual |
Releases a memory block.
[in] | handles | A vector containing a pair of handles and indices |
Implements IMemoryPool.
Definition at line 60 of file OffsetMemoryPool.cpp.
References ARM_COMPUTE_ERROR_ON.