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

            Bug ID: 79975
           Summary: SEGV in cc1 compiling gcc.dg/rtl/x86_64/final.c
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ro at gcc dot gnu.org
                CC: dmalcolm at gcc dot gnu.org
  Target Milestone: ---
              Host: i?86-pc-solaris2.*, amd64-pc-solaris2.*
            Target: i?86-pc-solaris2.*, amd64-pc-solaris2.*
             Build: i?86-pc-solaris2.*, amd64-pc-solaris2.*

The gcc.dg/rtl/x86_64/final.c test FAILs on Solaris/x86:

FAIL: gcc.dg/rtl/x86_64/final.c (internal compiler error)
FAIL: gcc.dg/rtl/x86_64/final.c (test for excess errors)
UNRESOLVED: gcc.dg/rtl/x86_64/final.c scan-assembler .cfi_endproc
UNRESOLVED: gcc.dg/rtl/x86_64/final.c scan-assembler .cfi_startproc
UNRESOLVED: gcc.dg/rtl/x86_64/final.c scan-assembler ret
UNRESOLVED: gcc.dg/rtl/x86_64/final.c scan-assembler test_1:

I'm seeing the failure either with a 64-bit-default compiler (amd64-*-* config)
or a 32-bit-default compiler (i386-*-* config) when using /bin/as:
Excess errors:
/vol/gcc/src/hg/trunk/local/gcc/testsuite/gcc.dg/rtl/x86_64/final.c:124:1:
internal compiler error: Segmentation Fault
0x8da32ec crash_signal
        /vol/gcc/src/hg/trunk/local/gcc/toplev.c:337
0x8a17cbe vec<dw_cfi_node*, va_gc, vl_embed>::iterate(unsigned int,
dw_cfi_node**) const
        /vol/gcc/src/hg/trunk/local/gcc/vec.h:773
0x8a17cbe output_call_frame_info
        /vol/gcc/src/hg/trunk/local/gcc/dwarf2out.c:920

In the amd64-pc-solaris2.12 case with gas, I have

$ cc1 -fpreprocessed final.i -quiet -o final.s

Thread 2 received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1 (LWP 1)]
0x000000000118a29c in vec<dw_cfi_node*, va_gc, vl_embed>::iterate (
    ptr=<synthetic pointer>, ix=0, this=0x0)
    at /vol/gcc/src/hg/trunk/local/gcc/vec.h:773
773       if (ix < m_vecpfx.m_num)
(gdb) where
#0  0x000000000118a29c in vec<dw_cfi_node*, va_gc, vl_embed>::iterate (
    ptr=<synthetic pointer>, ix=0, this=0x0)
    at /vol/gcc/src/hg/trunk/local/gcc/vec.h:773
#1  output_call_frame_info (for_eh=for_eh@entry=1)
    at /vol/gcc/src/hg/trunk/local/gcc/dwarf2out.c:920
#2  0x000000000119193b in dwarf2out_frame_finish ()
    at /vol/gcc/src/hg/trunk/local/gcc/dwarf2out.c:1178
#3  0x0000000001551d26 in compile_file ()
    at /vol/gcc/src/hg/trunk/local/gcc/toplev.c:542
#4  0x0000000001553b46 in do_compile ()
    at /vol/gcc/src/hg/trunk/local/gcc/toplev.c:1984
#5  toplev::main (this=this@entry=0xffff80ffbfffeb80, argc=<optimized out>, 
    argc@entry=6, argv=<optimized out>, argv@entry=0xffff80ffbfffebc8)
    at /vol/gcc/src/hg/trunk/local/gcc/toplev.c:2118
#6  0x0000000001dc023e in main (argc=6, argv=0xffff80ffbfffebc8)
    at /vol/gcc/src/hg/trunk/local/gcc/main.c:39

(gdb) p m_vecpfx
Cannot access memory at address 0x0

  Rainer

Reply via email to