[PATCH] D86526: [SimplifyCFG] Consider cost of combining predicates.

Sam Parker via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 25 04:33:39 PDT 2020


samparker created this revision.
samparker added reviewers: reames, serge-sans-paille, davide, asbirlea.
Herald added a subscriber: hiraditya.
Herald added a project: LLVM.
samparker requested review of this revision.

Modify FoldBranchToCommonDest to consider the cost of inserting instructions when attempting to combine predicates to fold blocks. The threshold can be controlled via a new option: -simplifycfg-branch-fold-threshold which defaults to '2' to allow the insertion of a not and another logical operator.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D86526

Files:
  llvm/include/llvm/Transforms/Utils/Local.h
  llvm/lib/Transforms/Utils/SimplifyCFG.cpp
  llvm/test/Transforms/SimplifyCFG/ARM/branch-fold-threshold.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D86526.287628.patch
Type: text/x-patch
Size: 13199 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200825/62b2d53d/attachment.bin>


More information about the llvm-commits mailing list