[Bug tree-optimization/58715] Missed loop condition optimization opportunity
pinskia at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sun Oct 13 18:19:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58715
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Here is a testcase which shows we are not doing some other loop opt due to not
changing the loop:
typedef __SIZE_TYPE__ size_t;
void f(int mlen, unsigned char *dst, size_t d_len, unsigned char *cpy)
{
unsigned char *d_end = dst + d_len;
while (--mlen >= 0 && dst < d_end)
*dst++ = 0;
}
This should produce memset but we are not currently.
More information about the Gcc-bugs
mailing list