LLVM  4.0.0
Public Types | Public Member Functions | Public Attributes | List of all members
llvm::LLVMContextImpl Class Reference

#include <LLVMContextImpl.h>

Collaboration diagram for llvm::LLVMContextImpl:
[legend]

Public Types

typedef DenseMap< APInt,
std::unique_ptr< ConstantInt >
, DenseMapAPIntKeyInfo
IntMapTy
 
typedef DenseMap< APFloat,
std::unique_ptr< ConstantFP >
, DenseMapAPFloatKeyInfo
FPMapTy
 
typedef ConstantUniqueMap
< ConstantArray
ArrayConstantsTy
 
typedef ConstantUniqueMap
< ConstantStruct
StructConstantsTy
 
typedef ConstantUniqueMap
< ConstantVector
VectorConstantsTy
 
typedef DenseSet< FunctionType
*, FunctionTypeKeyInfo
FunctionTypeSet
 
typedef DenseSet< StructType
*, AnonStructTypeKeyInfo
StructTypeSet
 
typedef DenseMap< Value
*, ValueHandleBase * > 
ValueHandlesTy
 ValueHandles - This map keeps track of all of the value handles that are watching a Value*. More...
 

Public Member Functions

int getOrAddScopeRecordIdxEntry (MDNode *N, int ExistingIdx)
 
int getOrAddScopeInlinedAtIdxEntry (MDNode *Scope, MDNode *IA, int ExistingIdx)
 
StringMapEntry< uint32_t > * getOrInsertBundleTag (StringRef Tag)
 
void getOperandBundleTags (SmallVectorImpl< StringRef > &Tags) const
 
uint32_t getOperandBundleTagID (StringRef Tag) const
 
 LLVMContextImpl (LLVMContext &C)
 
 ~LLVMContextImpl ()
 
void dropTriviallyDeadConstantArrays ()
 Destroy the ConstantArrays if they are not used. More...
 
OptBisectgetOptBisect ()
 Access the object which manages optimization bisection for failure analysis. More...
 

Public Attributes

SmallPtrSet< Module *, 4 > OwnedModules
 OwnedModules - The set of modules instantiated in this context, and which will be automatically deleted if this context is deleted. More...
 
LLVMContext::InlineAsmDiagHandlerTy InlineAsmDiagHandler
 
void * InlineAsmDiagContext
 
LLVMContext::DiagnosticHandlerTy DiagnosticHandler
 
void * DiagnosticContext
 
bool RespectDiagnosticFilters
 
bool DiagnosticHotnessRequested
 
std::unique_ptr< yaml::OutputDiagnosticsOutputFile
 
LLVMContext::YieldCallbackTy YieldCallback
 
void * YieldOpaqueHandle
 
IntMapTy IntConstants
 
FPMapTy FPConstants
 
FoldingSet< AttributeImplAttrsSet
 
FoldingSet< AttributeSetImplAttrsLists
 
FoldingSet< AttributeSetNodeAttrsSetNodes
 
StringMap< MDString,
BumpPtrAllocator
MDStringCache
 
DenseMap< Value
*, ValueAsMetadata * > 
ValuesAsMetadata
 
DenseMap< Metadata
*, MetadataAsValue * > 
MetadataAsValues
 
DenseMap< const Value
*, ValueName * > 
ValueNames
 
Optional< DenseMap< const
MDString *, DICompositeType * > > 
DITypeMap
 
std::vector< MDNode * > DistinctMDNodes
 
DenseMap< Type
*, std::unique_ptr
< ConstantAggregateZero > > 
CAZConstants
 
ArrayConstantsTy ArrayConstants
 
StructConstantsTy StructConstants
 
VectorConstantsTy VectorConstants
 
DenseMap< PointerType
*, std::unique_ptr
< ConstantPointerNull > > 
CPNConstants
 
DenseMap< Type
*, std::unique_ptr< UndefValue > > 
UVConstants
 
