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

            Bug ID: 85984
           Summary: ICE in create_pseudo_cfg, at dwarf2cfi.c:2874
           Product: gcc
           Version: 9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gs...@t-online.de
  Target Milestone: ---

Affects versions 8/9 at -O[23] (no better example found).
Changed between 20170723 and 20170820.


$ cat z1.c
int fn1 (void);
void __attribute__((naked))
fn2 (void)
{
  if (!fn1())
    abort ();
}
void fn3 (void)
{
  fn2 ();
}


$ gcc-9-20180527 -c z1.c -O2
z1.c: In function 'fn2':
z1.c:6:5: warning: implicit declaration of function 'abort'
[-Wimplicit-function-declaration]
     abort ();
     ^~~~~
z1.c:6:5: warning: incompatible implicit declaration of built-in function
'abort'
z1.c:6:5: note: include '<stdlib.h>' or provide a declaration of 'abort'
z1.c:1:1:
+#include <stdlib.h>
 int fn1 (void);
z1.c:6:5:
     abort ();
     ^~~~~
during RTL pass: dwarf2
z1.c:7:1: internal compiler error: in create_pseudo_cfg, at dwarf2cfi.c:2874
 }
 ^
0x7cb7a7 create_pseudo_cfg
        ../../gcc/dwarf2cfi.c:2874
0x7cb7a7 execute_dwarf2_frame
        ../../gcc/dwarf2cfi.c:3049
0x7cb7a7 execute
        ../../gcc/dwarf2cfi.c:3540

Reply via email to