10 #ifndef LLVM_DEBUGINFO_PDB_IPDBSYMBOL_H
11 #define LLVM_DEBUGINFO_PDB_IPDBSYMBOL_H
20 #define FORWARD_SYMBOL_METHOD(MethodName) \
21 auto MethodName() const->decltype(RawSymbol->MethodName()) { \
22 return RawSymbol->MethodName(); \
25 #define FORWARD_CONCRETE_SYMBOL_ID_METHOD_WITH_NAME(ConcreteType, PrivateName, \
27 auto PublicName##Id() const->decltype(RawSymbol->PrivateName##Id()) { \
28 return RawSymbol->PrivateName##Id(); \
30 std::unique_ptr<ConcreteType> PublicName() const { \
31 uint32_t Id = PublicName##Id(); \
32 return getConcreteSymbolByIdHelper<ConcreteType>(Id); \
35 #define FORWARD_SYMBOL_ID_METHOD_WITH_NAME(PrivateName, PublicName) \
36 FORWARD_CONCRETE_SYMBOL_ID_METHOD_WITH_NAME(PDBSymbol, PrivateName, \
39 #define FORWARD_SYMBOL_ID_METHOD(MethodName) \
40 FORWARD_SYMBOL_ID_METHOD_WITH_NAME(MethodName, MethodName)
51 #define DECLARE_PDB_SYMBOL_CONCRETE_TYPE(TagValue) \
52 static const PDB_SymType Tag = TagValue; \
53 static bool classof(const PDBSymbol *S) { return S->getSymTag() == Tag; }
64 std::unique_ptr<IPDBRawSymbol>
Symbol);
68 static std::unique_ptr<PDBSymbol>
97 std::unique_ptr<PDBSymbol>
clone()
const;
104 return llvm::make_unique<ConcreteSymbolEnumerator<T>>(std::move(BaseIter));
109 std::unique_ptr<IPDBEnumSymbols>
128 template <
typename ConcreteType>
const IPDBSession & getSession() const
IPDBSession defines an interface used to provide a context for querying debug information from a debu...
void dumpProperties() const
std::unique_ptr< ConcreteSymbolEnumerator< T > > findAllChildren() const
PDB_NameSearchFlags
Defines flags used for enumerating child symbols.
std::unique_ptr< PDBSymbol > getSymbolByIdHelper(uint32_t Id) const
IPDBRawSymbol & getRawSymbol()
std::unique_ptr< IPDBEnumSymbols > findChildrenByRVA(PDB_SymType Type, StringRef Name, PDB_NameSearchFlags Flags, uint32_t RVA) const
std::unique_ptr< IPDBRawSymbol > RawSymbol
PDBSymbol(const IPDBSession &PDBSession, std::unique_ptr< IPDBRawSymbol > Symbol)
std::unordered_map< PDB_SymType, int > TagStats
static std::unique_ptr< PDBSymbol > create(const IPDBSession &PDBSession, std::unique_ptr< IPDBRawSymbol > Symbol)
block placement Basic Block Placement Stats
std::unique_ptr< IPDBEnumSymbols > findChildren(PDB_SymType Type, StringRef Name, PDB_NameSearchFlags Flags) const
void defaultDump(raw_ostream &OS, int Indent) const
std::unique_ptr< IPDBEnumSymbols > findInlineFramesByRVA(uint32_t RVA) const
PDB_SymType
These values correspond to the SymTagEnum enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/bkedss5f.aspx.
The instances of the Type class are immutable: once they are created, they are never changed...
std::unique_ptr< IPDBEnumSymbols > getChildStats(TagStats &Stats) const
std::unique_ptr< T > findOneChild() const
IPDBRawSymbol defines an interface used to represent an arbitrary symbol.
PDB_SymType getSymTag() const
std::unique_ptr< PDBSymbol > clone() const
PDBSymbol defines the base of the inheritance hierarchy for concrete symbol types (e...
void dumpChildStats() const
virtual void dump(PDBSymDumper &Dumper) const =0
Dumps the contents of a symbol a raw_ostream.
static std::vector< std::string > Flags
const IPDBRawSymbol & getRawSymbol() const
const IPDBSession & Session
std::unique_ptr< ConcreteType > getConcreteSymbolByIdHelper(uint32_t Id) const
This class implements an extremely fast bulk output stream that can only output to a stream...
virtual void dumpRight(PDBSymDumper &Dumper) const
For certain PDBSymbolTypes, dumps additional information for the type that normally goes on the right...
StringRef - Represent a constant reference to a string, i.e.
uint32_t getSymIndexId() const