[PATCH] D82293: [CodeMoverUtils][WIP] Move code motion related checks from LICM to CodeMoverUtils
Florian Hahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 22 06:57:46 PDT 2020
fhahn added reviewers: reames, asbirlea, fhahn.
fhahn added inline comments.
================
Comment at: llvm/include/llvm/Analysis/LoopAnalysisManager.h:63
MemorySSA *MSSA;
+ PostDominatorTree &PDT;
+ DependenceInfo &DI;
----------------
Requiring those extra analysis here requires a strong motivation I think, as I think each loop pass has to make sure they are preserved or recomputed.
================
Comment at: llvm/lib/Transforms/Scalar/LICM.cpp:1392
+ DependenceInfo *DI) {
+ if (!isSafeToMoveBefore(I, Dest, *DT, *PDT, *DI))
+ return;
----------------
In order to make the transition to more general utils easier I think it might be worth considering making PDT/DI optional in the various utils and separate it from making DI & PDT required for all users, which potentially has quite a big impact.
Also, I think LICM already uses MemorySSA to figure out if it is legal to move memory access out of the loop.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D82293/new/
https://reviews.llvm.org/D82293
More information about the llvm-commits
mailing list