[PATCH] D32631: Speed up the -Map option.

Dean Michael Berris via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 27 21:05:23 PDT 2017


dberris added inline comments.


================
Comment at: lld/ELF/MapFile.cpp:50
+  // Maps sections to their symbols.
+  DenseMap<const SectionBase *, std::vector<SymbolBody *>> Symbols;
+
----------------
ruiu wrote:
> dberris wrote:
> > No `SmallVector<...>` ?
> Does it make any noticeable difference? I usually use data structures in the standard library unless that is not appropriate because most people are more familiar with std::* than llvm:*.
I suspect it should, especially if you size the SmallVector with enough values to not require an additional indirection when reaching for the values. It should be easy to measure, given that you already have a test case. :)


https://reviews.llvm.org/D32631





More information about the llvm-commits mailing list