|
clang 24.0.0git
|
Allocator for function frames. More...
#include "/work/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/AST/ByteCode/FrameAllocator.h"
Public Member Functions | |
| FrameAllocator ()=default | |
| FrameAllocator (FrameAllocator &)=delete | |
| FrameAllocator (FrameAllocator &&)=delete | |
| ~FrameAllocator () | |
| char * | reserve (unsigned Size) |
| void | pop (unsigned FrameSize) |
| Pop the memory of the last function frame that was added. | |
Allocator for function frames.
The function frame size includes the size reserved for local variables. Function frames are allocated strictly in a LIFO manner, i.e. the last created frame is the first frame that is destroyed.
Since the address a function frame is allocated in needs to stay stable during the lifetime of the frame, we allocate them here in chunks.
A chunk is of (at least) MinChunkSize size and only gets deallocated once it is empty AND the previous chunk is also empty.
Definition at line 39 of file FrameAllocator.h.
|
default |
Referenced by FrameAllocator(), and FrameAllocator().
|
delete |
References FrameAllocator().
|
delete |
References FrameAllocator().
|
inline |
Definition at line 68 of file FrameAllocator.h.
|
inline |
Pop the memory of the last function frame that was added.
The passed FrameSize needs to match the latest size passed to reserve(). If it doesn't, bad things will happen.
Definition at line 106 of file FrameAllocator.h.
|
inline |
Definition at line 73 of file FrameAllocator.h.
References clang::C.