UraniumCompute 0.1.0
A GPU accelerated parallel task scheduler
IAllocator.h
1#pragma once
2#include <UnCompute/Base/Base.h>
3
4namespace UN
5{
8 {
9 public:
16 virtual void* Allocate(USize size, USize alignment) = 0;
17
21 virtual void Deallocate(void* pointer) = 0;
22
24 [[nodiscard]] virtual const char* GetName() const = 0;
25 };
26} // namespace UN
An interface for memory allocators.
Definition: IAllocator.h:8
virtual void Deallocate(void *pointer)=0
Deallocate memory.
virtual const char * GetName() const =0
Get debug name of the allocator.
virtual void * Allocate(USize size, USize alignment)=0
Allocate memory.