diff options
author | Reid Kleckner <rnk@google.com> | 2017-07-24 16:16:17 +0000 |
---|---|---|
committer | Reid Kleckner <rnk@google.com> | 2017-07-24 16:16:17 +0000 |
commit | 7f6b2534fb2d4dedb2d948686a6031d4739c3576 (patch) | |
tree | c760dbfe93fe2ee8775d6d27059f076ad7bb3084 | |
parent | 103aedd2856d500c8e28a1f0bc9e898093abac8b (diff) | |
download | bcm5719-llvm-7f6b2534fb2d4dedb2d948686a6031d4739c3576.tar.gz bcm5719-llvm-7f6b2534fb2d4dedb2d948686a6031d4739c3576.zip |
Format some case labels and shrink an anonymous namespace NFC
llvm-svn: 308889
-rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp | 27 |
1 files changed, 12 insertions, 15 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp b/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp index b5370e53f29..ec0f007371d 100644 --- a/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp @@ -545,8 +545,6 @@ void CodeViewDebug::emitTypeInformation() { } } -namespace { - static SourceLanguage MapDWLangToCVLang(unsigned DWLang) { switch (DWLang) { case dwarf::DW_LANG_C: @@ -580,9 +578,11 @@ static SourceLanguage MapDWLangToCVLang(unsigned DWLang) { } } +namespace { struct Version { int Part[4]; }; +} // end anonymous namespace // Takes a StringRef like "clang 4.0.0.0 (other nonsense 123)" and parses out // the version number. @@ -605,22 +605,19 @@ static Version parseVersion(StringRef Name) { static CPUType mapArchToCVCPUType(Triple::ArchType Type) { switch (Type) { - case Triple::ArchType::x86: - return CPUType::Pentium3; - case Triple::ArchType::x86_64: - return CPUType::X64; - case Triple::ArchType::thumb: - return CPUType::Thumb; - case Triple::ArchType::aarch64: - return CPUType::ARM64; - default: - report_fatal_error("target architecture doesn't map to a CodeView " - "CPUType"); + case Triple::ArchType::x86: + return CPUType::Pentium3; + case Triple::ArchType::x86_64: + return CPUType::X64; + case Triple::ArchType::thumb: + return CPUType::Thumb; + case Triple::ArchType::aarch64: + return CPUType::ARM64; + default: + report_fatal_error("target architecture doesn't map to a CodeView CPUType"); } } -} // end anonymous namespace - void CodeViewDebug::emitCompilerInformation() { MCContext &Context = MMI->getContext(); MCSymbol *CompilerBegin = Context.createTempSymbol(), |