StringMap
< ConstantDataSequential * > 
CDSConstants
 
DenseMap< std::pair< const
Function *, const BasicBlock * >
, BlockAddress * > 
BlockAddresses
 
ConstantUniqueMap< ConstantExprExprConstants
 
ConstantUniqueMap< InlineAsmInlineAsms
 
ConstantIntTheTrueVal
 
ConstantIntTheFalseVal
 
std::unique_ptr
< ConstantTokenNone
TheNoneToken
 
Type VoidTy
 
Type LabelTy
 
Type HalfTy
 
Type FloatTy
 
Type DoubleTy
 
Type MetadataTy
 
Type TokenTy
 
Type X86_FP80Ty
 
Type FP128Ty
 
Type PPC_FP128Ty
 
Type X86_MMXTy
 
IntegerType Int1Ty
 
IntegerType Int8Ty
 
IntegerType Int16Ty
 
IntegerType Int32Ty
 
IntegerType Int64Ty
 
IntegerType Int128Ty
 
BumpPtrAllocator TypeAllocator
 TypeAllocator - All dynamically allocated types are allocated from this. More...
 
DenseMap< unsigned, IntegerType * > IntegerTypes
 
FunctionTypeSet FunctionTypes
 
StructTypeSet AnonStructTypes
 
StringMap< StructType * > NamedStructTypes
 
unsigned NamedStructTypesUniqueID
 
DenseMap< std::pair< Type
*, uint64_t >, ArrayType * > 
ArrayTypes
 
DenseMap< std::pair< Type
*, unsigned >, VectorType * > 
VectorTypes
 
DenseMap< Type *, PointerType * > PointerTypes
 
DenseMap< std::pair< Type
*, unsigned >, PointerType * > 
ASPointerTypes
 
ValueHandlesTy ValueHandles
 
StringMap< unsignedCustomMDKindNames
 CustomMDKindNames - Map to hold the metadata string to ID mapping. More...
 
DenseMap< const Instruction
*, MDAttachmentMap
InstructionMetadata
 Collection of per-instruction metadata used in this context. More...
 
DenseMap< const GlobalObject
*, MDGlobalAttachmentMap
GlobalObjectMetadata
 Collection of per-GlobalObject metadata used in this context. More...
 
DenseMap< const GlobalObject
*, StringRef
GlobalObjectSections
 Collection of per-GlobalObject sections used in this context. More...
 
StringSet SectionStrings
 Stable collection of section strings. More...
 
DenseMap< std::pair< const
char *, unsigned >, unsigned
DiscriminatorTable
 DiscriminatorTable - This table maps file:line locations to an integer representing the next DWARF path discriminator to assign to instructions in different blocks at the same location. More...
 
StringMap< uint32_tBundleTagCache
 A set of interned tags for operand bundles. More...
 
DenseMap< const Function
*, std::string > 
GCNames
 Maintain the GC name for each function. More...
 
bool DiscardValueNames = false
 Flag to indicate if Value (other than GlobalValue) retains their name or not. More...
 

Detailed Description

Definition at line 1081 of file LLVMContextImpl.h.

Member Typedef Documentation

Definition at line 1132 of file LLVMContextImpl.h.

Definition at line 1104 of file LLVMContextImpl.h.

Definition at line 1170 of file LLVMContextImpl.h.

Definition at line 1100 of file LLVMContextImpl.h.

Definition at line 1135 of file LLVMContextImpl.h.

Definition at line 1172 of file LLVMContextImpl.h.

ValueHandles - This map keeps track of all of the value handles that are watching a Value*.

The Value::HasValueHandle bit is used to know whether or not a value has an entry in this map.

Definition at line 1186 of file LLVMContextImpl.h.

Definition at line 1138 of file LLVMContextImpl.h.

Constructor & Destructor Documentation

LLVMContextImpl::LLVMContextImpl ( LLVMContext C)
LLVMContextImpl::~LLVMContextImpl ( )

Member Function Documentation

