clang 20.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, std::vector< 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 (std::vector< std::byte > &Code, const T &Val, bool &Success) |
Emits a serializable value. | |
template<> | |
void | emit (Program &P, std::vector< std::byte > &Code, const Floating &Val, bool &Success) |
template<> | |
void | emit (Program &P, std::vector< std::byte > &Code, const IntegralAP< false > &Val, bool &Success) |
template<> | |
void | emit (Program &P, std::vector< std::byte > &Code, const IntegralAP< true > &Val, bool &Success) |
#define GET_LINK_IMPL |
Definition at line 371 of file ByteCodeEmitter.cpp.
void emit | ( | Program & | P, |
std::vector< std::byte > & | Code, | ||
const Floating & | Val, | ||
bool & | Success | ||
) |
Definition at line 318 of file ByteCodeEmitter.cpp.
References emitSerialized(), and clang::Success.
void emit | ( | Program & | P, |
std::vector< std::byte > & | Code, | ||
const IntegralAP< false > & | Val, | ||
bool & | Success | ||
) |
Definition at line 324 of file ByteCodeEmitter.cpp.
References emitSerialized(), and clang::Success.
void emit | ( | Program & | P, |
std::vector< std::byte > & | Code, | ||
const IntegralAP< true > & | Val, | ||
bool & | Success | ||
) |
Definition at line 330 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 268 of file ByteCodeEmitter.cpp.
References clang::interp::align(), clang::interp::aligned(), P, clang::Success, and clang::T.
Referenced by clang::Sema::BoundTypeDiagnoser< Ts >::diagnose(), and clang::Sema::SizelessTypeDiagnoser< Ts >::diagnose().
|
static |
Emits a serializable value.
These usually (potentially) contain heap-allocated memory and aren't trivially copyable.
Definition at line 299 of file ByteCodeEmitter.cpp.
References clang::interp::align(), clang::interp::aligned(), and clang::Success.
Referenced by emit().