LLVM  8.0.0svn
Go to the documentation of this file.
1 //===- DIARawSymbol.h - DIA implementation of IPDBRawSymbol ----*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
13 #include "DIASupport.h"
16 namespace llvm {
17 namespace pdb {
18 class DIASession;
19 class DIARawSymbol : public IPDBRawSymbol {
20 public:
21  DIARawSymbol(const DIASession &PDBSession, CComPtr<IDiaSymbol> DiaSymbol);
23  void dump(raw_ostream &OS, int Indent, PdbSymbolIdField ShowIdFields,
24  PdbSymbolIdField RecurseIdFields) const override;
26  CComPtr<IDiaSymbol> getDiaSymbol() const { return Symbol; }
28  std::unique_ptr<IPDBEnumSymbols>
29  findChildren(PDB_SymType Type) const override;
30  std::unique_ptr<IPDBEnumSymbols>
32  PDB_NameSearchFlags Flags) const override;
33  std::unique_ptr<IPDBEnumSymbols>
35  PDB_NameSearchFlags Flags,
36  uint32_t Section, uint32_t Offset) const override;
37  std::unique_ptr<IPDBEnumSymbols>
39  uint64_t VA) const override;
40  std::unique_ptr<IPDBEnumSymbols>
42  uint32_t RVA) const override;
44  std::unique_ptr<IPDBEnumSymbols>
45  findInlineFramesByAddr(uint32_t Section, uint32_t Offset) const override;
46  std::unique_ptr<IPDBEnumSymbols>
47  findInlineFramesByRVA(uint32_t RVA) const override;
48  std::unique_ptr<IPDBEnumSymbols>
49  findInlineFramesByVA(uint64_t VA) const override;
51  std::unique_ptr<IPDBEnumLineNumbers> findInlineeLines() const override;
52  std::unique_ptr<IPDBEnumLineNumbers>
54  uint32_t Length) const override;
55  std::unique_ptr<IPDBEnumLineNumbers>
56  findInlineeLinesByRVA(uint32_t RVA, uint32_t Length) const override;
57  std::unique_ptr<IPDBEnumLineNumbers>
58  findInlineeLinesByVA(uint64_t VA, uint32_t Length) const override;
60  void getDataBytes(llvm::SmallVector<uint8_t, 32> &bytes) const override;
61  void getFrontEndVersion(VersionInfo &Version) const override;
62  void getBackEndVersion(VersionInfo &Version) const override;
63  PDB_MemberAccess getAccess() const override;
64  uint32_t getAddressOffset() const override;
65  uint32_t getAddressSection() const override;
66  uint32_t getAge() const override;
67  SymIndexId getArrayIndexTypeId() const override;
68  uint32_t getBaseDataOffset() const override;
69  uint32_t getBaseDataSlot() const override;
70  SymIndexId getBaseSymbolId() const override;
71  PDB_BuiltinType getBuiltinType() const override;
72  uint32_t getBitPosition() const override;
73  PDB_CallingConv getCallingConvention() const override;
74  SymIndexId getClassParentId() const override;
75  std::string getCompilerName() const override;
76  uint32_t getCount() const override;
77  uint32_t getCountLiveRanges() const override;
78  PDB_Lang getLanguage() const override;
79  SymIndexId getLexicalParentId() const override;
80  std::string getLibraryName() const override;
85  SymIndexId getLowerBoundId() const override;
86  uint32_t getMemorySpaceKind() const override;
87  std::string getName() const override;
89  uint32_t getNumberOfColumns() const override;
90  uint32_t getNumberOfModifiers() const override;
91  uint32_t getNumberOfRegisterIndices() const override;
92  uint32_t getNumberOfRows() const override;
93  std::string getObjectFileName() const override;
94  uint32_t getOemId() const override;
95  SymIndexId getOemSymbolId() const override;
96  uint32_t getOffsetInUdt() const override;
97  PDB_Cpu getPlatform() const override;
98  uint32_t getRank() const override;
99  codeview::RegisterId getRegisterId() const override;
100  uint32_t getRegisterType() const override;
101  uint32_t getRelativeVirtualAddress() const override;
102  uint32_t getSamplerSlot() const override;
103  uint32_t getSignature() const override;
104  uint32_t getSizeInUdt() const override;
105  uint32_t getSlot() const override;
106  std::string getSourceFileName() const override;
107  std::unique_ptr<IPDBLineNumber> getSrcLineOnTypeDefn() const override;
108  uint32_t getStride() const override;
109  SymIndexId getSubTypeId() const override;
110  std::string getSymbolsFileName() const override;
111  SymIndexId getSymIndexId() const override;
112  uint32_t getTargetOffset() const override;
113  uint32_t getTargetRelativeVirtualAddress() const override;
114  uint64_t getTargetVirtualAddress() const override;
115  uint32_t getTargetSection() const override;
116  uint32_t getTextureSlot() const override;
117  uint32_t getTimeStamp() const override;
118  uint32_t getToken() const override;
119  SymIndexId getTypeId() const override;
120  uint32_t getUavSlot() const override;
121  std::string getUndecoratedName() const override;
122  std::string getUndecoratedNameEx(PDB_UndnameFlags Flags) const override;
123  SymIndexId getUnmodifiedTypeId() const override;
124  SymIndexId getUpperBoundId() const override;
125  Variant getValue() const override;
126  uint32_t getVirtualBaseDispIndex() const override;
127  uint32_t getVirtualBaseOffset() const override;
128  SymIndexId getVirtualTableShapeId() const override;
129  std::unique_ptr<PDBSymbolTypeBuiltin>
130  getVirtualBaseTableType() const override;
131  PDB_DataKind getDataKind() const override;
132  PDB_SymType getSymTag() const override;
133  codeview::GUID getGuid() const override;
134  int32_t getOffset() const override;
135  int32_t getThisAdjust() const override;
136  int32_t getVirtualBasePointerOffset() const override;
137  PDB_LocType getLocationType() const override;
138  PDB_Machine getMachineType() const override;
139  codeview::ThunkOrdinal getThunkOrdinal() const override;
140  uint64_t getLength() const override;
141  uint64_t getLiveRangeLength() const override;
142  uint64_t getVirtualAddress() const override;
143  PDB_UdtType getUdtKind() const override;
144  bool hasConstructor() const override;
145  bool hasCustomCallingConvention() const override;
146  bool hasFarReturn() const override;
147  bool isCode() const override;
148  bool isCompilerGenerated() const override;
149  bool isConstType() const override;
150  bool isEditAndContinueEnabled() const override;
151  bool isFunction() const override;
152  bool getAddressTaken() const override;
153  bool getNoStackOrdering() const override;
154  bool hasAlloca() const override;
155  bool hasAssignmentOperator() const override;
156  bool hasCTypes() const override;
157  bool hasCastOperator() const override;
158  bool hasDebugInfo() const override;
159  bool hasEH() const override;
160  bool hasEHa() const override;
161  bool hasInlAsm() const override;
162  bool hasInlineAttribute() const override;
163  bool hasInterruptReturn() const override;
164  bool hasFramePointer() const override;
165  bool hasLongJump() const override;
166  bool hasManagedCode() const override;
167  bool hasNestedTypes() const override;
168  bool hasNoInlineAttribute() const override;
169  bool hasNoReturnAttribute() const override;
170  bool hasOptimizedCodeDebugInfo() const override;
171  bool hasOverloadedOperator() const override;
172  bool hasSEH() const override;
173  bool hasSecurityChecks() const override;
174  bool hasSetJump() const override;
175  bool hasStrictGSCheck() const override;
176  bool isAcceleratorGroupSharedLocal() const override;
177  bool isAcceleratorPointerTagLiveRange() const override;
178  bool isAcceleratorStubFunction() const override;
179  bool isAggregated() const override;
180  bool isIntroVirtualFunction() const override;
181  bool isCVTCIL() const override;
182  bool isConstructorVirtualBase() const override;
183  bool isCxxReturnUdt() const override;
184  bool isDataAligned() const override;
185  bool isHLSLData() const override;
186  bool isHotpatchable() const override;
187  bool isIndirectVirtualBaseClass() const override;
188  bool isInterfaceUdt() const override;
189  bool isIntrinsic() const override;
190  bool isLTCG() const override;
191  bool isLocationControlFlowDependent() const override;
192  bool isMSILNetmodule() const override;
193  bool isMatrixRowMajor() const override;
194  bool isManagedCode() const override;
195  bool isMSILCode() const override;
196  bool isMultipleInheritance() const override;
197  bool isNaked() const override;
198  bool isNested() const override;
199  bool isOptimizedAway() const override;
200  bool isPacked() const override;
201  bool isPointerBasedOnSymbolValue() const override;
202  bool isPointerToDataMember() const override;
203  bool isPointerToMemberFunction() const override;
204  bool isPureVirtual() const override;
205  bool isRValueReference() const override;
206  bool isRefUdt() const override;
207  bool isReference() const override;
208  bool isRestrictedType() const override;
209  bool isReturnValue() const override;
210  bool isSafeBuffers() const override;
211  bool isScoped() const override;
212  bool isSdl() const override;
213  bool isSingleInheritance() const override;
214  bool isSplitted() const override;
215  bool isStatic() const override;
216  bool hasPrivateSymbols() const override;
217  bool isUnalignedType() const override;
218  bool isUnreached() const override;
219  bool isValueUdt() const override;
220  bool isVirtual() const override;
221  bool isVirtualBaseClass() const override;
222  bool isVirtualInheritance() const override;
223  bool isVolatileType() const override;
224  bool wasInlined() const override;
225  std::string getUnused() const override;
227 private:
228  const DIASession &Session;
229  CComPtr<IDiaSymbol> Symbol;
230 };
231 }
232 }
234 #endif
bool hasAlloca() const override
bool hasInlineAttribute() const override
bool hasNoReturnAttribute() const override
uint32_t getToken() const override
uint32_t getLiveRangeStartRelativeVirtualAddress() const override
bool hasInterruptReturn() const override
bool isRValueReference() const override
std::unique_ptr< IPDBEnumSymbols > findInlineFramesByVA(uint64_t VA) const override
std::unique_ptr< IPDBEnumSymbols > findInlineFramesByAddr(uint32_t Section, uint32_t Offset) const override
PDB_UdtType getUdtKind() const override
Compute iterated dominance frontiers using a linear time algorithm.
Definition: AllocatorList.h:24
int32_t getOffset() const override
void dump(raw_ostream &OS, int Indent, PdbSymbolIdField ShowIdFields, PdbSymbolIdField RecurseIdFields) const override
bool isStatic() const override
codeview::RegisterId getLocalBasePointerRegisterId() const override
uint32_t getNumberOfColumns() const override
uint32_t getTargetOffset() const override
bool hasOptimizedCodeDebugInfo() const override
SymIndexId getClassParentId() const override
These values correspond to the UdtKind enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/wcstk66t.aspx.
Definition: PDBTypes.h:236
uint32_t getTextureSlot() const override
bool isNaked() const override
uint32_t getVirtualBaseDispIndex() const override
Defines flags used for enumerating child symbols.
Definition: PDBTypes.h:99
bool isValueUdt() const override
std::unique_ptr< IPDBEnumLineNumbers > findInlineeLinesByAddr(uint32_t Section, uint32_t Offset, uint32_t Length) const override
SymIndexId getBaseSymbolId() const override
SymIndexId getOemSymbolId() const override
std::string getUnused() const override
bool isConstructorVirtualBase() const override
bool getNoStackOrdering() const override
bool isPureVirtual() const override
bool isSdl() const override
SymIndexId getVirtualTableShapeId() const override
std::string getSymbolsFileName() const override
std::unique_ptr< IPDBEnumLineNumbers > findInlineeLinesByVA(uint64_t VA, uint32_t Length) const override
bool isFunction() const override
bool isReturnValue() const override
PDB_Machine getMachineType() const override
bool isRefUdt() const override
bool hasManagedCode() const override
bool isVirtual() const override
bool hasOverloadedOperator() const override
bool hasCastOperator() const override
uint32_t getStride() const override
bool hasEHa() const override
bool isIntroVirtualFunction() const override
uint32_t getNumberOfRegisterIndices() const override
std::string getName() const override
codeview::ThunkOrdinal getThunkOrdinal() const override
SymIndexId getUnmodifiedTypeId() const override
This represents the &#39;GUID&#39; type from windows.h.
Definition: GUID.h:22
bool isScoped() const override
SymIndexId getLowerBoundId() const override
std::unique_ptr< IPDBLineNumber > getSrcLineOnTypeDefn() const override
std::string getUndecoratedNameEx(PDB_UndnameFlags Flags) const override
bool isCxxReturnUdt() const override
bool isVolatileType() const override
uint32_t getNumberOfAcceleratorPointerTags() const override
SymIndexId getUpperBoundId() const override
PDB_SymType getSymTag() const override
bool isNested() const override
bool isMSILNetmodule() const override
bool isPointerToMemberFunction() const override
uint64_t getLength() const override
bool isOptimizedAway() const override
SymIndexId getSymIndexId() const override
bool isIndirectVirtualBaseClass() const override
std::unique_ptr< IPDBEnumSymbols > findChildrenByVA(PDB_SymType Type, StringRef Name, PDB_NameSearchFlags Flags, uint64_t VA) const override
uint32_t getTimeStamp() const override
bool isIntrinsic() const override
These values correspond to the flags that can be combined to control the return of an undecorated nam...
Definition: PDBTypes.h:287
void getFrontEndVersion(VersionInfo &Version) const override
PDB_BuiltinType getBuiltinType() const override
bool hasCustomCallingConvention() const override
uint32_t getLiveRangeStartAddressOffset() const override
bool isLocationControlFlowDependent() const override
bool isAcceleratorPointerTagLiveRange() const override
bool isRestrictedType() const override
bool hasCTypes() const override
These values correspond to the SymTagEnum enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/bkedss5f.aspx.
Definition: PDBTypes.h:181
uint32_t getRank() const override
PDB_MemberAccess getAccess() const override
bool getAddressTaken() const override
uint32_t getTargetSection() const override
uint32_t getRegisterType() const override
bool isAcceleratorGroupSharedLocal() const override
bool isEditAndContinueEnabled() const override
The instances of the Type class are immutable: once they are created, they are never changed...
Definition: Type.h:46
These values correspond to the DataKind enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/b2x2t313.aspx.
Definition: PDBTypes.h:166
void getDataBytes(llvm::SmallVector< uint8_t, 32 > &bytes) const override
IPDBRawSymbol defines an interface used to represent an arbitrary symbol.
Definition: IPDBRawSymbol.h:50
bool isPointerBasedOnSymbolValue() const override
uint32_t getOffsetInUdt() const override
bool isAcceleratorStubFunction() const override
std::unique_ptr< IPDBEnumSymbols > findChildrenByAddr(PDB_SymType Type, StringRef Name, PDB_NameSearchFlags Flags, uint32_t Section, uint32_t Offset) const override
bool isDataAligned() const override
uint64_t getTargetVirtualAddress() const override
bool hasNestedTypes() const override
codeview::GUID getGuid() const override
SymIndexId getLexicalParentId() const override
bool isVirtualBaseClass() const override
bool hasEH() const override
bool wasInlined() const override
bool isAggregated() const override
bool isMSILCode() const override
uint32_t getSizeInUdt() const override
These values correspond to the LocationType enumeration, and are documented here: https://msdn...
Definition: PDBTypes.h:218
uint32_t getTargetRelativeVirtualAddress() const override
bool isPacked() const override
PDB_CallingConv getCallingConvention() const override
std::string getCompilerName() const override
uint64_t getLiveRangeLength() const override
bool isConstType() const override
bool isCode() const override
uint32_t getSignature() const override
These values correspond to the CV_CFL_LANG enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/bw3aekw6.aspx.
Definition: CodeView.h:144
bool hasSEH() const override
std::unique_ptr< IPDBEnumSymbols > findInlineFramesByRVA(uint32_t RVA) const override
bool isCVTCIL() const override
int32_t getVirtualBasePointerOffset() const override
bool isManagedCode() const override
bool hasPrivateSymbols() const override
bool isSafeBuffers() const override
These values correspond to the CV_CPU_TYPE_e enumeration, and are documented here: https://msdn...
Definition: CodeView.h:79
int32_t getThisAdjust() const override
std::string getLibraryName() const override
codeview::RegisterId getRegisterId() const override
bool isMatrixRowMajor() const override
bool isHLSLData() const override
uint32_t getSlot() const override
std::unique_ptr< IPDBEnumLineNumbers > findInlineeLinesByRVA(uint32_t RVA, uint32_t Length) const override
SymIndexId getArrayIndexTypeId() const override
bool hasLongJump() const override
bool hasAssignmentOperator() const override
uint32_t getVirtualBaseOffset() const override
DIARawSymbol(const DIASession &PDBSession, CComPtr< IDiaSymbol > DiaSymbol)
std::string getSourceFileName() const override
uint32_t getBaseDataOffset() const override
SymIndexId getTypeId() const override
bool hasSetJump() const override
bool isVirtualInheritance() const override
bool isUnreached() const override
SymIndexId getSubTypeId() const override
bool isPointerToDataMember() const override
uint32_t getNumberOfModifiers() const override
PDB_LocType getLocationType() const override
bool hasStrictGSCheck() const override
bool hasSecurityChecks() const override
void getBackEndVersion(VersionInfo &Version) const override
std::unique_ptr< IPDBEnumLineNumbers > findInlineeLines() const override
bool hasFramePointer() const override
uint32_t getNumberOfRows() const override
std::string getUndecoratedName() const override
uint32_t getAddressSection() const override
uint32_t getAge() const override
PDB_Cpu getPlatform() const override
CComPtr< IDiaSymbol > getDiaSymbol() const
Definition: DIARawSymbol.h:26
uint32_t getOemId() const override
bool isHotpatchable() const override
bool isMultipleInheritance() const override
These values correspond to the THUNK_ORDINAL enumeration.
Definition: CodeView.h:516
These values correspond to the Basictype enumeration, and are documented here: https://msdn.microsoft.com/en-us/library/4szdtzc3.aspx.
Definition: PDBTypes.h:261
Definition: JSON.cpp:592
std::unique_ptr< IPDBEnumSymbols > findChildren(PDB_SymType Type) const override
bool hasNoInlineAttribute() const override
bool isLTCG() const override
uint32_t getCount() const override
bool isSplitted() const override
uint64_t getVirtualAddress() const override
std::unique_ptr< IPDBEnumSymbols > findChildrenByRVA(PDB_SymType Type, StringRef Name, PDB_NameSearchFlags Flags, uint32_t RVA) const override
These values correspond to the CV_call_e enumeration, and are documented at the following locations: ...
Definition: CodeView.h:173
uint32_t getMemorySpaceKind() const override
This class implements an extremely fast bulk output stream that can only output to a stream...
Definition: raw_ostream.h:46
bool isCompilerGenerated() const override
StringRef - Represent a constant reference to a string, i.e.
Definition: StringRef.h:49
Variant getValue() const override
bool isSingleInheritance() const override
uint32_t getLiveRangeStartAddressSection() const override
PDB_Lang getLanguage() const override
std::string getObjectFileName() const override
bool isInterfaceUdt() const override
bool isReference() const override
PDB_DataKind getDataKind() const override
bool hasInlAsm() const override
uint32_t getAddressOffset() const override
uint32_t getUavSlot() const override
uint32_t getBitPosition() const override
uint32_t getBaseDataSlot() const override
const uint64_t Version
Definition: InstrProf.h:895
bool hasConstructor() const override
bool isUnalignedType() const override
uint32_t getCountLiveRanges() const override
uint32_t getSamplerSlot() const override
std::unique_ptr< PDBSymbolTypeBuiltin > getVirtualBaseTableType() const override
bool hasDebugInfo() const override
bool hasFarReturn() const override
uint32_t getRelativeVirtualAddress() const override
Definition: PDBTypes.h:310