[PATCH] D85963: [SLC] sprintf(dst, "%s", str) -> strcpy(dst, str)

Dávid Bolvanský via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 14 09:14:01 PDT 2020


xbolva00 added inline comments.


================
Comment at: llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp:2501
+                      llvm::shouldOptimizeForSize(CI->getParent(), PSI, BFI,
+                                                  PGSOQueryType::IRPass);
+    if (OptForSize)
----------------
efriedma wrote:
> I don't think I've seen this `hasOptSize() || shouldOptimizeForSize()` pattern before; is there documentation anywhere?
Also used eg in “optimizeFputs”

It was introducted as part of PGSO.


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

https://reviews.llvm.org/D85963



More information about the llvm-commits mailing list