https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118318
Bug ID: 118318 Summary: ICE when building firefox-134.0 with PGO Product: gcc Version: 15.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: gcov-profile Assignee: unassigned at gcc dot gnu.org Reporter: sjames at gcc dot gnu.org Target Milestone: --- It'll take me some time to try get a testcase. Hints or ideas welcome. I think it's a regression but it's possibly caused by FF changes and was latent otherwise, I can't easily check that yet. ``` /usr/bin/x86_64-pc-linux-gnu-gcc-15 -std=gnu99 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3 -fstack-protector-strong -fstrict-flex-arrays=1 -pthread -ffunction-sections -fdata-sections -fno-math-errno -pipe -fPIC -march=native -mtls-dialect=gnu2 -fno-semantic-interposition -pipe -fcf-protection=none -O3 -fomit-frame-pointer -funwind-tables -shared -Wl,-z,defs -Wl,--gc-sections -Wl,-h,libmozavutil.so -o ../../../dist/bin/libmozavutil.so -Wl,@/var/tmp/portage/www-client/firefox-134.0/work/firefox_build/media/ffvpx/libavutil/libmozavutil_so.list -flto=32 -flifetime-dse=1 -march=native -mtls-dialect=gnu2 -fno-semantic-interposition -pipe -fcf-protection=none -Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs -fuse-ld=mold -Wl,--defsym=__gentoo_check_ldflags__=0 -Wl,-z,relro -Wl,-z,now -Wl,--undefined-version -Wl,-rpath=/usr/lib64/firefox,--enable-new-dtags -Wl,-z,noexecstack -Wl,-z,text -Wl,-z,relro -Wl,-z,now -Wl,-z,nocopyreloc -fuse-ld=bfd -Wl,-z,pack-relative-relocs -fstack-protector-strong -Wl,-rpath-link,/var/tmp/portage/www-client/firefox-134.0/work/firefox_build/dist/bin -fprofile-use ../../../dist/bin/libgkcodecs.so -Wl,--version-script,libmozavutil.so.symbols -ldl -lm during IPA pass: cp lto1: internal compiler error: in operator+=, at profile-count.h:932 0x5c9a735fa9a9 internal_error(char const*, ...) /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/diagnostic-global-context.cc:517 0x5c9a735fab44 fancy_abort(char const*, int, char const*) /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/diagnostic.cc:1722 0x5c9a71ff25ae profile_count::operator+=(profile_count const&) /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/profile-count.h:932 0x5c9a71ff25ae profile_count::operator+=(profile_count const&) /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/profile-count.h:919 0x5c9a735282ae adjust_clone_incoming_counts(cgraph_node*, desc_incoming_count_struct*) [clone .isra.0] /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/ipa-cp.cc:4609 0x5c9a71ebf7bc update_counts_for_self_gen_clones /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/ipa-cp.cc:4725 0x5c9a71ebf7bc decide_whether_version_node /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/ipa-cp.cc:6087 0x5c9a73ecc65e ipcp_decision_stage /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/ipa-cp.cc:6252 0x5c9a73ecc65e ipcp_driver /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/ipa-cp.cc:6427 0x5c9a73ecc65e execute /usr/src/debug/sys-devel/gcc-15.0.9999/gcc-15.0.9999/gcc/ipa-cp.cc:6500 Please submit a full bug report, with preprocessed source (by using -freport-bug). Please include the complete backtrace with any bug report. See <https://bugs.gentoo.org/> for instructions. lto-wrapper: fatal error: /usr/bin/x86_64-pc-linux-gnu-gcc-15 returned 1 exit status compilation terminated. /usr/lib/gcc/x86_64-pc-linux-gnu/15/../../../../x86_64-pc-linux-gnu/bin/ld.bfd: error: lto-wrapper failed collect2: error: ld returned 1 exit status ``` ``` Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-pc-linux-gnu/15/lto-wrapper OFFLOAD_TARGET_NAMES=nvptx-none OFFLOAD_TARGET_DEFAULT=1 Target: x86_64-pc-linux-gnu Configured with: /var/tmp/portage/sys-devel/gcc-15.0.9999/work/gcc-15.0.9999/configure --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/15 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/15/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/15 --mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/15/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/15/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15 --disable-silent-rules --disable-dependency-tracking --with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/15/python --enable-objc-gc --enable-languages=c,c++,d,go,objc,obj-c++,fortran,ada,m2,rust --enable-obsolete --enable-secureplt --disable-werror --with-system-zlib --enable-nls --without-included-gettext --disable-libunwind-exceptions --enable-checking=yes,extra,rtl --with-bugurl=https://bugs.gentoo.org/ --with-pkgversion='Gentoo Hardened 15.0.9999 p, commit f6d3d0becd191f48aca221595377e39e53708adf' --with-gcc-major-version-only --enable-libstdcxx-time --enable-lto --disable-libstdcxx-pch --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --enable-multilib --with-multilib-list=m32,m64 --disable-fixed-point --enable-targets=all --enable-offload-defaulted --enable-offload-targets=nvptx-none --enable-libgomp --disable-libssp --enable-libada --disable-cet --disable-systemtap --enable-valgrind-annotations --disable-vtable-verify --disable-libvtv --with-zstd --with-isl --disable-isl-version-check --enable-default-pie --enable-host-pie --enable-host-bind-now --enable-default-ssp --disable-fixincludes --with-build-config='bootstrap-O3 bootstrap-lto' Thread model: posix Supported LTO compression algorithms: zlib zstd gcc version 15.0.0 20250106 (experimental) 144ddb0cdfa7a09ccbaaea5ec72837346fbc1d8d (Gentoo Hardened 15.0.9999 p, commit f6d3d0becd191f48aca221595377e39e53708adf) ```