|
Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
|
Arena-backed ownership context for IR nodes. More...
#include <Compiler_IR_Model.H>
Classes | |
| struct | Owned_Object |
Public Member Functions | |
| Compiler_IR_Context (const size_t arena_size=AhArenaAllocator::DEFAULT_SIZE) | |
Constructs an IR context with arena_size bytes. | |
| Compiler_IR_Context (const Compiler_IR_Context &)=delete | |
| Compiler_IR_Context & | operator= (const Compiler_IR_Context &)=delete |
| ~Compiler_IR_Context () noexcept | |
| template<typename T , typename... Args> | |
| T * | make (Args &&...args) |
| Allocates and constructs one IR object. | |
| void | reset () noexcept |
| Destroys all tracked objects and rewinds the arena. | |
Private Attributes | |
| AhArenaAllocator | arena |
| DynArray< Owned_Object > | owned |
Arena-backed ownership context for IR nodes.
Definition at line 256 of file Compiler_IR_Model.H.
|
inlineexplicit |
Constructs an IR context with arena_size bytes.
Definition at line 269 of file Compiler_IR_Model.H.
|
delete |
|
inlinenoexcept |
Definition at line 276 of file Compiler_IR_Model.H.
References reset().
Allocates and constructs one IR object.
Definition at line 283 of file Compiler_IR_Model.H.
References ah_runtime_error_unless, arena, Aleph::blossom_maximum_cardinality_matching(), and owned.
Referenced by Aleph::Compiler_IR_Lowering::lower_module(), Aleph::Compiler_IR_Builder::make_module(), and Aleph::Compiler_IR_Lowering::Module_Builder::predeclare_function().
|
delete |
|
inlinenoexcept |
Destroys all tracked objects and rewinds the arena.
Definition at line 297 of file Compiler_IR_Model.H.
References Aleph::and, arena, owned, and Aleph::AhArenaAllocator::reset().
Referenced by ~Compiler_IR_Context(), Aleph::Compiler_Driver::clear(), Aleph::Compiler_Line_Frontend::clear(), and Aleph::Compiler_MVP_Frontend::clear().
|
private |
Definition at line 264 of file Compiler_IR_Model.H.
|
private |
Definition at line 265 of file Compiler_IR_Model.H.