13#ifndef LLVM_TOOLS_LLUBI_EXECUTORBASE_H
14#define LLVM_TOOLS_LLUBI_EXECUTORBASE_H
84class DiagnosticReporter;
134 std::optional<ProgramExitInfo>
getExitInfo()
const;
150 : Executor(
E), OS(Buf), Printer(
E.Ctx, OS), Kind(
K) {}
161 Executor.reportImmediateUBString(Buf);
164 Executor.reportErrorString(Buf);
AMDGPU Mark last scratch load
static GCRegistry::Add< ShadowStackGC > C("shadow-stack", "Very portable GC for uncooperative code generators")
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
Represent a constant reference to an array (0 or more elements consecutively in memory),...
LLVM Basic Block Representation.
InstListType::iterator iterator
Instruction iterators...
Base class for all callable instructions (InvokeInst and CallInst) Holds everything related to callin...
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
Represent a constant reference to a string, i.e.
Implementation of the target library information.
Provides information about what library functions are available for the current target.
The instances of the Type class are immutable: once they are created, they are never changed.
A raw_ostream that writes to an std::string.
The global context for the interpreter.
DiagnosticReporter(const DiagnosticReporter &)=delete
DiagnosticReporter(ExecutorBase &E, DiagnosticKind K)
DiagnosticReporter & operator<<(const T &Val)
DiagnosticReporter(DiagnosticReporter &&) noexcept=delete
An interface for handling events and managing outputs during interpretation.
unsigned getIntSize() const
DiagnosticReporter reportError()
std::pair< MemoryObject *, uint64_t > verifyMemAccess(const Pointer &Ptr, uint64_t AccessSize, Align Alignment, bool IsStore)
Check if the upcoming memory access is valid.
friend class DiagnosticReporter
void dumpStackTrace() const
void executeMemSet(const AnyValue &Dest, const AnyValue &Val, const AnyValue &Length)
Fill Length bytes at Dest with Val.
ExecutorBase(Context &C, EventHandler &H)
bool hasProgramExited() const
std::optional< ProgramExitInfo > ExitInfo
std::optional< ProgramExitInfo > getExitInfo() const
void requestProgramExit(ProgramExitInfo::ProgramExitKind Kind, uint64_t ExitCode=0)
DiagnosticReporter reportImmediateUB()
void store(const AnyValue &Ptr, Align Alignment, const AnyValue &Val, Type *ValTy)
void executeMemTransfer(const AnyValue &Dest, const AnyValue &Src, const AnyValue &Length, Intrinsic::ID IID, bool IsLibCall)
Copy Length bytes from Src to Dest according to the intrinsic IID.
Implement std::hash so that hash_code can be used in STL containers.
This struct is a compact representation of a valid (non-zero power of two) alignment.
Context for a function call.
Frame(Function &F, CallBase *CallSite, Frame *LastFrame, ArrayRef< AnyValue > Args, AnyValue &RetVal, const TargetLibraryInfoImpl &TLIImpl)
ArrayRef< AnyValue > Args
Function * ResolvedCallee
bool HasInaccessibleStackObjects
SmallVector< IntrusiveRefCntPtr< MemoryObject > > CalleeByValArgs
SmallVector< IntrusiveRefCntPtr< MemoryObject > > Allocas
SmallVector< AnyValue > CalleeArgs
DenseMap< Value *, AnyValue > ValueMap