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