void LLVMContextImpl::dropTriviallyDeadConstantArrays ( )

Destroy the ConstantArrays if they are not used.

Definition at line 146 of file LLVMContextImpl.cpp.

References ArrayConstants, llvm::ConstantUniqueMap< ConstantClass >::begin(), C, E, llvm::ConstantUniqueMap< ConstantClass >::end(), and I.

Referenced by llvm::Module::dropTriviallyDeadConstantArrays().

uint32_t LLVMContextImpl::getOperandBundleTagID ( StringRef  Tag) const
void LLVMContextImpl::getOperandBundleTags ( SmallVectorImpl< StringRef > &  Tags) const
OptBisect & LLVMContextImpl::getOptBisect ( )

Access the object which manages optimization bisection for failure analysis.

Definition at line 251 of file LLVMContextImpl.cpp.

References OptBisector.

Referenced by llvm::LLVMContext::getOptBisect().

int llvm::LLVMContextImpl::getOrAddScopeInlinedAtIdxEntry ( MDNode Scope,
MDNode IA,
int  ExistingIdx 
)
int llvm::LLVMContextImpl::getOrAddScopeRecordIdxEntry ( MDNode N,
int  ExistingIdx 
)
StringMapEntry< uint32_t > * LLVMContextImpl::getOrInsertBundleTag ( StringRef  Tag)

Member Data Documentation

StructTypeSet llvm::LLVMContextImpl::AnonStructTypes

Definition at line 1173 of file LLVMContextImpl.h.

Referenced by llvm::StructType::get().

ArrayConstantsTy llvm::LLVMContextImpl::ArrayConstants
DenseMap<std::pair<Type *, uint64_t>, ArrayType*> llvm::LLVMContextImpl::ArrayTypes

Definition at line 1177 of file LLVMContextImpl.h.

Referenced by llvm::ArrayType::get().

DenseMap<std::pair<Type*, unsigned>, PointerType*> llvm::LLVMContextImpl::ASPointerTypes

Definition at line 1180 of file LLVMContextImpl.h.

Referenced by llvm::PointerType::get().

FoldingSet<AttributeSetImpl> llvm::LLVMContextImpl::AttrsLists

Definition at line 1108 of file LLVMContextImpl.h.

Referenced by ~LLVMContextImpl().

FoldingSet<AttributeImpl> llvm::LLVMContextImpl::AttrsSet

Definition at line 1107 of file LLVMContextImpl.h.

Referenced by llvm::Attribute::get(), and ~LLVMContextImpl().

FoldingSet<AttributeSetNode> llvm::LLVMContextImpl::AttrsSetNodes

Definition at line 1109 of file LLVMContextImpl.h.

Referenced by llvm::AttributeSetNode::get(), and ~LLVMContextImpl().

DenseMap<std::pair<const Function *, const BasicBlock *>, BlockAddress *> llvm::LLVMContextImpl::BlockAddresses

Definition at line 1148 of file LLVMContextImpl.h.

Referenced by llvm::BlockAddress::get(), and llvm::BlockAddress::lookup().

StringMap<uint32_t> llvm::LLVMContextImpl::BundleTagCache

A set of interned tags for operand bundles.

The StringMap maps bundle tags to their IDs.

See Also
LLVMContext::getOperandBundleTagID

Definition at line 1216 of file LLVMContextImpl.h.

Referenced by getOperandBundleTagID(), getOperandBundleTags(), and getOrInsertBundleTag().

DenseMap<Type *, std::unique_ptr<ConstantAggregateZero> > llvm::LLVMContextImpl::CAZConstants

Definition at line 1130 of file LLVMContextImpl.h.

Referenced by llvm::ConstantAggregateZero::get(), and ~LLVMContextImpl().

StringMap<ConstantDataSequential*> llvm::LLVMContextImpl::CDSConstants

Definition at line 1145 of file LLVMContextImpl.h.

Referenced by llvm::ConstantDataSequential::getImpl(), and ~LLVMContextImpl().

