[lld] r303446 - Resubmit "[CodeView] Provide a common interface for type collections."
Zachary Turner via llvm-commits
llvm-commits at lists.llvm.org
Fri May 19 12:26:58 PDT 2017
Author: zturner
Date: Fri May 19 14:26:58 2017
New Revision: 303446
URL: http://llvm.org/viewvc/llvm-project?rev=303446&view=rev
Log:
Resubmit "[CodeView] Provide a common interface for type collections."
This was originally reverted because it was a breaking a bunch
of bots and the breakage was not surfacing on Windows. After much
head-scratching this was ultimately traced back to a bug in the
lit test runner related to its pipe handling. Now that the bug
in lit is fixed, Windows correctly reports these test failures,
and as such I have finally (hopefully) fixed all of them in this
patch.
Modified:
lld/trunk/COFF/PDB.cpp
Modified: lld/trunk/COFF/PDB.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/PDB.cpp?rev=303446&r1=303445&r2=303446&view=diff
==============================================================================
--- lld/trunk/COFF/PDB.cpp (original)
+++ lld/trunk/COFF/PDB.cpp Fri May 19 14:26:58 2017
@@ -14,7 +14,8 @@
#include "SymbolTable.h"
#include "Symbols.h"
#include "llvm/DebugInfo/CodeView/CVDebugRecord.h"
-#include "llvm/DebugInfo/CodeView/CVTypeDumper.h"
+#include "llvm/DebugInfo/CodeView/CVTypeVisitor.h"
+#include "llvm/DebugInfo/CodeView/LazyRandomTypeCollection.h"
#include "llvm/DebugInfo/CodeView/SymbolDumper.h"
#include "llvm/DebugInfo/CodeView/TypeDatabase.h"
#include "llvm/DebugInfo/CodeView/TypeDumpVisitor.h"
@@ -134,12 +135,11 @@ static void dumpDebugT(ScopedPrinter &W,
if (Data.empty())
return;
- TypeDatabase TDB(0);
- TypeDumpVisitor TDV(TDB, &W, false);
+ LazyRandomTypeCollection Types(Data, 100);
+ TypeDumpVisitor TDV(Types, &W, false);
// Use a default implementation that does not follow type servers and instead
// just dumps the contents of the TypeServer2 record.
- CVTypeDumper TypeDumper(TDB);
- if (auto EC = TypeDumper.dump(Data, TDV))
+ if (auto EC = codeview::visitTypeStream(Types, TDV))
fatal(EC, "CVTypeDumper::dump failed");
}
More information about the llvm-commits
mailing list