summaryrefslogtreecommitdiffstats
path: root/llvm/lib/DebugInfo/CodeView
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2017-08-17 20:04:51 +0000
committerZachary Turner <zturner@google.com>2017-08-17 20:04:51 +0000
commit96bcd6a37ac477ad776279a0e6fdd820545256da (patch)
treef46567d39fe9803ddb0a9cd1ce441e59eb00e5d1 /llvm/lib/DebugInfo/CodeView
parentf401e1102d573b36f788f1c7d13972d6ceb5ff89 (diff)
downloadbcm5719-llvm-96bcd6a37ac477ad776279a0e6fdd820545256da.tar.gz
bcm5719-llvm-96bcd6a37ac477ad776279a0e6fdd820545256da.zip
[llvm-pdbutil] Fix some dumping issues.
When dumping, we were treating the S_INLINESITESYM as referring to a type record, when it actually refers to an id record. We had this correct in TypeIndexDiscovery, so our merging algorithm should be fine, but we had it wrong in the dumper, which means it would appear to work most of the time, unless the index was out of bounds in the type stream, when it would fail. Fixed this, and audited a few other cases to make them match the behavior in TypeIndexDiscovery. Also, I've now observed a new symbol record with kind 0x1168 which I have no clue what it is, so to avoid crashing we have to just print "Unknown Symbol Kind". llvm-svn: 311117
Diffstat (limited to 'llvm/lib/DebugInfo/CodeView')
-rw-r--r--llvm/lib/DebugInfo/CodeView/LazyRandomTypeCollection.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/llvm/lib/DebugInfo/CodeView/LazyRandomTypeCollection.cpp b/llvm/lib/DebugInfo/CodeView/LazyRandomTypeCollection.cpp
index 6db921ed939..7133109ea84 100644
--- a/llvm/lib/DebugInfo/CodeView/LazyRandomTypeCollection.cpp
+++ b/llvm/lib/DebugInfo/CodeView/LazyRandomTypeCollection.cpp
@@ -83,7 +83,9 @@ uint32_t LazyRandomTypeCollection::getOffsetOfType(TypeIndex Index) {
}
CVType LazyRandomTypeCollection::getType(TypeIndex Index) {
- error(ensureTypeExists(Index));
+ uint32_t I = Index.getIndex();
+ auto EC = ensureTypeExists(Index);
+ error(std::move(EC));
assert(contains(Index));
return Records[Index.toArrayIndex()].Type;
OpenPOWER on IntegriCloud