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

            Bug ID: 92917
           Summary: ipa-cp segfaults in print_all_lattices
           Product: gcc
           Version: 10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ipa
          Assignee: unassigned at gcc dot gnu.org
          Reporter: erick.oc...@theobroma-systems.com
                CC: marxin at gcc dot gnu.org
  Target Milestone: ---

Created attachment 47477
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=47477&action=edit
Possible fix

Stacktrace
===========

lto1: internal compiler error: Segmentation fault
0xbcff9b crash_signal
        ../../gcc/gcc/toplev.c:328
0x1533c14 print_all_lattices
        ../../gcc/gcc/ipa-cp.c:547
0x1536edf ipcp_propagate_stage
        ../../gcc/gcc/ipa-cp.c:3876
0x153c1c7 ipcp_driver
        ../../gcc/gcc/ipa-cp.c:5746
0x153c1c7 execute
        ../../gcc/gcc/ipa-cp.c:5839
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
lto-wrapper: fatal error: ../gcc2/gcc-inst/bin/gcc returned 1 exit status
compilation terminated.
/usr/bin/ld: error: lto-wrapper failed
collect2: error: ld returned 1 exit status
make: *** [Makefile:2: all] Error 1

Code to trigger
===============

int
main(int argc, char**argv)
{
  return 0;
}

How to compile
===============

/path/to/gcc a.c -flto -fdump-ipa-all

How gcc was compiled
====================

$ ../gcc2/gcc-inst/bin/gcc -v
Using built-in specs.
COLLECT_GCC=../gcc2/gcc-inst/bin/gcc
COLLECT_LTO_WRAPPER=/home/eochoa/code/gcc2/gcc-inst/libexec/gcc/aarch64-unknown-linux-gnu/10.0.0/lto-wrapper
Target: aarch64-unknown-linux-gnu
Configured with: ../gcc/configure --disable-bootstrap --disable-libsanitizer
--enable-__cxa_atexit --enable-shared --disable-libsanitizer
--enable-languages=c,c++,fortran --enable-lto --enable-gold
--enable-linker-build-id --with-cpu-emag
--prefix=/home/eochoa/code/gcc2/gcc-inst : (reconfigured) ../gcc/configure
--disable-bootstrap --disable-libsanitizer --enable-__cxa_atexit
--enable-shared --disable-libsanitizer --enable-languages=c,c++,fortran
--enable-lto --enable-gold --enable-linker-build-id --with-cpu-emag
--prefix=/home/eochoa/code/gcc2/gcc-inst
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 10.0.0 20191211 (experimental) (GCC)

Which git commit id is HEAD?
===========================

300dae5c80ddda7ab4fedffaa0bbf53887232a53
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@279250
138bc75d-0d04-0410-961f-82ee72b054a4

I have attached a possible (lazy) fix.

Reply via email to