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

            Bug ID: 122955
           Summary: [16 Regression] Segmentation fault in lto1 when
                    building GCC with autoprofiledbootstrap
           Product: gcc
           Version: 16.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: other
          Assignee: unassigned at gcc dot gnu.org
          Reporter: dhruvc at gcc dot gnu.org
  Target Milestone: ---

I have recently started seeing this occurring when trying to run auto-profile
bootstrap on AArch64 using both SPE and BRBE, so marked it as 16 regression.

It appears that lto1 segfaults when trying to build cc1/cc1plus for
stageautoprofile, and on debugging it seems to be either an infinite loop in
the garbage collector or a very large GC that overflows the stack (probably the
former):

<...>/./prev-gcc/xg++ -B<...>/./prev-gcc/
-B<...>/install-afdo-bootstrap-debug/aarch64-unknown-linux-gnu/bin/ -nostdinc++
-B<...>/prev-aarch64-unknown-linux-gnu/libstdc++-v3/src/.libs
-B<...>/prev-aarch64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs
-I<...>/prev-aarch64-unknown-linux-gnu/libstdc++-v3/include/aarch64-unknown-linux-gnu
-I<...>/prev-aarch64-unknown-linux-gnu/libstdc++-v3/include
-I<...>/src/libstdc++-v3/libsupc++
-L<...>/prev-aarch64-unknown-linux-gnu/libstdc++-v3/src/.libs
-L<...>/prev-aarch64-unknown-linux-gnu/libstdc++-v3/libsupc++/.libs -no-pie -g
-O2 -fno-checking -flto=jobserver -frandom-seed=1 -g -DIN_GCC -fno-exceptions
-fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-error=narrowing
-Wwrite-strings -Wcast-qual -Wmissing-format-attribute
-Wconditionally-supported -Woverloaded-virtual -pedantic -Wno-long-long
-Wno-variadic-macros -Wno-overlength-strings -DHAVE_CONFIG_H -no-pie
-static-libstdc++ -static-libgcc -o cc1 c/c-lang.o c-family/stub-objc.o
attribs.o c/c-errors.o c/c-decl.o c/c-typeck.o c/c-convert.o c/c-aux-info.o
c/c-objc-common.o c/c-parser.o c/c-fold.o c/gimple-parser.o c-family/c-common.o
c-family/c-cppbuiltin.o c-family/c-dump.o c-family/c-format.o
c-family/c-gimplify.o c-family/c-indentation.o c-family/c-lex.o
c-family/c-omp.o c-family/c-opts.o c-family/c-pch.o c-family/c-ppoutput.o
c-family/c-pragma.o c-family/c-pretty-print.o c-family/c-semantics.o
c-family/c-ada-spec.o c-family/c-ubsan.o c-family/known-headers.o
c-family/c-attribs.o c-family/c-warn.o c-family/c-spellcheck.o
c-family/c-type-mismatch.o aarch64-c.o glibc-c.o cc1-checksum.o
simple-diagnostic-path.o diagnostics/lazy-paths.o libbackend.a main.o
libcommon-target.a libcommon.a ../libcpp/libcpp.a
../libdecnumber/libdecnumber.a libcommon.a ../libcpp/libcpp.a
../libbacktrace/.libs/libbacktrace.a ../libiberty/libiberty.a
../libdecnumber/libdecnumber.a -L<...>/install/lib -lisl -L<...>/install/lib
-L<...>/install/lib -L<...>/install/lib -lmpc -lmpfr -lgmp -rdynamic
-L./../zlib -lz -lzstd

xg++: internal compiler error: Segmentation fault signal terminated program
lto1
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
See <https://gcc.gnu.org/bugs/> for instructions.

Reply via email to