[PATCH] D28414: Simplify conditional branch on constant condition and remove unreachable blocks in LoopUnswitch.
Xin Tong via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 6 15:44:48 PST 2017
trentxintong added inline comments.
================
Comment at: lib/Transforms/Scalar/LoopUnswitch.cpp:1374
+ BI->eraseFromParent();
+ Worklist.push_back(NBI);
+ }
----------------
efriedma wrote:
> See the comment near the beginning of LoopUnswitch::TryTrivialLoopUnswitch for a description of all the state you aren't updating correctly.
>
> Also, I think you meant "isa<ConstantInt>(BI->getCondition())".
Thanks @efriedma. In llvm, a change in CFG like this, do we usually expect to update the dominator tree dynamic/manually or we are ok with DT->recalculate.
https://reviews.llvm.org/D28414
More information about the llvm-commits
mailing list