[PATCH] D54223: [SimpleLoopUnswitch] adding cost multiplier to cap exponential unswitch with
Chandler Carruth via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 14 21:08:28 PST 2018
chandlerc accepted this revision.
chandlerc added a comment.
still LGTM.
================
Comment at: lib/Transforms/Scalar/SimpleLoopUnswitch.cpp:2303
+ (isGuard(&TI) ||
+ 1 >= llvm::count_if(successors(&TI), [&L](BasicBlock *SuccBB) {
+ return L.contains(SuccBB);
----------------
I think the yoda-comparison makes this harder to read. I'd rather say `count_if(...) <= 1`.
Repository:
rL LLVM
https://reviews.llvm.org/D54223
More information about the llvm-commits
mailing list