Re: [PATCH] tree-ssa-strlen: Fix up handling of conditionally zero memcpy [PR110914]

2023-08-30 Thread Richard Biener via Gcc-patches
On Wed, 30 Aug 2023, Jakub Jelinek wrote: > Hi! > > The following testcase is miscompiled since r279392 aka > r10-5451-gef29b12cfbb4979 > The strlen pass has adjust_last_stmt function, which performs mainly strcat > or strcat-like optimizations (say strcpy (x, "abcd"); strcat (x, p); > or

[PATCH] tree-ssa-strlen: Fix up handling of conditionally zero memcpy [PR110914]

2023-08-30 Thread Jakub Jelinek via Gcc-patches
Hi! The following testcase is miscompiled since r279392 aka r10-5451-gef29b12cfbb4979 The strlen pass has adjust_last_stmt function, which performs mainly strcat or strcat-like optimizations (say strcpy (x, "abcd"); strcat (x, p); or equivalent memcpy (x, "abcd", strlen ("abcd") + 1); char *q =