]> granicus.if.org Git - llvm/commitdiff
[PDB] It is not an error getting the "Invalid" Annotation opcode.
authorZachary Turner <zturner@google.com>
Fri, 17 Mar 2017 00:15:27 +0000 (00:15 +0000)
committerZachary Turner <zturner@google.com>
Fri, 17 Mar 2017 00:15:27 +0000 (00:15 +0000)
The linker can insert invalid opcodes to indicate padding
bytes, and we should not fail in this case.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@298016 91177308-0d34-0410-b5e6-96231b3b80d8

lib/DebugInfo/CodeView/SymbolDumper.cpp

index fd54fba13c763627c518de5f4758a706f2ee2065..134471e81cacd0a275a16752e89a9d10558d9032 100644 (file)
@@ -468,8 +468,8 @@ Error CVSymbolDumperImpl::visitKnownRecord(CVSymbol &CVR,
   for (auto &Annotation : InlineSite.annotations()) {
     switch (Annotation.OpCode) {
     case BinaryAnnotationsOpCode::Invalid:
-      return llvm::make_error<CodeViewError>(
-          "Invalid binary annotation opcode!");
+      W.printString("(Annotation Padding)");
+      break;
     case BinaryAnnotationsOpCode::CodeOffset:
     case BinaryAnnotationsOpCode::ChangeCodeOffset:
     case BinaryAnnotationsOpCode::ChangeCodeLength: