[PATCH] D132233: [CGP][ARM] Dont align memcpy args when optimization for size

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 24 13:43:13 PDT 2022


efriedma added inline comments.


================
Comment at: llvm/lib/CodeGen/CodeGenPrepare.cpp:2130
   Align PrefAlign;
-  if (TLI->shouldAlignPointerArgs(CI, MinSize, PrefAlign)) {
+  if (!OptSize && TLI->shouldAlignPointerArgs(CI, MinSize, PrefAlign)) {
     for (auto &Arg : CI->args()) {
----------------
Not sure I understand the placement of this check.  Increasing the alignment of an alloca or a MemIntrinsic doesn't directly increase codesize.  And increasing the alignment of a global variable only increases codeisze if we're forced to insert extra padding.


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

https://reviews.llvm.org/D132233



More information about the llvm-commits mailing list