[PATCH] D19338: New code hoisting pass based on GVN (optimistic approach)

Sebastian Pop via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 28 15:33:19 PDT 2016


sebpop updated this revision to Diff 55499.
sebpop added a comment.

Update patch to use Memory SSA as a minimal data dependence analysis.
We may want to commit the fix to MemorySSA.cpp as a separate patch.

On the SPEC 2006 benchmarks with the patch (the number between parentheses is the difference against without the patch, positive is more with the patch):
 Number of call sites deleted, not inlined: 20419 (+25)
 Number of functions deleted because all callers found: 70393 (-104)
 Number of functions inlined: 182452 (+333)
 Number of allocas merged together: 227 (0)
 Number of caller-callers analyzed: 200825 (+464)
 Number of call sites analyzed: 446853 (+1047)
 Number of hoisted instructions: 34977
 Number of instructions removed: 88044

On the llvm test-suite the numbers are:
 Number of hoisted instructions: 35125
 Number of instructions removed: 234484


http://reviews.llvm.org/D19338

Files:
  llvm/include/llvm/InitializePasses.h
  llvm/include/llvm/LinkAllPasses.h
  llvm/include/llvm/Transforms/Scalar.h
  llvm/include/llvm/Transforms/Scalar/GVN.h
  llvm/lib/Passes/PassRegistry.def
  llvm/lib/Transforms/IPO/PassManagerBuilder.cpp
  llvm/lib/Transforms/Scalar/CMakeLists.txt
  llvm/lib/Transforms/Scalar/GVNHoist.cpp
  llvm/lib/Transforms/Scalar/Scalar.cpp
  llvm/lib/Transforms/Utils/MemorySSA.cpp
  llvm/lib/Transforms/Utils/SimplifyCFG.cpp
  llvm/test/Transforms/GVN/hoist.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D19338.55499.patch
Type: text/x-patch
Size: 55752 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160428/c944c74d/attachment.bin>


More information about the llvm-commits mailing list