https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109238
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Reduced testcase:
/* PR tree-optimization/10923 */
/* { dg-do compile } */
/* { dg-options "-O2 -Wall" } */
void foo (void) __attribute__((noreturn));
void bar (void *);
void
baz (void *p)
{
void *c = __builtin_realloc (p, 16);
if (c)
foo ();
for (;;)
bar (__builtin_realloc (p, 8)); /* { dg-bogus "pointer 'p' may be used
after '__builtin_realloc'" } */
}