[PATCH] D37163: [LICM] sink through non-trivially replicable PHI
Eli Friedman via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 25 14:44:33 PDT 2017
efriedma added inline comments.
================
Comment at: lib/Transforms/Scalar/LICM.cpp:803
+ Instruction *New;
+ auto It = SunkCopies.find(ExitBlock);
+ if (It != SunkCopies.end())
----------------
Do you need to do something to keep SunkCopies up to date?
================
Comment at: lib/Transforms/Scalar/LICM.cpp:858
+ while (i != e) {
+ if (CurLoop->contains(PN->getIncomingBlock(i))) {
+ SplitBlockPredecessors(PN->getParent(), PN->getIncomingBlock(i),
----------------
The indexing here is a little weird; can you first compute all the blocks to split, then split them?
https://reviews.llvm.org/D37163
More information about the llvm-commits
mailing list