[PATCH] D35261: Change GlobalValueSummaryMapTy from std::map to DenseMap.

Dehao Chen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 11 08:52:15 PDT 2017


danielcdh created this revision.
Herald added subscribers: eraman, sanjoy.

GlobalValueSummaryMapTy is heavily accessed datasture. And it is large thus nlogn algorithm becomes quite expensive. Changing this to DenseMap speeds up thin-link by ~36% when building large applications.


https://reviews.llvm.org/D35261

Files:
  include/llvm/Analysis/ModuleSummaryAnalysis.h
  include/llvm/IR/ModuleSummaryIndex.h
  lib/Analysis/ModuleSummaryAnalysis.cpp
  lib/Bitcode/Writer/BitcodeWriterPass.cpp
  lib/LTO/LTO.cpp
  lib/LTO/ThinLTOCodeGenerator.cpp
  lib/Transforms/IPO/FunctionImport.cpp
  lib/Transforms/IPO/ThinLTOBitcodeWriter.cpp
  test/Bitcode/thinlto-alias.ll
  test/Bitcode/thinlto-function-summary-callgraph-profile-summary.ll
  test/Bitcode/thinlto-function-summary-callgraph-sample-profile-summary.ll
  test/Bitcode/thinlto-type-tests.ll
  test/Bitcode/thinlto-type-vcalls.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D35261.106039.patch
Type: text/x-patch
Size: 21394 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170711/022e7575/attachment.bin>


More information about the llvm-commits mailing list