[llvm] [MemCpyOpt] Require writable object during call slot optimization (PR #71542)

Kohei Asano via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 8 05:09:47 PST 2023


================
@@ -6,7 +6,7 @@ declare void @llvm.memcpy.p0.p0.i64(ptr nocapture, ptr nocapture readonly, i64,
 declare void @llvm.memset.p0.i64(ptr nocapture, i8, i64, i1) nounwind
 
 ; all bytes of %dst that are touch by the memset are dereferenceable
-define void @must_remove_memcpy(ptr noalias nocapture dereferenceable(4096) %dst) nofree nosync {
+define void @must_remove_memcpy(ptr noalias nocapture writable dereferenceable(4096) %dst) nofree nosync {
----------------
khei4 wrote:

Ah, I see this is what AA matters. Thanks! 

https://github.com/llvm/llvm-project/pull/71542


More information about the llvm-commits mailing list