[PATCH] D132571: [RLEV] Pick a correct insert point when incoming instruction is itself a phi node

Yevgeny Rouban via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 1 05:29:03 PDT 2022


yrouban added inline comments.


================
Comment at: llvm/lib/Transforms/Utils/LoopUtils.cpp:1398-1400
+        Instruction *InsertPt =
+          (isa<PHINode>(Inst) || isa<LandingPadInst>(Inst)) ?
+          &*Inst->getParent()->getFirstInsertionPt() : Inst;
----------------
Would it be better to fix //SCEVExpander::expandCodeForImpl(const SCEV *SH, Type *Ty, Instruction *IP, bool Root)// so it fixed IP in the same way? It would fix all its users.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D132571/new/

https://reviews.llvm.org/D132571



More information about the llvm-commits mailing list