[PATCH] D35738: Enable llvm-pdbutil to list enumerations using native PDB reader

Adrian McCarthy via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 2 09:59:20 PDT 2017


amccarth marked 4 inline comments as done.
amccarth added a comment.

I'll ping when it's ready for another look.



================
Comment at: llvm/lib/DebugInfo/PDB/Native/NativeExeSymbol.cpp:47
+      bool HadError = false;
+      const auto &Types = Tpi->types(&HadError);
+      if (HadError)
----------------
zturner wrote:
> If you call `Tpi->typeCollection()` instead of `Tpi->types()`, then you can store a `LazyRandomTypeCollection` in the `NativeEnumTypes`, which should be more efficient.  This also solves the problem of making the session own the `TpiStream`, and should enable you to easily create an enumerator for the values of the enum.
> 
> In fact, I'd like to eventually delete the `types()` method now that we have the random access type collection.
Working on this.


https://reviews.llvm.org/D35738





More information about the llvm-commits mailing list