summaryrefslogtreecommitdiffstats
path: root/contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp')
-rw-r--r--contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp66
1 files changed, 47 insertions, 19 deletions
diff --git a/contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp b/contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp
index 0e20bcb..4cfb55a 100644
--- a/contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp
+++ b/contrib/llvm/lib/DebugInfo/CodeView/EnumTables.cpp
@@ -1,4 +1,4 @@
-//===- EnumTables.cpp - Enum to string conversion tables --------*- C++ -*-===//
+//===- EnumTables.cpp - Enum to string conversion tables ------------------===//
//
// The LLVM Compiler Infrastructure
//
@@ -8,6 +8,8 @@
//===----------------------------------------------------------------------===//
#include "llvm/DebugInfo/CodeView/EnumTables.h"
+#include "llvm/Support/ScopedPrinter.h"
+#include <type_traits>
using namespace llvm;
using namespace codeview;
@@ -20,13 +22,13 @@ using namespace codeview;
static const EnumEntry<SymbolKind> SymbolTypeNames[] = {
#define CV_SYMBOL(enum, val) {#enum, enum},
-#include "llvm/DebugInfo/CodeView/CVSymbolTypes.def"
+#include "llvm/DebugInfo/CodeView/CodeViewSymbols.def"
#undef CV_SYMBOL
};
static const EnumEntry<TypeLeafKind> TypeLeafNames[] = {
#define CV_TYPE(name, val) {#name, name},
-#include "llvm/DebugInfo/CodeView/TypeRecords.def"
+#include "llvm/DebugInfo/CodeView/CodeViewTypes.def"
#undef CV_TYPE
};
@@ -82,6 +84,13 @@ static const EnumEntry<uint16_t> RegisterNames[] = {
CV_ENUM_CLASS_ENT(RegisterId, R15),
};
+static const EnumEntry<uint32_t> PublicSymFlagNames[] = {
+ CV_ENUM_CLASS_ENT(PublicSymFlags, Code),
+ CV_ENUM_CLASS_ENT(PublicSymFlags, Function),
+ CV_ENUM_CLASS_ENT(PublicSymFlags, Managed),
+ CV_ENUM_CLASS_ENT(PublicSymFlags, MSIL),
+};
+
static const EnumEntry<uint8_t> ProcSymFlagNames[] = {
CV_ENUM_CLASS_ENT(ProcSymFlags, HasFP),
CV_ENUM_CLASS_ENT(ProcSymFlags, HasIRET),
@@ -245,20 +254,20 @@ static const EnumEntry<uint32_t> FrameProcSymFlagNames[] = {
};
static const EnumEntry<uint32_t> ModuleSubstreamKindNames[] = {
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, None),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, Symbols),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, Lines),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, StringTable),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, FileChecksums),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, FrameData),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, InlineeLines),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, CrossScopeImports),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, CrossScopeExports),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, ILLines),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, FuncMDTokenMap),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, TypeMDTokenMap),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, MergedAssemblyInput),
- CV_ENUM_CLASS_ENT(ModuleSubstreamKind, CoffSymbolRVA),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, None),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, Symbols),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, Lines),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, StringTable),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, FileChecksums),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, FrameData),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, InlineeLines),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, CrossScopeImports),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, CrossScopeExports),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, ILLines),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, FuncMDTokenMap),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, TypeMDTokenMap),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, MergedAssemblyInput),
+ CV_ENUM_CLASS_ENT(DebugSubsectionKind, CoffSymbolRVA),
};
static const EnumEntry<uint16_t> ExportSymFlagNames[] = {
@@ -326,6 +335,7 @@ static const EnumEntry<COFF::SectionCharacteristics>
namespace llvm {
namespace codeview {
+
ArrayRef<EnumEntry<SymbolKind>> getSymbolTypeNames() {
return makeArrayRef(SymbolTypeNames);
}
@@ -338,48 +348,66 @@ ArrayRef<EnumEntry<uint16_t>> getRegisterNames() {
return makeArrayRef(RegisterNames);
}
+ArrayRef<EnumEntry<uint32_t>> getPublicSymFlagNames() {
+ return makeArrayRef(PublicSymFlagNames);
+}
+
ArrayRef<EnumEntry<uint8_t>> getProcSymFlagNames() {
return makeArrayRef(ProcSymFlagNames);
}
+
ArrayRef<EnumEntry<uint16_t>> getLocalFlagNames() {
return makeArrayRef(LocalFlags);
}
+
ArrayRef<EnumEntry<uint8_t>> getFrameCookieKindNames() {
return makeArrayRef(FrameCookieKinds);
}
+
ArrayRef<EnumEntry<SourceLanguage>> getSourceLanguageNames() {
return makeArrayRef(SourceLanguages);
}
+
ArrayRef<EnumEntry<uint32_t>> getCompileSym2FlagNames() {
return makeArrayRef(CompileSym2FlagNames);
}
+
ArrayRef<EnumEntry<uint32_t>> getCompileSym3FlagNames() {
return makeArrayRef(CompileSym3FlagNames);
}
+
ArrayRef<EnumEntry<uint32_t>> getFileChecksumNames() {
return makeArrayRef(FileChecksumNames);
}
+
ArrayRef<EnumEntry<unsigned>> getCPUTypeNames() {
return makeArrayRef(CPUTypeNames);
}
+
ArrayRef<EnumEntry<uint32_t>> getFrameProcSymFlagNames() {
return makeArrayRef(FrameProcSymFlagNames);
}
+
ArrayRef<EnumEntry<uint16_t>> getExportSymFlagNames() {
return makeArrayRef(ExportSymFlagNames);
}
+
ArrayRef<EnumEntry<uint32_t>> getModuleSubstreamKindNames() {
return makeArrayRef(ModuleSubstreamKindNames);
}
+
ArrayRef<EnumEntry<uint8_t>> getThunkOrdinalNames() {
return makeArrayRef(ThunkOrdinalNames);
}
+
ArrayRef<EnumEntry<uint16_t>> getTrampolineNames() {
return makeArrayRef(TrampolineNames);
}
+
ArrayRef<EnumEntry<COFF::SectionCharacteristics>>
getImageSectionCharacteristicNames() {
return makeArrayRef(ImageSectionCharacteristicNames);
}
-}
-}
+
+} // end namespace codeview
+} // end namespace llvm
OpenPOWER on IntegriCloud