clang 22.0.0git
|
#include "ByteCodeEmitter.h"
#include "Context.h"
#include "Floating.h"
#include "IntegralAP.h"
#include "Opcode.h"
#include "Program.h"
#include "clang/AST/ASTLambda.h"
#include "clang/AST/Attr.h"
#include "clang/AST/DeclCXX.h"
#include <type_traits>
#include "Opcodes.inc"
Go to the source code of this file.
Macros | |
#define | GET_LINK_IMPL |
Functions | |
template<typename T> | |
static void | emit (Program &P, llvm::SmallVectorImpl< std::byte > &Code, const T &Val, bool &Success) |
Helper to write bytecode and bail out if 32-bit offsets become invalid. | |
template<typename T> | |
static void | emitSerialized (llvm::SmallVectorImpl< std::byte > &Code, const T &Val, bool &Success) |
Emits a serializable value. | |
template<> | |
void | emit (Program &P, llvm::SmallVectorImpl< std::byte > &Code, const Floating &Val, bool &Success) |
template<> | |
void | emit (Program &P, llvm::SmallVectorImpl< std::byte > &Code, const IntegralAP< false > &Val, bool &Success) |
template<> | |
void | emit (Program &P, llvm::SmallVectorImpl< std::byte > &Code, const IntegralAP< true > &Val, bool &Success) |
template<> | |
void | emit (Program &P, llvm::SmallVectorImpl< std::byte > &Code, const FixedPoint &Val, bool &Success) |
#define GET_LINK_IMPL |
Definition at line 257 of file ByteCodeEmitter.cpp.
void emit | ( | Program & | P, |
llvm::SmallVectorImpl< std::byte > & | Code, | ||
const FixedPoint & | Val, | ||
bool & | Success ) |
Definition at line 204 of file ByteCodeEmitter.cpp.
References emitSerialized(), and clang::Success.
void emit | ( | Program & | P, |
llvm::SmallVectorImpl< std::byte > & | Code, | ||
const Floating & | Val, | ||
bool & | Success ) |
Definition at line 186 of file ByteCodeEmitter.cpp.
References emitSerialized(), and clang::Success.
void emit | ( | Program & | P, |
llvm::SmallVectorImpl< std::byte > & | Code, | ||
const IntegralAP< false > & | Val, | ||
bool & | Success ) |
Definition at line 192 of file ByteCodeEmitter.cpp.
References emitSerialized(), and clang::Success.
void emit | ( | Program & | P, |
llvm::SmallVectorImpl< std::byte > & | Code, | ||
const IntegralAP< true > & | Val, | ||
bool & | Success ) |
Definition at line 198 of file ByteCodeEmitter.cpp.
References emitSerialized(), and clang::Success.
|
static |
Helper to write bytecode and bail out if 32-bit offsets become invalid.
Pointers will be automatically marshalled as 32-bit IDs.
Definition at line 136 of file ByteCodeEmitter.cpp.
References clang::interp::align(), clang::interp::aligned(), clang::interp::Program::getOrCreateNativePointer(), clang::Success, and clang::T.
Referenced by clang::interp::Compiler< Emitter >::VisitCXXThisExpr().
|
static |
Emits a serializable value.
These usually (potentially) contain heap-allocated memory and aren't trivially copyable.
Definition at line 167 of file ByteCodeEmitter.cpp.
References clang::interp::align(), clang::interp::aligned(), clang::Success, and clang::T.