[PATCH] D71047: [LV] Keep dominator tree up to date during vectorization.
Florian Hahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 5 00:43:49 PST 2019
fhahn requested changes to this revision.
fhahn added a comment.
This revision now requires changes to proceed.
Please split the patch into one that only preserves the DT directly, without any other changes.
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:2676
Value *Count = getOrCreateTripCount(L);
- BasicBlock *BB = L->getLoopPreheader();
- IRBuilder<> Builder(BB->getTerminator());
+ BasicBlock *const OrigPreHeader = LoopVectorPreHeader;
+ IRBuilder<> Builder(OrigPreHeader->getTerminator());
----------------
Change unrelated to keeping the DT up to date?
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:2698
+ LoopVectorPreHeader =
+ OrigPreHeader->splitBasicBlock(OrigPreHeader->getTerminator(), OrigName);
// Update dominator tree immediately if the generated block is a
----------------
Please use SplitBlock from BasicBlockUtils.h and pass the DT instead of updating it manually (here and at other paces in the patch) Same for LoopInfo.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D71047/new/
https://reviews.llvm.org/D71047
More information about the llvm-commits
mailing list