[PATCH] D104464: [LoopIdiom] Transform memmove-like loop into memmove (PR46179)

Dávid Bolvanský via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 29 07:42:06 PDT 2021


xbolva00 added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp:110
 
 STATISTIC(NumMemSet, "Number of memset's formed from loop stores");
 STATISTIC(NumMemCpy, "Number of memcpy's formed from loop load+stores");
----------------
Also you can add NumMemMove..


================
Comment at: llvm/lib/Transforms/Scalar/LoopIdiomRecognize.cpp:1380
     MSSAU->getMemorySSA()->verifyMemorySSA();
-  ++NumMemCpy;
+  if (!UseMemMove)
+    ++NumMemCpy;
----------------
… and increment it here


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D104464



More information about the llvm-commits mailing list