45#define DEBUG_TYPE "CodeViewUtilities"
48namespace logicalview {
79#define CV_TYPE(enum, val) {#enum, enum},
80#include "llvm/DebugInfo/CodeView/CodeViewTypes.def"
91 auto GetName = [&](
auto Record) {
100 if (RK == TypeRecordKind::Class || RK == TypeRecordKind::Struct)
102 else if (RK == TypeRecordKind::Union)
104 else if (RK == TypeRecordKind::Enum)
114#define DEBUG_TYPE "CodeViewDataVisitor"
117namespace logicalview {
128 using RecordEntry = std::pair<TypeLeafKind, LVElement *>;
129 using RecordTable = std::map<TypeIndex, RecordEntry>;
130 RecordTable RecordFromTypes;
131 RecordTable RecordFromIds;
133 using NameTable = std::map<StringRef, TypeIndex>;
134 NameTable NameFromTypes;
135 NameTable NameFromIds;
138 LVTypeRecords(
LVShared *Shared) : Shared(Shared) {}
147class LVForwardReferences {
149 using ForwardEntry = std::pair<TypeIndex, TypeIndex>;
150 using ForwardTypeNames = std::map<StringRef, ForwardEntry>;
151 ForwardTypeNames ForwardTypesNames;
154 using ForwardType = std::map<TypeIndex, TypeIndex>;
155 ForwardType ForwardTypes;
159 ForwardTypes.emplace(TIForward, TIReference);
163 if (ForwardTypesNames.find(
Name) == ForwardTypesNames.end()) {
164 ForwardTypesNames.emplace(
165 std::piecewise_construct, std::forward_as_tuple(
Name),
169 ForwardTypesNames[
Name].first = TIForward;
170 add(TIForward, ForwardTypesNames[
Name].second);
176 if (ForwardTypesNames.find(
Name) != ForwardTypesNames.end()) {
178 ForwardTypesNames[
Name].second = TIReference;
179 add(ForwardTypesNames[
Name].first, TIReference);
182 ForwardTypesNames.emplace(
183 std::piecewise_construct, std::forward_as_tuple(
Name),
189 LVForwardReferences() =
default;
195 (IsForwardRef) ? add(
Name, TI) : update(
Name, TI);
199 return (ForwardTypes.find(TIForward) != ForwardTypes.end())
200 ? ForwardTypes[TIForward]
205 return (ForwardTypesNames.find(
Name) != ForwardTypesNames.end())
206 ? ForwardTypesNames[
Name].second
219class LVNamespaceDeduction {
222 using Names = std::map<StringRef, LVScope *>;
223 Names NamespaceNames;
225 using LookupSet = std::set<StringRef>;
226 LookupSet DeducedScopes;
227 LookupSet UnresolvedScopes;
228 LookupSet IdentifiedNamespaces;
231 if (NamespaceNames.find(
Name) == NamespaceNames.end())
232 NamespaceNames.emplace(
Name, Namespace);
236 LVNamespaceDeduction(
LVShared *Shared) : Shared(Shared) {}
245 LVScope *Namespace = (NamespaceNames.find(
Name) != NamespaceNames.end())
246 ? NamespaceNames[
Name]
255 if (Components.empty())
258 LVStringRefs::size_type FirstNamespace = 0;
259 LVStringRefs::size_type FirstNonNamespace;
260 for (LVStringRefs::size_type
Index = 0;
Index < Components.size();
262 FirstNonNamespace =
Index;
263 LookupSet::iterator Iter = IdentifiedNamespaces.find(Components[
Index]);
264 if (Iter == IdentifiedNamespaces.end())
268 return std::make_tuple(FirstNamespace, FirstNonNamespace);
273class LVStringRecords {
274 using StringEntry = std::tuple<uint32_t, std::string, LVScopeCompileUnit *>;
275 using StringIds = std::map<TypeIndex, StringEntry>;
279 LVStringRecords() =
default;
283 if (Strings.find(TI) == Strings.end())
285 std::piecewise_construct, std::forward_as_tuple(TI),
286 std::forward_as_tuple(++
Index, std::string(
String),
nullptr));
290 StringIds::iterator Iter = Strings.find(TI);
291 return Iter != Strings.end() ? std::get<1>(Iter->second) :
StringRef{};
295 StringIds::iterator Iter = Strings.find(TI);
296 return Iter != Strings.end() ? std::get<0>(Iter->second) : 0;
339 (StreamIdx ==
StreamTPI) ? RecordFromTypes : RecordFromIds;
340 Target.emplace(std::piecewise_construct, std::forward_as_tuple(TI),
341 std::forward_as_tuple(
Kind, Element));
345 NameTable &
Target = (StreamIdx ==
StreamTPI) ? NameFromTypes : NameFromIds;
351 (StreamIdx ==
StreamTPI) ? RecordFromTypes : RecordFromIds;
354 RecordTable::iterator Iter =
Target.find(TI);
355 if (Iter !=
Target.end()) {
356 Element = Iter->second.second;
357 if (Element || !Create)
364 Element->setOffsetFromTypeIndex();
365 Target[TI].second = Element;
372 NameTable &
Target = (StreamIdx ==
StreamTPI) ? NameFromTypes : NameFromIds;
377void LVStringRecords::addFilenames() {
378 for (StringIds::const_reference Entry : Strings) {
387 for (StringIds::reference Entry : Strings)
388 if (!std::get<2>(
Entry.second))
396 DeducedScopes.insert(InnerComponent);
397 if (OuterComponent.
size())
398 UnresolvedScopes.insert(OuterComponent);
401void LVNamespaceDeduction::init() {
408 for (
const StringRef &Unresolved : UnresolvedScopes) {
410 for (
const StringRef &Component : Components) {
411 LookupSet::iterator Iter = DeducedScopes.find(Component);
412 if (Iter == DeducedScopes.end())
413 IdentifiedNamespaces.insert(Component);
418 auto Print = [&](LookupSet &Container,
const char *Title) {
419 auto Header = [&]() {
429 Print(DeducedScopes,
"Deducted Scopes");
430 Print(UnresolvedScopes,
"Unresolved Scopes");
431 Print(IdentifiedNamespaces,
"Namespaces");
437 for (
const StringRef &Component : Components)
441 if (Components.empty())
447 for (
const StringRef &Component : Components) {
449 Namespace =
find(Component);
453 Namespace = Shared->
Reader->createScopeNamespace();
454 Namespace->
setTag(dwarf::DW_TAG_namespace);
458 add(Component, Namespace);
469 LookupSet::iterator Iter = IdentifiedNamespaces.find(Component);
470 return Iter == IdentifiedNamespaces.end();
474 {
dbgs() <<
formatv(
"ScopedName: '{0}'\n", ScopedName.
str().c_str()); });
476 return get(Components);
480#define DEBUG_TYPE "CodeViewTypeVisitor"
501 if (
options().getInternalTag())
506 CurrentTypeIndex = TI;
545 printTypeIndex(
"ArgType", Arg,
StreamIPI);
555 TI = Args.getArgs()[BuildInfoRecord::BuildInfoArg::CurrentDirectory];
561 TI = Args.getArgs()[BuildInfoRecord::BuildInfoArg::SourceFile];
573 printTypeIndex(
"TypeIndex", CurrentTypeIndex,
StreamTPI);
591 printTypeIndex(
"TypeIndex", CurrentTypeIndex,
StreamTPI);
592 printTypeIndex(
"FieldListType",
Enum.getFieldList(),
StreamTPI);
604 printTypeIndex(
"TypeIndex", CurrentTypeIndex,
StreamTPI);
605 printTypeIndex(
"Type", Func.getFunctionType(),
StreamTPI);
606 printTypeIndex(
"Parent", Func.getParentScope(),
StreamTPI);
618 printTypeIndex(
"TypeIndex", CurrentTypeIndex,
StreamTPI);
645 printTypeIndex(
"SourceFile",
Line.getSourceFile(),
StreamIPI);
675#define DEBUG_TYPE "CodeViewSymbolVisitor"
684 Reader->printRelocatedField(
Label, CoffSection, RelocOffset,
Offset,
705 return Reader->CVStringTable;
708void LVSymbolVisitor::printLocalVariableAddrRange(
710 DictScope S(W,
"LocalVariableAddrRange");
718void LVSymbolVisitor::printLocalVariableAddrGap(
722 W.
printHex(
"GapStartOffset", Gap.GapStartOffset);
742 if (
options().getInternalTag())
756 IsCompileUnit =
false;
804 if (
options().getGeneralCollectRanges()) {
810 Scope->addObject(LowPC, HighPC);
821 printTypeIndex(
"Type",
Local.Type);
827 Symbol->setName(
Local.Name);
835 Symbol->resetIsVariable();
837 if (
Local.Name ==
"this") {
838 Symbol->setIsParameter();
839 Symbol->setIsArtificial();
842 bool(
Local.Offset > 0) ? Symbol->setIsParameter()
843 : Symbol->setIsVariable();
847 if (Symbol->getIsParameter())
848 Symbol->setTag(dwarf::DW_TAG_formal_parameter);
851 if (Element && Element->getIsScoped()) {
853 LVScope *Parent = Symbol->getFunctionParent();
866 Symbol->setType(Element);
876 printTypeIndex(
"Type",
Local.Type);
882 Symbol->setName(
Local.Name);
885 Symbol->resetIsVariable();
888 if (
Local.Name ==
"this") {
889 Symbol->setIsArtificial();
890 Symbol->setIsParameter();
893 determineSymbolKind(Symbol,
Local.Register);
897 if (Symbol->getIsParameter())
898 Symbol->setTag(dwarf::DW_TAG_formal_parameter);
901 if (Element && Element->getIsScoped()) {
903 LVScope *Parent = Symbol->getFunctionParent();
916 Symbol->setType(Element);
962 Scope->setName(CurrentObjectName);
963 if (
options().getAttributeProducer())
964 Scope->setProducer(Compile2.
Version);
976 CurrentObjectName =
"";
1007 Scope->setName(CurrentObjectName);
1008 if (
options().getAttributeProducer())
1009 Scope->setProducer(Compile3.
Version);
1021 CurrentObjectName =
"";
1029 printTypeIndex(
"Type",
Constant.Type);
1037 Symbol->resetIncludeInPrint();
1055 if (
LVSymbol *Symbol = LocalSymbol) {
1056 Symbol->setHasCodeViewLocation();
1057 LocalSymbol =
nullptr;
1064 Symbol->addLocation(Attr, 0, 0, 0, 0);
1065 Symbol->addLocationOperands(
LVSmall(Attr), {Operand1});
1080 printLocalVariableAddrRange(DefRangeFramePointerRel.
Range,
1082 printLocalVariableAddrGap(DefRangeFramePointerRel.
Gaps);
1089 if (
LVSymbol *Symbol = LocalSymbol) {
1090 Symbol->setHasCodeViewLocation();
1091 LocalSymbol =
nullptr;
1103 Symbol->addLocationOperands(
LVSmall(Attr), {Operand1});
1122 printLocalVariableAddrRange(DefRangeRegisterRel.
Range,
1124 printLocalVariableAddrGap(DefRangeRegisterRel.
Gaps);
1127 if (
LVSymbol *Symbol = LocalSymbol) {
1128 Symbol->setHasCodeViewLocation();
1129 LocalSymbol =
nullptr;
1142 Symbol->addLocationOperands(
LVSmall(Attr), {Operand1, Operand2});
1159 printLocalVariableAddrRange(DefRangeRegister.
Range,
1161 printLocalVariableAddrGap(DefRangeRegister.
Gaps);
1164 if (
LVSymbol *Symbol = LocalSymbol) {
1165 Symbol->setHasCodeViewLocation();
1166 LocalSymbol =
nullptr;
1177 Symbol->addLocationOperands(
LVSmall(Attr), {Operand1});
1196 printLocalVariableAddrRange(DefRangeSubfieldRegister.
Range,
1198 printLocalVariableAddrGap(DefRangeSubfieldRegister.
Gaps);
1201 if (
LVSymbol *Symbol = LocalSymbol) {
1202 Symbol->setHasCodeViewLocation();
1203 LocalSymbol =
nullptr;
1215 Symbol->addLocationOperands(
LVSmall(Attr), {Operand1});
1231 auto ExpectedProgram = Strings.getString(DefRangeSubfield.
Program);
1232 if (!ExpectedProgram) {
1234 return llvm::make_error<CodeViewError>(
1235 "String table offset outside of bounds of String Table!");
1240 printLocalVariableAddrRange(DefRangeSubfield.
Range,
1242 printLocalVariableAddrGap(DefRangeSubfield.
Gaps);
1245 if (
LVSymbol *Symbol = LocalSymbol) {
1246 Symbol->setHasCodeViewLocation();
1247 LocalSymbol =
nullptr;
1258 Symbol->addLocationOperands(
LVSmall(Attr), {Operand1, 0});
1274 auto ExpectedProgram = Strings.getString(DefRange.
Program);
1275 if (!ExpectedProgram) {
1277 return llvm::make_error<CodeViewError>(
1278 "String table offset outside of bounds of String Table!");
1283 printLocalVariableAddrGap(DefRange.
Gaps);
1286 if (
LVSymbol *Symbol = LocalSymbol) {
1287 Symbol->setHasCodeViewLocation();
1288 LocalSymbol =
nullptr;
1299 Symbol->addLocationOperands(
LVSmall(Attr), {Operand1, 0});
1319 if (FrameProcedureOptions::MarkedInline ==
1320 (Flags & FrameProcedureOptions::MarkedInline))
1322 if (FrameProcedureOptions::Inlined ==
1323 (Flags & FrameProcedureOptions::Inlined))
1341 printTypeIndex(
"Type",
Data.Type);
1351 Symbol->setName(
Data.Name);
1361 Symbol->resetIncludeInPrint();
1368 if (Symbol->getParentScope()->removeElement(Symbol))
1373 if (
Record.kind() == SymbolKind::S_GDATA32)
1374 Symbol->setIsExternal();
1386 LVScope *AbstractFunction = Reader->createScopeFunction();
1387 AbstractFunction->setIsSubprogram();
1388 AbstractFunction->
setTag(dwarf::DW_TAG_subprogram);
1390 AbstractFunction->setIsInlinedAbstract();
1397 CVFunctionType,
InlineSite.Inlinee, AbstractFunction))
1404 InlinedFunction->setName(
Name);
1405 InlinedFunction->setLinkageName(
Name);
1409 AbstractFunction, InlinedFunction,
InlineSite))
1419 printTypeIndex(
"Type",
Local.Type);
1425 Symbol->setName(
Local.Name);
1428 Symbol->resetIsVariable();
1431 if (
bool(
Local.Flags & LocalSymFlags::IsCompilerGenerated) ||
1432 Local.Name ==
"this") {
1433 Symbol->setIsArtificial();
1434 Symbol->setIsParameter();
1436 bool(
Local.Flags & LocalSymFlags::IsParameter) ? Symbol->setIsParameter()
1437 : Symbol->setIsVariable();
1441 if (Symbol->getIsParameter())
1442 Symbol->setTag(dwarf::DW_TAG_formal_parameter);
1445 if (Element && Element->getIsScoped()) {
1447 LVScope *Parent = Symbol->getFunctionParent();
1454 Symbol->setType(Element);
1459 LocalSymbol = Symbol;
1472 CurrentObjectName = ObjName.
Name;
1478 if (InFunctionScope)
1479 return llvm::make_error<CodeViewError>(
"Visiting a ProcSym while inside "
1482 InFunctionScope =
true;
1538 if (
options().getGeneralCollectRanges()) {
1544 Function->addObject(LowPC, HighPC);
1547 if ((
options().getAttributePublics() ||
options().getPrintAnyLine()) &&
1572 std::optional<CVType> CVFunctionType;
1573 auto GetRecordType = [&]() ->
bool {
1574 CVFunctionType = Ids.
tryGetType(TIFunctionType);
1575 if (!CVFunctionType)
1580 if (CVFunctionType->kind() == LF_FUNC_ID)
1584 return (CVFunctionType->kind() == LF_MFUNC_ID);
1588 if (!GetRecordType()) {
1589 CVFunctionType = Types.
tryGetType(TIFunctionType);
1590 if (!CVFunctionType)
1591 return llvm::make_error<CodeViewError>(
"Invalid type index");
1595 *CVFunctionType, TIFunctionType,
Function))
1599 if (
Record.kind() == SymbolKind::S_GPROC32 ||
1600 Record.kind() == SymbolKind::S_GPROC32_ID)
1606 if (DemangledSymbol.find(
"scalar deleting dtor") != std::string::npos) {
1611 if (DemangledSymbol.find(
"dynamic atexit destructor for") !=
1623 InFunctionScope =
false;
1629 if (InFunctionScope)
1630 return llvm::make_error<CodeViewError>(
"Visiting a Thunk32Sym while inside "
1633 InFunctionScope =
true;
1649 printTypeIndex(
"Type",
UDT.Type);
1655 if (
Type->getParentScope()->removeElement(
Type))
1669 Type->resetIncludeInPrint();
1672 if (
UDT.Name == RecordName)
1673 Type->resetIncludeInPrint();
1692 W.
printHex(
"BaseOffset", JumpTable.BaseOffset);
1693 W.
printNumber(
"BaseSegment", JumpTable.BaseSegment);
1696 W.
printHex(
"BranchOffset", JumpTable.BranchOffset);
1697 W.
printHex(
"TableOffset", JumpTable.TableOffset);
1698 W.
printNumber(
"BranchSegment", JumpTable.BranchSegment);
1699 W.
printNumber(
"TableSegment", JumpTable.TableSegment);
1700 W.
printNumber(
"EntriesCount", JumpTable.EntriesCount);
1709 switch (
Caller.getKind()) {
1710 case SymbolRecordKind::CallerSym:
1711 FieldName =
"Callee";
1713 case SymbolRecordKind::CalleeSym:
1714 FieldName =
"Caller";
1716 case SymbolRecordKind::InlineesSym:
1717 FieldName =
"Inlinee";
1720 return llvm::make_error<CodeViewError>(
1721 "Unknown CV Record type for a CallerSym object!");
1724 printTypeIndex(FieldName, FuncID);
1731#define DEBUG_TYPE "CodeViewLogicalVisitor"
1738 : Reader(Reader), W(W), Input(Input) {
1741 Shared = std::make_shared<LVShared>(Reader,
this);
1747 StreamIdx ==
StreamTPI ? types() : ids());
1760 << Element->
getName() <<
"\n";
1779 << Element->
getName() <<
"\n";
1830 if (Element->getIsFinalized())
1832 Element->setIsFinalized();
1841 LVType *PrevSubrange =
nullptr;
1849 Subrange->setTag(dwarf::DW_TAG_subrange_type);
1859 if (int64_t Count =
Subrange->getCount())
1874 while (CVEntry.
kind() == LF_ARRAY) {
1885 AddSubrangeType(AR);
1886 TIArrayType = TIElementType;
1892 CVType CVElementType =
Types.getType(TIElementType);
1893 if (CVElementType.
kind() == LF_MODIFIER) {
1895 Shared->TypeRecords.find(
StreamTPI, TIElementType);
1908 CVEntry =
Types.getType(TIElementType);
1910 const_cast<CVType &
>(CVEntry), AR)) {
1920 TIArrayType = Shared->ForwardReferences.remap(TIArrayType);
1966 TypeIndex TIName = BI.
getArgs()[BuildInfoRecord::BuildInfoArg::SourceFile];
1987 if (
Class.hasUniqueName())
1992 if (Element->getIsFinalized())
1994 Element->setIsFinalized();
2000 Scope->setName(
Class.getName());
2001 if (
Class.hasUniqueName())
2002 Scope->setLinkageName(
Class.getUniqueName());
2004 if (
Class.isNested()) {
2005 Scope->setIsNested();
2006 createParents(
Class.getName(), Scope);
2009 if (
Class.isScoped())
2010 Scope->setIsScoped();
2014 if (!(
Class.isNested() ||
Class.isScoped())) {
2015 if (
LVScope *Namespace = Shared->NamespaceDeduction.get(
Class.getName()))
2024 TypeIndex ForwardType = Shared->ForwardReferences.find(
Class.getName());
2030 const_cast<CVType &
>(CVReference), ReferenceRecord))
2062 if (Scope->getIsFinalized())
2064 Scope->setIsFinalized();
2068 Scope->setName(
Enum.getName());
2069 if (
Enum.hasUniqueName())
2070 Scope->setLinkageName(
Enum.getUniqueName());
2074 if (
Enum.isNested()) {
2075 Scope->setIsNested();
2076 createParents(
Enum.getName(), Scope);
2079 if (
Enum.isScoped()) {
2080 Scope->setIsScoped();
2081 Scope->setIsEnumClass();
2085 if (!(
Enum.isNested() ||
Enum.isScoped())) {
2086 if (
LVScope *Namespace = Shared->NamespaceDeduction.get(
Enum.getName()))
2112 if (
Error Err = visitFieldListMemberStream(TI, Element,
FieldList.Data))
2138 TypeIndex TIParent = Func.getParentScope();
2139 if (FunctionDcl->getIsInlinedAbstract()) {
2140 FunctionDcl->setName(Func.getName());
2151 TypeIndex TIFunctionType = Func.getFunctionType();
2152 CVType CVFunctionType =
Types.getType(TIFunctionType);
2157 FunctionDcl->setIsFinalized();
2186 if (FunctionDcl->getIsInlinedAbstract()) {
2192 Shared->TypeRecords.find(
StreamTPI, Id.getClassType())))
2193 Class->addElement(FunctionDcl);
2196 TypeIndex TIFunctionType = Id.getFunctionType();
2222 MemberFunction->setIsFinalized();
2224 MemberFunction->setOffset(TI.
getIndex());
2225 MemberFunction->setOffsetFromTypeIndex();
2227 if (ProcessArgumentList) {
2228 ProcessArgumentList =
false;
2230 if (!MemberFunction->getIsStatic()) {
2235 createParameter(ThisPointer,
StringRef(), MemberFunction);
2236 This->setIsArtificial();
2263 Method.
Name = OverloadedMethodName;
2295 bool SeenModifier =
false;
2297 if (Mods &
uint16_t(ModifierOptions::Const)) {
2298 SeenModifier =
true;
2299 LastLink->
setTag(dwarf::DW_TAG_const_type);
2300 LastLink->setIsConst();
2303 if (Mods &
uint16_t(ModifierOptions::Volatile)) {
2311 LastLink->
setTag(dwarf::DW_TAG_volatile_type);
2312 LastLink->setIsVolatile();
2313 LastLink->
setName(
"volatile");
2315 if (Mods &
uint16_t(ModifierOptions::Unaligned)) {
2324 LastLink->setIsUnaligned();
2325 LastLink->
setName(
"unaligned");
2328 LastLink->
setType(ModifiedType);
2347 if (
Ptr.isPointerToMember()) {
2359 Pointee =
Ptr.isPointerToMember()
2360 ? Shared->TypeRecords.find(
StreamTPI,
Ptr.getReferentType())
2370 bool SeenModifier =
false;
2375 if (
Ptr.isRestrict()) {
2376 SeenModifier =
true;
2378 Restrict->setTag(dwarf::DW_TAG_restrict_type);
2385 if (Mode == PointerMode::LValueReference) {
2387 LVType *LReference = Reader->createType();
2388 LReference->setIsModifier();
2389 LastLink->
setType(LReference);
2390 LastLink = LReference;
2393 LastLink->
setTag(dwarf::DW_TAG_reference_type);
2394 LastLink->setIsReference();
2397 if (Mode == PointerMode::RValueReference) {
2399 LVType *RReference = Reader->createType();
2400 RReference->setIsModifier();
2401 LastLink->
setType(RReference);
2402 LastLink = RReference;
2405 LastLink->
setTag(dwarf::DW_TAG_rvalue_reference_type);
2406 LastLink->setIsRvalueReference();
2432 if (ProcessArgumentList) {
2433 ProcessArgumentList =
false;
2455 if (
Union.hasUniqueName())
2464 if (Scope->getIsFinalized())
2466 Scope->setIsFinalized();
2468 Scope->setName(
Union.getName());
2469 if (
Union.hasUniqueName())
2470 Scope->setLinkageName(
Union.getUniqueName());
2472 if (
Union.isNested()) {
2473 Scope->setIsNested();
2474 createParents(
Union.getName(), Scope);
2476 if (
LVScope *Namespace = Shared->NamespaceDeduction.get(
Union.getName()))
2482 if (!
Union.getFieldList().isNoneType()) {
2562 if (
LVScope *Namespace = Shared->NamespaceDeduction.get(
2563 String.getString(),
false)) {
2567 Scope->removeElement(Element);
2653 Symbol->setAccessibilityCode(
Base.getAccess());
2693 Enum.getValue().toString(
Value, 16,
true,
true);
2731 if (NestedType && NestedType->getIsNested()) {
2737 if (NestedTypeName.
size() && RecordName.
size()) {
2739 std::tie(OuterComponent, std::ignore) =
2743 if (OuterComponent.
size() && OuterComponent == RecordName) {
2744 if (!NestedType->getIsScopedAlready()) {
2745 Scope->addElement(NestedType);
2746 NestedType->setIsScopedAlready();
2749 Typedef->resetIncludeInPrint();
2775 ProcessArgumentList =
true;
2777 MemberFunction->setIsFinalized();
2780 MemberFunction->setName(Method.
getName());
2781 MemberFunction->setAccessibilityCode(Method.
getAccess());
2784 if (
Kind == MethodKind::Static)
2785 MemberFunction->setIsStatic();
2786 MemberFunction->setVirtualityCode(
Kind);
2789 if (MethodOptions::CompilerGenerated ==
2790 (Flags & MethodOptions::CompilerGenerated))
2791 MemberFunction->setIsArtificial();
2799 ProcessArgumentList =
false;
2819 OverloadedMethodName = Method.
getName();
2874 Symbol->setAccessibilityCode(
Base.getAccess());
2875 Symbol->setVirtualityCode(MethodKind::Virtual);
2893#define MEMBER_RECORD(EnumName, EnumVal, Name) \
2896 visitKnownMember<Name##Record>(Record, Callbacks, TI, Element)) \
2900#define MEMBER_RECORD_ALIAS(EnumName, EnumVal, Name, AliasName) \
2901 MEMBER_RECORD(EnumVal, EnumVal, AliasName)
2902#define TYPE_RECORD(EnumName, EnumVal, Name)
2903#define TYPE_RECORD_ALIAS(EnumName, EnumVal, Name, AliasName)
2904#include "llvm/DebugInfo/CodeView/CodeViewTypes.def"
2920#define TYPE_RECORD(EnumName, EnumVal, Name) \
2922 if (Error Err = visitKnownRecord<Name##Record>(Record, TI, Element)) \
2926#define TYPE_RECORD_ALIAS(EnumName, EnumVal, Name, AliasName) \
2927 TYPE_RECORD(EnumVal, EnumVal, AliasName)
2928#define MEMBER_RECORD(EnumName, EnumVal, Name)
2929#define MEMBER_RECORD_ALIAS(EnumName, EnumVal, Name, AliasName)
2930#include "llvm/DebugInfo/CodeView/CodeViewTypes.def"
2937Error LVLogicalVisitor::visitFieldListMemberStream(
2946 while (!Reader.empty()) {
2947 if (
Error Err = Reader.readEnum(Leaf))
2965 if (!ScopeStack.empty())
2967 InCompileUnitScope =
true;
2991 if (
options().getAttributeBase())
2998 case TypeLeafKind::LF_ENUMERATE:
3002 case TypeLeafKind::LF_MODIFIER:
3006 case TypeLeafKind::LF_POINTER:
3014 case TypeLeafKind::LF_BCLASS:
3015 case TypeLeafKind::LF_IVBCLASS:
3016 case TypeLeafKind::LF_VBCLASS:
3021 case TypeLeafKind::LF_MEMBER:
3022 case TypeLeafKind::LF_STMEMBER:
3029 case TypeLeafKind::LF_ARRAY:
3033 case TypeLeafKind::LF_CLASS:
3038 case TypeLeafKind::LF_ENUM:
3042 case TypeLeafKind::LF_METHOD:
3043 case TypeLeafKind::LF_ONEMETHOD:
3044 case TypeLeafKind::LF_PROCEDURE:
3049 case TypeLeafKind::LF_STRUCTURE:
3054 case TypeLeafKind::LF_UNION:
3073 case SymbolKind::S_UDT:
3079 case SymbolKind::S_CONSTANT:
3085 case SymbolKind::S_BPREL32:
3086 case SymbolKind::S_REGREL32:
3087 case SymbolKind::S_GDATA32:
3088 case SymbolKind::S_LDATA32:
3089 case SymbolKind::S_LOCAL:
3099 case SymbolKind::S_BLOCK32:
3104 case SymbolKind::S_COMPILE2:
3105 case SymbolKind::S_COMPILE3:
3110 case SymbolKind::S_INLINESITE:
3111 case SymbolKind::S_INLINESITE2:
3116 case SymbolKind::S_LPROC32:
3117 case SymbolKind::S_GPROC32:
3118 case SymbolKind::S_LPROC32_ID:
3119 case SymbolKind::S_GPROC32_ID:
3120 case SymbolKind::S_SEPCODE:
3121 case SymbolKind::S_THUNK32:
3141 Element->setIsFinalized();
3151 Element->setOffsetFromTypeIndex();
3162 Element->setOffsetFromTypeIndex();
3176 Symbol->setName(
Name);
3182 if (CVMemberType.
kind() == LF_BITFIELD) {
3190 Symbol->setAccessibilityCode(Access);
3197 LVSymbol *Parameter = Reader->createSymbol();
3199 Parameter->setIsParameter();
3200 Parameter->
setTag(dwarf::DW_TAG_formal_parameter);
3220 return static_cast<LVType *
>(Element);
3236 return static_cast<LVType *
>(Element);
3267 if (Components.size() < 2)
3269 Components.pop_back();
3271 LVStringRefs::size_type FirstNamespace;
3272 LVStringRefs::size_type FirstAggregate;
3273 std::tie(FirstNamespace, FirstAggregate) =
3274 Shared->NamespaceDeduction.find(Components);
3277 W.
printString(
"First Namespace", Components[FirstNamespace]);
3278 W.
printString(
"First NonNamespace", Components[FirstAggregate]);
3282 if (FirstNamespace < FirstAggregate) {
3283 Shared->NamespaceDeduction.get(
3285 Components.begin() + FirstAggregate));
3294 LVStringRefs(Components.begin(), Components.begin() + FirstAggregate));
3297 for (LVStringRefs::size_type
Index = FirstAggregate;
3300 Components.begin() +
Index + 1),
3302 TIAggregate = Shared->ForwardReferences.remap(
3303 Shared->TypeRecords.find(
StreamTPI, AggregateName));
3313 if (Aggregate && !Element->getIsScopedAlready()) {
3315 Element->setIsScopedAlready();
3322 TI = Shared->ForwardReferences.remap(TI);
3325 LVElement *Element = Shared->TypeRecords.find(StreamIdx, TI);
3333 return (TypeName.back() ==
'*') ? createPointerType(TI, TypeName)
3334 : createBaseType(TI, TypeName);
3342 if (Element->getIsFinalized())
3356 Element->setIsFinalized();
3363 for (
const TypeIndex &Entry : Shared->LineRecords) {
3379 if (
LVElement *Element = Shared->TypeRecords.find(
3383 Shared->StringRecords.findIndex(
Line.getSourceFile()));
3391 Shared->NamespaceDeduction.init();
3397 if (!
options().getInternalTag())
3402 auto NewLine = [&]() {
3415 Shared->TypeKinds.clear();
3418 OS <<
"\nSymbols:\n";
3421 Shared->SymbolKinds.clear();
3435 ParentLowPC = (*
Locations->begin())->getLowerAddress();
3442 LVInlineeInfo::iterator Iter = InlineeInfo.find(
InlineSite.Inlinee);
3443 if (Iter != InlineeInfo.end()) {
3444 LineNumber = Iter->second.first;
3453 dbgs() <<
"inlineSiteAnnotation\n"
3454 <<
"Abstract: " << AbstractFunction->
getName() <<
"\n"
3455 <<
"Inlined: " << InlinedFunction->
getName() <<
"\n"
3456 <<
"Parent: " << Parent->
getName() <<
"\n"
3457 <<
"Low PC: " <<
hexValue(ParentLowPC) <<
"\n";
3461 if (!
options().getPrintLines())
3468 int32_t LineOffset = LineNumber;
3472 auto UpdateCodeOffset = [&](
uint32_t Delta) {
3479 auto UpdateLineOffset = [&](int32_t Delta) {
3480 LineOffset += Delta;
3482 char Sign = Delta > 0 ?
'+' :
'-';
3483 dbgs() <<
formatv(
" line {0} ({1}{2})", LineOffset, Sign,
3487 auto UpdateFileOffset = [&](int32_t
Offset) {
3493 auto CreateLine = [&]() {
3497 Line->setLineNumber(LineOffset);
3504 bool SeenLowAddress =
false;
3505 bool SeenHighAddress =
false;
3509 for (
auto &Annot :
InlineSite.annotations()) {
3516 switch (Annot.OpCode) {
3517 case BinaryAnnotationsOpCode::ChangeCodeOffset:
3518 case BinaryAnnotationsOpCode::CodeOffset:
3519 case BinaryAnnotationsOpCode::ChangeCodeLength:
3520 UpdateCodeOffset(Annot.U1);
3522 if (Annot.OpCode == BinaryAnnotationsOpCode::ChangeCodeOffset) {
3525 SeenLowAddress =
true;
3528 if (Annot.OpCode == BinaryAnnotationsOpCode::ChangeCodeLength) {
3530 SeenHighAddress =
true;
3533 case BinaryAnnotationsOpCode::ChangeCodeLengthAndCodeOffset:
3534 UpdateCodeOffset(Annot.U2);
3537 case BinaryAnnotationsOpCode::ChangeLineOffset:
3538 case BinaryAnnotationsOpCode::ChangeCodeOffsetAndLineOffset:
3539 UpdateCodeOffset(Annot.U1);
3540 UpdateLineOffset(Annot.S1);
3543 BinaryAnnotationsOpCode::ChangeCodeOffsetAndLineOffset)
3546 case BinaryAnnotationsOpCode::ChangeFile:
3547 UpdateFileOffset(Annot.U1);
3553 if (SeenLowAddress && SeenHighAddress) {
3554 SeenLowAddress =
false;
3555 SeenHighAddress =
false;
3556 InlinedFunction->
addObject(LowPC, HighPC);
for(const MachineOperand &MO :llvm::drop_begin(OldMI.operands(), Desc.getNumOperands()))
AMDGPU Lower Kernel Arguments
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
ArrayRef - Represent a constant reference to an array (0 or more elements consecutively in memory),...
size_t size() const
size - Get the array size.
An implementation of BinaryStream which holds its entire data set in a single contiguous buffer.
Provides read only access to a subclass of BinaryStream.
This is an important base class in LLVM.
Lightweight error class with error context and mandatory checking.
static ErrorSuccess success()
Create a success value.
Tagged union holding either a T or a Error.
StringRef getName() const
virtual void printString(StringRef Value)
void indent(int Levels=1)
void unindent(int Levels=1)
void printEnum(StringRef Label, T Value, ArrayRef< EnumEntry< TEnum > > EnumValues)
virtual raw_ostream & getOStream()
virtual raw_ostream & startLine()
virtual void printNumber(StringRef Label, char Value)
void printHex(StringRef Label, T Value)
void printFlags(StringRef Label, T Value, ArrayRef< EnumEntry< TFlag > > Flags, TFlag EnumMask1={}, TFlag EnumMask2={}, TFlag EnumMask3={}, ArrayRef< FlagEntry > ExtraFlags={})
virtual void printBoolean(StringRef Label, bool Value)
SmallString - A SmallString is just a SmallVector with methods and accessors that make it work better...
This is a 'vector' (really, a variable-sized array), optimized for the case when the array is small.
StringMapEntry - This is used to represent one value that is inserted into a StringMap.
StringRef - Represent a constant reference to a string, i.e.
std::string str() const
str - Get the contents as an std::string.
constexpr size_t size() const
size - Get the string size.
Target - Wrapper for Target specific information.
The instances of the Type class are immutable: once they are created, they are never changed.
LLVM Value Representation.
Value(Type *Ty, unsigned scid)
void setName(const Twine &Name)
Change the name of the value.
TypeIndex getElementType() const
TypeIndex getIndexType() const
StringRef getName() const
uint8_t getBitSize() const
TypeIndex getType() const
uint8_t getBitOffset() const
ArrayRef< TypeIndex > getArgs() const
uint8_t getLanguage() const
uint32_t getFlags() const
CompileSym3Flags getFlags() const
SourceLanguage getLanguage() const
Represents a read-only view of a CodeView string table.
DefRangeFramePointerRelHeader Hdr
LocalVariableAddrRange Range
uint32_t getRelocationOffset() const
std::vector< LocalVariableAddrGap > Gaps
DefRangeRegisterRelHeader Hdr
bool hasSpilledUDTMember() const
uint32_t getRelocationOffset() const
uint16_t offsetInParent() const
std::vector< LocalVariableAddrGap > Gaps
LocalVariableAddrRange Range
uint32_t getRelocationOffset() const
std::vector< LocalVariableAddrGap > Gaps
LocalVariableAddrRange Range
DefRangeRegisterHeader Hdr
LocalVariableAddrRange Range
uint32_t getRelocationOffset() const
std::vector< LocalVariableAddrGap > Gaps
DefRangeSubfieldRegisterHeader Hdr
std::vector< LocalVariableAddrGap > Gaps
LocalVariableAddrRange Range
uint32_t getRelocationOffset() const
std::vector< LocalVariableAddrGap > Gaps
uint32_t getRelocationOffset() const
LocalVariableAddrRange Range
uint32_t getSignature() const
RegisterId getLocalFramePtrReg(CPUType CPU) const
Extract the register this frame uses to refer to local variables.
RegisterId getParamFramePtrReg(CPUType CPU) const
Extract the register this frame uses to refer to parameters.
FrameProcedureOptions Flags
Provides amortized O(1) random access to a CodeView type stream.
std::optional< CVType > tryGetType(TypeIndex Index)
CVType getType(TypeIndex Index) override
StringRef getTypeName(TypeIndex Index) override
LF_INDEX - Used to chain two large LF_FIELDLIST or LF_METHODLIST records together.
TypeIndex getContinuationIndex() const
TypeIndex getReturnType() const
int32_t getThisPointerAdjustment() const
TypeIndex getArgumentList() const
uint16_t getParameterCount() const
TypeIndex getThisType() const
TypeIndex getClassType() const
std::vector< OneMethodRecord > Methods
int32_t getVFTableOffset() const
TypeIndex getType() const
bool isIntroducingVirtual() const
MemberAccess getAccess() const
MethodKind getMethodKind() const
StringRef getName() const
For method overload sets. LF_METHOD.
StringRef getName() const
uint16_t getNumOverloads() const
TypeIndex getMethodList() const
uint32_t getSignature() const
StringRef getPrecompFilePath() const
uint32_t getTypesCount() const
uint32_t getStartTypeIndex() const
uint32_t getRelocationOffset() const
TypeIndex getReturnType() const
TypeIndex getArgumentList() const
uint16_t getParameterCount() const
TypeIndex getFieldList() const
static Error deserializeAs(CVType &CVT, T &Record)
static TypeIndex fromArrayIndex(uint32_t Index)
SimpleTypeKind getSimpleKind() const
void setIndex(uint32_t I)
static const uint32_t FirstNonSimpleIndex
static StringRef simpleTypeName(TypeIndex TI)
uint32_t getIndex() const
StringRef getName() const
const GUID & getGuid() const
void addCallbackToPipeline(TypeVisitorCallbacks &Callbacks)
virtual Error visitUnknownMember(CVMemberRecord &Record)
virtual Error visitMemberEnd(CVMemberRecord &Record)
virtual Error visitMemberBegin(CVMemberRecord &Record)
TypeIndex getSourceFile() const
uint16_t getModule() const
uint32_t getLineNumber() const
uint32_t getLineNumber() const
TypeIndex getSourceFile() const
TypeIndex getType() const
uint32_t getVFPtrOffset() const
TypeIndex getOverriddenVTable() const
ArrayRef< StringRef > getMethodNames() const
StringRef getName() const
TypeIndex getCompleteClass() const
uint32_t getEntryCount() const
Stores all information relating to a compile unit, be it in its original instance in the object file ...
void addInlineeLines(LVScope *Scope, LVLines &Lines)
LVAddress getSymbolTableAddress(StringRef Name)
LVAddress linearAddress(uint16_t Segment, uint32_t Offset, LVAddress Addendum=0)
void addToSymbolTable(StringRef Name, LVScope *Function, LVSectionIndex SectionIndex=0)
void addModule(LVScope *Scope)
void getLinkageName(const llvm::object::coff_section *CoffSection, uint32_t RelocOffset, uint32_t Offset, StringRef *RelocSym)
static StringRef getSymbolKindName(SymbolKind Kind)
virtual void setCount(int64_t Value)
virtual void setBitSize(uint32_t Size)
virtual void updateLevel(LVScope *Parent, bool Moved=false)
virtual int64_t getCount() const
void setInlineCode(uint32_t Code)
virtual void setReference(LVElement *Element)
void setName(StringRef ElementName) override
StringRef getName() const override
void setType(LVElement *Element=nullptr)
void setFilenameIndex(size_t Index)
Error visitKnownRecord(CVType &Record, ArgListRecord &Args, TypeIndex TI, LVElement *Element)
void printRecords(raw_ostream &OS) const
void stopProcessArgumentList()
void printTypeEnd(CVType &Record)
Error visitMemberRecord(CVMemberRecord &Record, TypeVisitorCallbacks &Callbacks, TypeIndex TI, LVElement *Element)
Error visitKnownMember(CVMemberRecord &Record, BaseClassRecord &Base, TypeIndex TI, LVElement *Element)
void printMemberEnd(CVMemberRecord &Record)
void setCompileUnitName(std::string Name)
LVElement * CurrentElement
Error inlineSiteAnnotation(LVScope *AbstractFunction, LVScope *InlinedFunction, InlineSiteSym &InlineSite)
LVLogicalVisitor(LVCodeViewReader *Reader, ScopedPrinter &W, llvm::pdb::InputFile &Input)
void printTypeIndex(StringRef FieldName, TypeIndex TI, uint32_t StreamIdx)
Error visitUnknownMember(CVMemberRecord &Record, TypeIndex TI)
void pushScope(LVScope *Scope)
Error visitUnknownType(CVType &Record, TypeIndex TI)
void startProcessArgumentList()
void addElement(LVScope *Scope, bool IsCompileUnit)
void printTypeBegin(CVType &Record, TypeIndex TI, LVElement *Element, uint32_t StreamIdx)
LVElement * getElement(uint32_t StreamIdx, TypeIndex TI, LVScope *Parent=nullptr)
LVScope * getReaderScope() const
void printMemberBegin(CVMemberRecord &Record, TypeIndex TI, LVElement *Element, uint32_t StreamIdx)
Error finishVisitation(CVType &Record, TypeIndex TI, LVElement *Element)
LVElement * createElement(TypeLeafKind Kind)
LVScope * getParentScope() const
void setOffset(LVOffset DieOffset)
LVOffset getOffset() const
void setLineNumber(uint32_t Number)
void setTag(dwarf::Tag Tag)
codeview::CPUType getCompileUnitCPUType()
void setCompileUnitCPUType(codeview::CPUType Type)
virtual bool isSystemEntry(LVElement *Element, StringRef Name={}) const
LVScopeCompileUnit * getCompileUnit() const
void setCompileUnit(LVScope *Scope)
void addPublicName(LVScope *Scope, LVAddress LowPC, LVAddress HighPC)
void addElement(LVElement *Element)
void addObject(LVLocation *Location)
const LVLocations * getRanges() const
void getLinkageName(uint32_t RelocOffset, uint32_t Offset, StringRef *RelocSym=nullptr)
void printRelocatedField(StringRef Label, uint32_t RelocOffset, uint32_t Offset, StringRef *RelocSym=nullptr)
DebugStringTableSubsectionRef getStringTable() override
StringRef getFileNameForFileOffset(uint32_t FileOffset) override
Error visitSymbolEnd(CVSymbol &Record) override
Error visitKnownRecord(CVSymbol &Record, BlockSym &Block) override
Error visitSymbolBegin(CVSymbol &Record) override
Error visitUnknownSymbol(CVSymbol &Record) override
Action to take on unknown symbols. By default, they are ignored.
Error visitMemberEnd(CVMemberRecord &Record) override
Error visitUnknownMember(CVMemberRecord &Record) override
Error visitTypeBegin(CVType &Record) override
Paired begin/end actions for all types.
Error visitMemberBegin(CVMemberRecord &Record) override
Error visitKnownRecord(CVType &Record, BuildInfoRecord &Args) override
Error visitUnknownType(CVType &Record) override
Action to take on unknown types. By default, they are ignored.
This class implements an extremely fast bulk output stream that can only output to a stream.
constexpr char TypeName[]
Key for Kernel::Arg::Metadata::mTypeName.
PointerMode
Equivalent to CV_ptrmode_e.
MethodKind
Part of member attribute flags. (CV_methodprop_e)
CPUType
These values correspond to the CV_CPU_TYPE_e enumeration, and are documented here: https://msdn....
ArrayRef< EnumEntry< uint16_t > > getJumpTableEntrySizeNames()
bool symbolEndsScope(SymbolKind Kind)
Return true if this ssymbol ends a scope.
MethodOptions
Equivalent to CV_fldattr_t bitfield.
ArrayRef< EnumEntry< SymbolKind > > getSymbolTypeNames()
MemberAccess
Source-level access specifier. (CV_access_e)
bool symbolOpensScope(SymbolKind Kind)
Return true if this symbol opens a scope.
TypeLeafKind
Duplicate copy of the above enum, but using the official CV names.
ArrayRef< EnumEntry< uint16_t > > getLocalFlagNames()
ArrayRef< EnumEntry< uint16_t > > getRegisterNames(CPUType Cpu)
bool isAggregate(CVType CVT)
Given an arbitrary codeview type, determine if it is an LF_STRUCTURE, LF_CLASS, LF_INTERFACE,...
ArrayRef< EnumEntry< uint8_t > > getProcSymFlagNames()
TypeRecordKind
Distinguishes individual records in .debug$T or .debug$P section or PDB type stream.
SymbolKind
Duplicate copy of the above enum, but using the official CV names.
uint64_t getSizeInBytesForTypeRecord(CVType CVT)
Given an arbitrary codeview type, return the type's size in the case of aggregate (LF_STRUCTURE,...
ArrayRef< EnumEntry< unsigned > > getCPUTypeNames()
ArrayRef< EnumEntry< SourceLanguage > > getSourceLanguageNames()
uint64_t getSizeInBytesForTypeIndex(TypeIndex TI)
Given an arbitrary codeview type index, determine its size.
TypeIndex getModifiedType(const CVType &CVT)
Given a CVType which is assumed to be an LF_MODIFIER, return the TypeIndex of the type that the LF_MO...
ArrayRef< EnumEntry< uint32_t > > getCompileSym3FlagNames()
void printTypeIndex(ScopedPrinter &Printer, StringRef FieldName, TypeIndex TI, TypeCollection &Types)
@ DW_INL_declared_inlined
constexpr Tag DW_TAG_unaligned
Scope
Defines the scope in which this symbol should be visible: Default – Visible in the public interface o...
FormattedNumber hexValue(uint64_t N, unsigned Width=HEX_WIDTH, bool Upper=false)
static TypeIndex getTrueType(TypeIndex &TI)
std::vector< StringRef > LVStringRefs
static StringRef getRecordName(LazyRandomTypeCollection &Types, TypeIndex TI)
std::vector< TypeIndex > LVLineRecords
LVStringRefs getAllLexicalComponents(StringRef Name)
std::string transformPath(StringRef Path)
LVLexicalComponent getInnerComponent(StringRef Name)
static const EnumEntry< TypeLeafKind > LeafTypeNames[]
std::set< SymbolKind > LVSymbolKinds
std::set< TypeLeafKind > LVTypeKinds
std::string getScopedName(const LVStringRefs &Components, StringRef BaseName={})
std::tuple< LVStringRefs::size_type, LVStringRefs::size_type > LVLexicalIndex
std::string formatTypeLeafKind(codeview::TypeLeafKind K)
Print(const T &, const DataFlowGraph &) -> Print< T >
This is an optimization pass for GlobalISel generic memory operations.
auto find(R &&Range, const T &Val)
Provide wrappers to std::find which take ranges instead of having to pass begin/end explicitly.
std::tuple< uint64_t, uint32_t > InlineSite
auto formatv(const char *Fmt, Ts &&...Vals) -> formatv_object< decltype(std::make_tuple(support::detail::build_format_adapter(std::forward< Ts >(Vals))...))>
decltype(auto) get(const PointerIntPair< PointerTy, IntBits, IntType, PtrTraits, Info > &Pair)
raw_ostream & dbgs()
dbgs() - This returns a reference to a raw_ostream for debugging messages.
format_object< Ts... > format(const char *Fmt, const Ts &... Vals)
These are helper functions used to produce formatted output.
StringRef getTypeName()
We provide a function which tries to compute the (demangled) name of a type statically.
@ Mod
The access may modify the value stored in memory.
support::detail::RepeatAdapter< T > fmt_repeat(T &&Item, size_t Count)
support::detail::AlignAdapter< T > fmt_align(T &&Item, AlignStyle Where, size_t Amount, char Fill=' ')
void erase_if(Container &C, UnaryPredicate P)
Provide a container algorithm similar to C++ Library Fundamentals v2's erase_if which is equivalent t...
void consumeError(Error Err)
Consume a Error without doing anything.
std::string demangle(std::string_view MangledName)
Attempt to demangle a string using different demangling schemes.
MethodOptions getFlags() const
Get the flags that are not included in access control or method properties.
LVShared(LVCodeViewReader *Reader, LVLogicalVisitor *Visitor)
LVLineRecords LineRecords
LVTypeRecords TypeRecords
LVCodeViewReader * Reader
LVLogicalVisitor * Visitor
LVNamespaceDeduction NamespaceDeduction
LVSymbolKinds SymbolKinds
LVStringRecords StringRecords
LVForwardReferences ForwardReferences