DenseMap<PointerType *, std::unique_ptr<ConstantPointerNull> > llvm::LLVMContextImpl::CPNConstants

Definition at line 1141 of file LLVMContextImpl.h.

Referenced by llvm::ConstantPointerNull::get(), and ~LLVMContextImpl().

StringMap<unsigned> llvm::LLVMContextImpl::CustomMDKindNames

CustomMDKindNames - Map to hold the metadata string to ID mapping.

Definition at line 1190 of file LLVMContextImpl.h.

Referenced by llvm::LLVMContext::getMDKindID(), and llvm::LLVMContext::getMDKindNames().

void* llvm::LLVMContextImpl::DiagnosticContext
LLVMContext::DiagnosticHandlerTy llvm::LLVMContextImpl::DiagnosticHandler
bool llvm::LLVMContextImpl::DiagnosticHotnessRequested
std::unique_ptr<yaml::Output> llvm::LLVMContextImpl::DiagnosticsOutputFile
bool llvm::LLVMContextImpl::DiscardValueNames = false

Flag to indicate if Value (other than GlobalValue) retains their name or not.

Definition at line 1231 of file LLVMContextImpl.h.

Referenced by llvm::LLVMContext::setDiscardValueNames(), and llvm::LLVMContext::shouldDiscardValueNames().

DenseMap<std::pair<const char *, unsigned>, unsigned> llvm::LLVMContextImpl::DiscriminatorTable

DiscriminatorTable - This table maps file:line locations to an integer representing the next DWARF path discriminator to assign to instructions in different blocks at the same location.

Definition at line 1207 of file LLVMContextImpl.h.

std::vector<MDNode *> llvm::LLVMContextImpl::DistinctMDNodes

Definition at line 1128 of file LLVMContextImpl.h.

Referenced by llvm::MDNode::storeDistinctInContext(), and ~LLVMContextImpl().

Optional<DenseMap<const MDString *, DICompositeType *> > llvm::LLVMContextImpl::DITypeMap
Type llvm::LLVMContextImpl::DoubleTy

Definition at line 1159 of file LLVMContextImpl.h.

Referenced by llvm::Type::getDoubleTy().

ConstantUniqueMap<ConstantExpr> llvm::LLVMContextImpl::ExprConstants
Type llvm::LLVMContextImpl::FloatTy

Definition at line 1159 of file LLVMContextImpl.h.

Referenced by llvm::Type::getFloatTy().

Type llvm::LLVMContextImpl::FP128Ty

Definition at line 1160 of file LLVMContextImpl.h.

Referenced by llvm::Type::getFP128Ty().

FPMapTy llvm::LLVMContextImpl::FPConstants

Definition at line 1105 of file LLVMContextImpl.h.

Referenced by llvm::ConstantFP::get(), and ~LLVMContextImpl().

FunctionTypeSet llvm::LLVMContextImpl::FunctionTypes

Definition at line 1171 of file LLVMContextImpl.h.

Referenced by llvm::FunctionType::get().

DenseMap<const Function*, std::string> llvm::LLVMContextImpl::GCNames

Maintain the GC name for each function.

This saves allocating an additional word in Function for programs which do not use GC (i.e., most programs) at the cost of increased overhead for clients which do use GC.

Definition at line 1227 of file LLVMContextImpl.h.

Referenced by llvm::LLVMContext::deleteGC(), llvm::LLVMContext::getGC(), and llvm::LLVMContext::setGC().

DenseMap<const GlobalObject *, MDGlobalAttachmentMap> llvm::LLVMContextImpl::GlobalObjectMetadata
DenseMap<const GlobalObject *, StringRef> llvm::LLVMContextImpl::GlobalObjectSections

Collection of per-GlobalObject sections used in this context.

Definition at line 1199 of file LLVMContextImpl.h.

Referenced by llvm::GlobalObject::setSection().

Type llvm::LLVMContextImpl::HalfTy

