[PATCH] D150970: (WIP) [MemCpyOpt]remove memcpy on immutable arguments from attributes
Kohei Asano via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon May 29 22:52:29 PDT 2023
khei4 planned changes to this revision.
khei4 added a comment.
need to change test on https://reviews.llvm.org/D150967#4365466 and refine description
================
Comment at: llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp:1704-1705
+ MSSA->getMemoryAccess(MDep), MSSA->getMemoryAccess(&CB)) ||
+ writtenBetween(MSSA, BAA, MemoryLocation::getForDest(MDep),
+ MSSA->getMemoryAccess(MDep), MSSA->getMemoryAccess(&CB)))
+ return false;
----------------
dest check might be redundant because the first clobber check might already show dest is not modified between call and memcpy.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D150970/new/
https://reviews.llvm.org/D150970
More information about the llvm-commits
mailing list