Go to the documentation of this file.
19 using namespace clang;
26 :
Parent(
Parent), M(M),
P(
P), Stk(Stk), Ctx(Ctx), Current(nullptr),
27 CallStackDepth(
Parent.getCallStackDepth() + 1) {}
63 char *Memory =
reinterpret_cast<char *
>(malloc(
sizeof(
DeadBlock) + Size));
64 auto *D =
new (Memory)
DeadBlock(DeadBlocks, B);
Descriptor for a dead block.
virtual Frame * getCurrentFrame()=0
InterpFrame * Current
The current frame.
char * data()
Returns a pointer to the stored data.
A (possibly-)qualified type.
Holds all information required to evaluate constexpr code in a module.
InterpState(State &Parent, Program &P, InterpStack &Stk, Context &Ctx, SourceMapper *M=nullptr)
The base class of the type hierarchy.
unsigned getSize() const
Returns the size of the block.
OptionalDiagnostic CCEDiag(SourceLocation Loc, diag::kind DiagId=diag::note_invalid_subexpr_in_const_expr, unsigned ExtraNotes=0)
Diagnose that the evaluation does not produce a C++11 core constant expression.
Frame storing local variables.
Interface for the VM to interact with the AST walker's context.
A memory block, either on the stack or in the heap.
void deallocate(Block *B)
Deallocates a pointer.
bool reportOverflow(const Expr *E, const llvm::APSInt &Value)
Reports overflow and return true if evaluation should continue.
Frame * getCurrentFrame() override
Stack frame storing temporaries and parameters.
InterpFrame * Caller
The frame of the previous function.
Base class for stack frames, shared between VM and walker.
Describes a memory block created by an allocation site.
bool hasPointers() const
Checks if the block has any live pointers.
Descriptor * getDescriptor() const
Returns the block's descriptor.
bool noteUndefinedBehavior() override
The program contains and links the bytecode for all functions.
This represents one expression.
Interface for classes which map locations to sources.