Definition at line 1159 of file LLVMContextImpl.h.

Referenced by llvm::Type::getHalfTy().

void* llvm::LLVMContextImpl::InlineAsmDiagContext
LLVMContext::InlineAsmDiagHandlerTy llvm::LLVMContextImpl::InlineAsmDiagHandler
ConstantUniqueMap<InlineAsm> llvm::LLVMContextImpl::InlineAsms

Definition at line 1151 of file LLVMContextImpl.h.

Referenced by llvm::InlineAsm::get(), and ~LLVMContextImpl().

DenseMap<const Instruction *, MDAttachmentMap> llvm::LLVMContextImpl::InstructionMetadata

Collection of per-instruction metadata used in this context.

Definition at line 1193 of file LLVMContextImpl.h.

Referenced by llvm::Instruction::dropUnknownNonDebugMetadata(), and llvm::Instruction::setMetadata().

IntegerType llvm::LLVMContextImpl::Int128Ty

Definition at line 1161 of file LLVMContextImpl.h.

Referenced by llvm::Type::getInt128Ty().

IntegerType llvm::LLVMContextImpl::Int16Ty

Definition at line 1161 of file LLVMContextImpl.h.

Referenced by llvm::Type::getInt16Ty().

IntegerType llvm::LLVMContextImpl::Int1Ty

Definition at line 1161 of file LLVMContextImpl.h.

Referenced by llvm::Type::getInt1Ty().

IntegerType llvm::LLVMContextImpl::Int32Ty

Definition at line 1161 of file LLVMContextImpl.h.

Referenced by llvm::Type::getInt32Ty().

IntegerType llvm::LLVMContextImpl::Int64Ty

Definition at line 1161 of file LLVMContextImpl.h.

Referenced by llvm::Type::getInt64Ty().

IntegerType llvm::LLVMContextImpl::Int8Ty

Definition at line 1161 of file LLVMContextImpl.h.

Referenced by llvm::Type::getInt8Ty().

IntMapTy llvm::LLVMContextImpl::IntConstants

Definition at line 1101 of file LLVMContextImpl.h.

Referenced by llvm::ConstantInt::get(), and ~LLVMContextImpl().

DenseMap<unsigned, IntegerType*> llvm::LLVMContextImpl::IntegerTypes

Definition at line 1168 of file LLVMContextImpl.h.

Referenced by llvm::IntegerType::get().

Type llvm::LLVMContextImpl::LabelTy

Definition at line 1159 of file LLVMContextImpl.h.

Referenced by llvm::Type::getLabelTy().

StringMap<MDString, BumpPtrAllocator> llvm::LLVMContextImpl::MDStringCache

Definition at line 1111 of file LLVMContextImpl.h.

Referenced by llvm::MDString::get().

DenseMap<Metadata *, MetadataAsValue *> llvm::LLVMContextImpl::MetadataAsValues
Type llvm::LLVMContextImpl::MetadataTy

Definition at line 1159 of file LLVMContextImpl.h.

Referenced by llvm::Type::getMetadataTy().

StringMap<StructType*> llvm::LLVMContextImpl::NamedStructTypes

Definition at line 1174 of file LLVMContextImpl.h.

Referenced by llvm::Module::getTypeByName(), and llvm::StructType::setName().

unsigned llvm::LLVMContextImpl::NamedStructTypesUniqueID

Definition at line 1175 of file LLVMContextImpl.h.

Referenced by LLVMContextImpl(), and llvm::StructType::setName().

SmallPtrSet<Module*, 4> llvm::LLVMContextImpl::OwnedModules

OwnedModules - The set of modules instantiated in this context, and which will be automatically deleted if this context is deleted.

Definition at line 1085 of file LLVMContextImpl.h.

Referenced by ~LLVMContextImpl().

DenseMap<Type*, PointerType*> llvm::LLVMContextImpl::PointerTypes

Definition at line 1179 of file LLVMContextImpl.h.

