summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2017-05-18 23:04:08 +0000
committerZachary Turner <zturner@google.com>2017-05-18 23:04:08 +0000
commitb32ec02b80bf3f321acf7b74a1a4e4ed7dc882bb (patch)
tree683b79478f51ab1fb223bad4204911c13d31bc28 /llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp
parent8fb441ab9cdb848c2e3f3b8f6a0c88ff0c8a875b (diff)
downloadbcm5719-llvm-b32ec02b80bf3f321acf7b74a1a4e4ed7dc882bb.tar.gz
bcm5719-llvm-b32ec02b80bf3f321acf7b74a1a4e4ed7dc882bb.zip
[CodeView] Raise the source to ID map out of the TypeStreamMerger.
This map will be needed to rewrite symbol streams after re-writing the corresponding type streams. llvm-svn: 303390
Diffstat (limited to 'llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp')
-rw-r--r--llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp b/llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp
index d3c6a799ac4..d9004f78a0e 100644
--- a/llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp
+++ b/llvm/tools/llvm-pdbdump/llvm-pdbdump.cpp
@@ -36,6 +36,7 @@
#include "llvm/DebugInfo/CodeView/ModuleDebugInlineeLinesFragment.h"
#include "llvm/DebugInfo/CodeView/ModuleDebugLineFragment.h"
#include "llvm/DebugInfo/CodeView/TypeStreamMerger.h"
+#include "llvm/DebugInfo/CodeView/TypeTableBuilder.h"
#include "llvm/DebugInfo/MSF/MSFBuilder.h"
#include "llvm/DebugInfo/PDB/GenericError.h"
#include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
@@ -851,15 +852,18 @@ static void mergePdbs() {
for (const auto &Path : opts::merge::InputFilenames) {
std::unique_ptr<IPDBSession> Session;
auto &File = loadPDB(Path, Session);
+ SmallVector<TypeIndex, 128> SourceToDest;
if (File.hasPDBTpiStream()) {
+ SourceToDest.clear();
auto &Tpi = ExitOnErr(File.getPDBTpiStream());
- ExitOnErr(codeview::mergeTypeStreams(MergedIpi, MergedTpi, nullptr,
- Tpi.typeArray()));
+ ExitOnErr(codeview::mergeTypeStreams(MergedIpi, MergedTpi, SourceToDest,
+ nullptr, Tpi.typeArray()));
}
if (File.hasPDBIpiStream()) {
+ SourceToDest.clear();
auto &Ipi = ExitOnErr(File.getPDBIpiStream());
- ExitOnErr(codeview::mergeTypeStreams(MergedIpi, MergedTpi, nullptr,
- Ipi.typeArray()));
+ ExitOnErr(codeview::mergeTypeStreams(MergedIpi, MergedTpi, SourceToDest,
+ nullptr, Ipi.typeArray()));
}
}
OpenPOWER on IntegriCloud