[PATCH] D100979: [loop-idiom][NFC] Extract processLoopStoreOfLoopLoad into a helper function

Han Zhu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 22 14:04:49 PDT 2021


zhuhan0 added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp:1088
   const SCEVAddRecExpr *LoadEv =
       cast<SCEVAddRecExpr>(SE->getSCEV(LI->getPointerOperand()));
+  Value *LoadPtr = LI->getPointerOperand();
----------------
hoy wrote:
> zhuhan0 wrote:
> > hoy wrote:
> > > Nit: reuse LoadPtr below?
> > Could you clarify? Where should I reuse `LoadPtr`?
> There is a use of LI->getPointerOperand() at line 1088 that can be replaced by LoadPtr. Sorry for the confusion.
Ah got it. Will do.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D100979



More information about the llvm-commits mailing list