Referenced by llvm::PointerType::get().

Type llvm::LLVMContextImpl::PPC_FP128Ty

Definition at line 1160 of file LLVMContextImpl.h.

Referenced by llvm::Type::getPPC_FP128Ty().

bool llvm::LLVMContextImpl::RespectDiagnosticFilters
StringSet llvm::LLVMContextImpl::SectionStrings

Stable collection of section strings.

Definition at line 1202 of file LLVMContextImpl.h.

Referenced by llvm::GlobalObject::setSection().

StructConstantsTy llvm::LLVMContextImpl::StructConstants

Definition at line 1136 of file LLVMContextImpl.h.

Referenced by llvm::ConstantStruct::get(), and ~LLVMContextImpl().

ConstantInt* llvm::LLVMContextImpl::TheFalseVal

Definition at line 1154 of file LLVMContextImpl.h.

Referenced by llvm::ConstantInt::getFalse().

std::unique_ptr<ConstantTokenNone> llvm::LLVMContextImpl::TheNoneToken

Definition at line 1156 of file LLVMContextImpl.h.

Referenced by llvm::ConstantTokenNone::get().

ConstantInt* llvm::LLVMContextImpl::TheTrueVal

Definition at line 1153 of file LLVMContextImpl.h.

Referenced by llvm::ConstantInt::getTrue().

Type llvm::LLVMContextImpl::TokenTy

Definition at line 1159 of file LLVMContextImpl.h.

Referenced by llvm::Type::getTokenTy().

BumpPtrAllocator llvm::LLVMContextImpl::TypeAllocator

TypeAllocator - All dynamically allocated types are allocated from this.

They live forever until the context is torn down.

Definition at line 1166 of file LLVMContextImpl.h.

Referenced by llvm::StructType::create(), llvm::IntegerType::get(), llvm::FunctionType::get(), llvm::StructType::get(), llvm::ArrayType::get(), llvm::VectorType::get(), and llvm::PointerType::get().

DenseMap<Type *, std::unique_ptr<UndefValue> > llvm::LLVMContextImpl::UVConstants

Definition at line 1143 of file LLVMContextImpl.h.

Referenced by llvm::UndefValue::get(), and ~LLVMContextImpl().

ValueHandlesTy llvm::LLVMContextImpl::ValueHandles

Definition at line 1187 of file LLVMContextImpl.h.

Referenced by llvm::ValueHandleBase::ValueIsDeleted().

DenseMap<const Value*, ValueName*> llvm::LLVMContextImpl::ValueNames

Definition at line 1115 of file LLVMContextImpl.h.

Referenced by llvm::Value::getValueName(), and llvm::Value::setValueName().

DenseMap<Value *, ValueAsMetadata *> llvm::LLVMContextImpl::ValuesAsMetadata
VectorConstantsTy llvm::LLVMContextImpl::VectorConstants

Definition at line 1139 of file LLVMContextImpl.h.

Referenced by llvm::ConstantVector::get(), and ~LLVMContextImpl().

DenseMap<std::pair<Type *, unsigned>, VectorType*> llvm::LLVMContextImpl::VectorTypes

Definition at line 1178 of file LLVMContextImpl.h.

Referenced by llvm::VectorType::get().

Type llvm::LLVMContextImpl::VoidTy

Definition at line 1159 of file LLVMContextImpl.h.

Referenced by llvm::Type::getVoidTy().

Type llvm::LLVMContextImpl::X86_FP80Ty

Definition at line 1160 of file LLVMContextImpl.h.

Referenced by llvm::Type::getX86_FP80Ty().

Type llvm::LLVMContextImpl::X86_MMXTy

Definition at line 1160 of file LLVMContextImpl.h.

Referenced by llvm::Type::getX86_MMXTy().

LLVMContext::YieldCallbackTy llvm::LLVMContextImpl::YieldCallback
void* llvm::LLVMContextImpl::YieldOpaqueHandle

The documentation for this class was generated from the following files: