clang 22.0.0git
|
CGBlockInfo - Information to generate a block literal. More...
#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/CodeGen/CGBlocks.h"
Classes | |
class | Capture |
Public Member Functions | |
void | buildCaptureMap () |
const Capture & | getCapture (const VarDecl *var) const |
Capture & | getCapture (const VarDecl *var) |
const BlockDecl * | getBlockDecl () const |
const BlockExpr * | getBlockExpr () const |
CGBlockInfo (const BlockDecl *blockDecl, StringRef Name) |
Public Attributes | |
StringRef | Name |
Name - The name of the block, kindof. | |
unsigned | CXXThisIndex |
The field index of 'this' within the block, if there is one. | |
bool | CanBeGlobal: 1 |
CanBeGlobal - True if the block can be global, i.e. | |
bool | NeedsCopyDispose: 1 |
True if the block has captures that would necessitate custom copy or dispose helper functions if the block were escaping. | |
bool | NoEscape: 1 |
Indicates whether the block is non-escaping. | |
bool | HasCXXObject: 1 |
HasCXXObject - True if the block's custom copy/dispose functions need to be run even in GC mode. | |
bool | UsesStret: 1 |
UsesStret : True if the block uses an stret return. | |
bool | HasCapturedVariableLayout: 1 |
HasCapturedVariableLayout : True if block has captured variables and their layout meta-data has been generated. | |
bool | CapturesNonExternalType: 1 |
Indicates whether an object of a non-external C++ class is captured. | |
llvm::DenseMap< const VarDecl *, Capture * > | Captures |
Mapping from variables to pointers to captures in SortedCaptures. | |
llvm::SmallVector< Capture, 4 > | SortedCaptures |
The block's captures. Non-constant captures are sorted by their offsets. | |
RawAddress | LocalAddress |
llvm::StructType * | StructureType |
const BlockDecl * | Block |
const BlockExpr * | BlockExpression |
CharUnits | BlockSize |
CharUnits | BlockAlign |
CharUnits | CXXThisOffset |
CharUnits | BlockHeaderForcedGapOffset |
CharUnits | BlockHeaderForcedGapSize |
CGBlockInfo - Information to generate a block literal.
Definition at line 157 of file CGBlocks.h.
CGBlockInfo::CGBlockInfo | ( | const BlockDecl * | blockDecl, |
StringRef | Name ) |
Definition at line 35 of file CGBlocks.cpp.
References Block, CanBeGlobal, CapturesNonExternalType, CXXThisIndex, false, HasCapturedVariableLayout, HasCXXObject, LocalAddress, Name, NeedsCopyDispose, NoEscape, clang::nullptr, StructureType, and UsesStret.
Referenced by getCapture().
|
inline |
Definition at line 292 of file CGBlocks.h.
References clang::C, Captures, and SortedCaptures.
Referenced by computeBlockInfo().
|
inline |
Definition at line 306 of file CGBlocks.h.
References Block.
Referenced by computeBlockInfo(), clang::CodeGen::CGDebugInfo::EmitDeclareOfBlockLiteralArgVariable(), and clang::CodeGen::CodeGenFunction::GenerateBlockFunction().
|
inline |
Definition at line 307 of file CGBlocks.h.
References Block, and BlockExpression.
Referenced by buildBlockDescriptor(), buildGlobalBlock(), clang::CodeGen::CodeGenFunction::GenerateBlockFunction(), and getBlockDescriptorName().
Definition at line 300 of file CGBlocks.h.
References Captures.
Definition at line 297 of file CGBlocks.h.
References CGBlockInfo(), and getCapture().
Referenced by clang::CodeGen::CGDebugInfo::EmitDeclareOfBlockDeclRefVariable(), clang::CodeGen::CGDebugInfo::EmitDeclareOfBlockLiteralArgVariable(), clang::CodeGen::CodeGenFunction::GenerateBlockFunction(), getCapture(), and getCaptureFieldType().
const BlockDecl* clang::CodeGen::CGBlockInfo::Block |
Definition at line 278 of file CGBlocks.h.
Referenced by CGBlockInfo(), getBlockDecl(), and getBlockExpr().
CharUnits clang::CodeGen::CGBlockInfo::BlockAlign |
Definition at line 281 of file CGBlocks.h.
Referenced by buildGlobalBlock(), computeBlockInfo(), clang::CodeGen::CodeGenFunction::EmitBlockLiteral(), clang::CodeGen::CodeGenFunction::GenerateCopyHelperFunction(), clang::CodeGen::CodeGenFunction::GenerateDestroyHelperFunction(), getBlockDescriptorName(), and initializeForBlockHeader().
const BlockExpr* clang::CodeGen::CGBlockInfo::BlockExpression |
Definition at line 279 of file CGBlocks.h.
Referenced by buildGlobalBlock(), clang::CodeGen::CodeGenFunction::EmitBlockLiteral(), clang::CodeGen::CodeGenModule::GetAddrOfGlobalBlock(), and getBlockExpr().
CharUnits clang::CodeGen::CGBlockInfo::BlockHeaderForcedGapOffset |
Definition at line 287 of file CGBlocks.h.
Referenced by computeBlockInfo().
CharUnits clang::CodeGen::CGBlockInfo::BlockHeaderForcedGapSize |
Definition at line 290 of file CGBlocks.h.
Referenced by computeBlockInfo().
CharUnits clang::CodeGen::CGBlockInfo::BlockSize |
Definition at line 280 of file CGBlocks.h.
Referenced by buildBlockDescriptor(), buildGlobalBlock(), computeBlockInfo(), clang::CodeGen::CGDebugInfo::EmitDeclareOfBlockLiteralArgVariable(), getBlockDescriptorName(), and initializeForBlockHeader().
bool clang::CodeGen::CGBlockInfo::CanBeGlobal |
CanBeGlobal - True if the block can be global, i.e.
it has no non-constant captures.
Definition at line 243 of file CGBlocks.h.
Referenced by buildGlobalBlock(), CGBlockInfo(), computeBlockInfo(), and clang::CodeGen::CodeGenFunction::EmitBlockLiteral().
Mapping from variables to pointers to captures in SortedCaptures.
Definition at line 270 of file CGBlocks.h.
Referenced by buildCaptureMap(), and getCapture().
bool clang::CodeGen::CGBlockInfo::CapturesNonExternalType |
Indicates whether an object of a non-external C++ class is captured.
This bit is used to determine the linkage of the block copy/destroy helper functions.
Definition at line 267 of file CGBlocks.h.
Referenced by CGBlockInfo(), computeBlockInfo(), clang::CodeGen::CodeGenFunction::GenerateCopyHelperFunction(), and clang::CodeGen::CodeGenFunction::GenerateDestroyHelperFunction().
unsigned clang::CodeGen::CGBlockInfo::CXXThisIndex |
The field index of 'this' within the block, if there is one.
Definition at line 163 of file CGBlocks.h.
Referenced by CGBlockInfo(), clang::CodeGen::CGDebugInfo::EmitDeclareOfBlockLiteralArgVariable(), and clang::CodeGen::CodeGenFunction::GenerateBlockFunction().
CharUnits clang::CodeGen::CGBlockInfo::CXXThisOffset |
Definition at line 282 of file CGBlocks.h.
bool clang::CodeGen::CGBlockInfo::HasCapturedVariableLayout |
HasCapturedVariableLayout : True if block has captured variables and their layout meta-data has been generated.
Definition at line 262 of file CGBlocks.h.
Referenced by CGBlockInfo(), and computeBlockInfo().
bool clang::CodeGen::CGBlockInfo::HasCXXObject |
HasCXXObject - True if the block's custom copy/dispose functions need to be run even in GC mode.
Definition at line 254 of file CGBlocks.h.
Referenced by CGBlockInfo(), and computeBlockInfo().
RawAddress clang::CodeGen::CGBlockInfo::LocalAddress |
Definition at line 276 of file CGBlocks.h.
Referenced by CGBlockInfo(), and clang::CodeGen::CodeGenFunction::EmitBlockLiteral().
StringRef clang::CodeGen::CGBlockInfo::Name |
Name - The name of the block, kindof.
Definition at line 160 of file CGBlocks.h.
Referenced by CGBlockInfo().
bool clang::CodeGen::CGBlockInfo::NeedsCopyDispose |
True if the block has captures that would necessitate custom copy or dispose helper functions if the block were escaping.
Definition at line 247 of file CGBlocks.h.
Referenced by addBlockLayout(), buildBlockDescriptor(), CGBlockInfo(), and getBlockDescriptorName().
bool clang::CodeGen::CGBlockInfo::NoEscape |
Indicates whether the block is non-escaping.
Definition at line 250 of file CGBlocks.h.
Referenced by addBlockLayout(), CGBlockInfo(), and computeBlockInfo().
llvm::SmallVector<Capture, 4> clang::CodeGen::CGBlockInfo::SortedCaptures |
The block's captures. Non-constant captures are sorted by their offsets.
Definition at line 273 of file CGBlocks.h.
Referenced by buildCaptureMap(), computeBlockInfo(), clang::CodeGen::CodeGenFunction::GenerateCopyHelperFunction(), clang::CodeGen::CodeGenFunction::GenerateDestroyHelperFunction(), and getBlockDescriptorName().
llvm::StructType* clang::CodeGen::CGBlockInfo::StructureType |
Definition at line 277 of file CGBlocks.h.
Referenced by CGBlockInfo(), computeBlockInfo(), clang::CodeGen::CodeGenFunction::EmitBlockLiteral(), clang::CodeGen::CGDebugInfo::EmitDeclareOfBlockDeclRefVariable(), clang::CodeGen::CGDebugInfo::EmitDeclareOfBlockLiteralArgVariable(), clang::CodeGen::CodeGenFunction::GenerateCopyHelperFunction(), and clang::CodeGen::CodeGenFunction::GenerateDestroyHelperFunction().
|
mutable |
UsesStret : True if the block uses an stret return.
Mutable because it gets set later in the block-creation process.
Definition at line 258 of file CGBlocks.h.
Referenced by buildGlobalBlock(), CGBlockInfo(), and clang::CodeGen::CodeGenFunction::GenerateBlockFunction().