https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88087

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
non-LTO testcase (void cast just to silence a warning):

int f();
int d;
void c() 
{
  for (;;)
    {
      f();
      int (*fp)() __attribute__((const)) = (void *)f;
      d = fp();
    }
}

the issue is that PRE tries to hoist the const call out of the loop
(OK) but the VN machinery doesn't track call fntypes so insertion
ends up with the decls fntype.

That's a latent issue anyways.

Reply via email to