Bug 113057 - Segmentation fault in dwarf2out.cc:941 with -O -fno-dwarf2-cfi-asm
Summary: Segmentation fault in dwarf2out.cc:941 with -O -fno-dwarf2-cfi-asm
Status: UNCONFIRMED
Alias: None
Product: gcc
Classification: Unclassified
Component: debug (show other bugs)
Version: 14.0
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks: rtlfe
  Show dependency treegraph
 
Reported: 2023-12-18 07:30 UTC by Anonymous
Modified: 2023-12-18 08:33 UTC (History)
0 users

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Anonymous 2023-12-18 07:30:44 UTC
Compiler Explorer: https://godbolt.org/z/4ndYafjnT

*******************************************************************************
OS and Platform:
$ uname -a:
Linux ubuntu 4.15.0-213-generic #224-Ubuntu SMP Mon Jun 19 13:30:12 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
*******************************************************************************
gcc version:
$ gcc -v
Using built-in specs.
COLLECT_GCC=/root/gcc_set/202311291030/bin/gcc
COLLECT_LTO_WRAPPER=/root/gcc_set/202311291030/libexec/gcc/x86_64-pc-linux-gnu/14.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc/configure --prefix=/root/gcc_set/202311291030 --with-gmp=/root/build_essential --with-mpfr=/root/build_essential --with-mpc=/root/build_essential --enable-languages=c,c++ --disable-multilib --with-sanitizer=address,undefined,thread,leak
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 14.0.0 20231129 (experimental) (GCC) 

git version: 99fa0bfd63d97825c4221dcd3123940f1d0e6291
*******************************************************************************
Program:
$ cat mutant.c
int __RTL (startwith ("final")) a () {
    (function "" ) 
}

*******************************************************************************
Command Lines:
$ gcc -O -fno-dwarf2-cfi-asm mutant.c
mutant.c:3:1: internal compiler error: Segmentation fault
    3 | }
      | ^
0x101491f crash_signal
        ../../gcc/gcc/toplev.cc:316
0xb6efb7 vec<dw_cfi_node*, va_gc, vl_embed>::iterate(unsigned int, dw_cfi_node**) const
        ../../gcc/gcc/vec.h:951
0xb6efb7 output_call_frame_info
        ../../gcc/gcc/dwarf2out.cc:941
Please submit a full bug report, with preprocessed source (by using -freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.