|
FastLED 3.9.15
|
Polymorphic memory resource base class (PMR-style).
Concrete implementations wrap different allocation backends (default heap, PSRAM, DMA, slab, etc.)
Definition at line 16 of file memory_resource.h.
#include <memory_resource.h>
Inheritance diagram for fl::memory_resource:Public Member Functions | |
| virtual | ~memory_resource () FL_NOEXCEPT=default |
| void * | allocate (fl::size bytes) FL_NOEXCEPT |
| void | deallocate (void *p, fl::size bytes) FL_NOEXCEPT |
| bool | is_equal (const memory_resource &other) const FL_NOEXCEPT |
| void * | reallocate (void *p, fl::size old_bytes, fl::size new_bytes) FL_NOEXCEPT |
| Try to resize in-place. | |
Protected Member Functions | |
| virtual void * | do_allocate (fl::size bytes) FL_NOEXCEPT=0 |
| virtual void | do_deallocate (void *p, fl::size bytes) FL_NOEXCEPT=0 |
| virtual bool | do_is_equal (const memory_resource &other) const FL_NOEXCEPT |
| virtual void * | do_reallocate (void *p, fl::size old_bytes, fl::size new_bytes) FL_NOEXCEPT |
| Default: returns nullptr (not supported). Override for realloc-capable resources. | |