https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92406
Bug ID: 92406 Summary: [10 Regression] ICE in ipa_call_summary at ipa-fnsummary.h:253 with lto and pgo Product: gcc Version: 10.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: lto Assignee: unassigned at gcc dot gnu.org Reporter: jan at jki dot io CC: marxin at gcc dot gnu.org Target Milestone: --- Created attachment 47192 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=47192&action=edit preprocessed source Latest trunk This is a profiled python build version 3.7.4 Only happens with PGO and LTO enabled. /usr/libexec/gcc/x86_64-pc-linux-gnu/10.0.0-pre9999/lto-wrapper -fresolution=-lm.res -flinker-output=dyn Modules/getbuildinfo.o Parser/acceler.o Parser/grammar1.o Parser/listnode.o P arser/node.o Parser/parser.o Parser/bitset.o Parser/metagrammar.o Parser/firstsets.o Parser/grammar.o Parser/pgen.o Parser/myreadline.o Parser/parsetok.o Parser/tokenizer.o Objects/a bstract.o Objects/accu.o Objects/boolobject.o Objects/bytes_methods.o Objects/bytearrayobject.o Objects/bytesobject.o Objects/call.o Objects/cellobject.o Objects/classobject.o Object s/codeobject.o Objects/complexobject.o Objects/descrobject.o Objects/enumobject.o Objects/exceptions.o Objects/genobject.o Objects/fileobject.o Objects/floatobject.o Objects/frameobj ect.o Objects/funcobject.o Objects/iterobject.o Objects/listobject.o Objects/longobject.o Objects/dictobject.o Objects/odictobject.o Objects/memoryobject.o Objects/methodobject.o Obj ects/moduleobject.o Objects/namespaceobject.o Objects/object.o Objects/obmalloc.o Objects/capsule.o Objects/rangeobject.o Objects/setobject.o Objects/sliceobject.o Objects/structseq. o Objects/tupleobject.o Objects/typeobject.o Objects/unicodeobject.o Objects/unicodectype.o Objects/weakrefobject.o Python/_warnings.o Python/Python-ast.o Python/asdl.o Python/ast.o Python/ast_opt.o Python/ast_unparse.o Python/bltinmodule.o Python/ceval.o Python/compile.o Python/codecs.o Python/dynamic_annotations.o Python/errors.o Python/frozenmain.o Python/fut ure.o Python/getargs.o Python/getcompiler.o Python/getcopyright.o Python/getplatform.o Python/getversion.o Python/graminit.o Python/import.o Python/importdl.o Python/marshal.o Python /modsupport.o Python/mysnprintf.o Python/mystrtoul.o Python/pathconfig.o Python/peephole.o Python/pyarena.o Python/pyctype.o Python/pyfpe.o Python/pyhash.o Python/pylifecycle.o Pytho n/pymath.o Python/pystate.o Python/context.o Python/hamt.o Python/pythonrun.o Python/pytime.o Python/bootstrap_hash.o Python/structmember.o Python/symtable.o Python/sysmodule.o Pytho n/thread.o Python/traceback.o Python/getopt.o Python/pystrcmp.o Python/pystrtod.o Python/pystrhex.o Python/dtoa.o Python/formatter_unicode.o Python/fileutils.o Python/dynload_shlib.o Modules/config.o Modules/getpath.o Modules/main.o Modules/gcmodule.o Modules/posixmodule.o Modules/errnomodule.o Modules/pwdmodule.o Modules/_sre.o Modules/_codecsmodule.o Modules/_ weakref.o Modules/_functoolsmodule.o Modules/_operator.o Modules/_collectionsmodule.o Modules/_abc.o Modules/itertoolsmodule.o Modules/atexitmodule.o Modules/signalmodule.o Modules/_ stat.o Modules/timemodule.o Modules/_threadmodule.o Modules/_localemodule.o Modules/_iomodule.o Modules/iobase.o Modules/fileio.o Modules/bytesio.o Modules/bufferedio.o Modules/texti o.o Modules/stringio.o Modules/zipimport.o Modules/faulthandler.o Modules/_tracemalloc.o Modules/hashtable.o Modules/symtablemodule.o Modules/xxsubtype.o Python/frozen.o /usr/libexec/gcc/x86_64-pc-linux-gnu/10.0.0-pre9999/lto-wrapper -fresolution=-lm.res -flinker-output=dyn Modules/getbuildinfo.o Parser/acceler.o Parser/grammar1.o Parser/listnode.o P arser/node.o Parser/parser.o Parser/bitset.o Parser/metagrammar.o Parser/firstsets.o Parser/grammar.o Parser/pgen.o Parser/myreadline.o Parser/parsetok.o Parser/tokenizer.o Objects/a bstract.o Objects/accu.o Objects/boolobject.o Objects/bytes_methods.o Objects/bytearrayobject.o Objects/bytesobject.o Objects/call.o Objects/cellobject.o Objects/classobject.o Object s/codeobject.o Objects/complexobject.o Objects/descrobject.o Objects/enumobject.o Objects/exceptions.o Objects/genobject.o Objects/fileobject.o Objects/floatobject.o Objects/frameobj ect.o Objects/funcobject.o Objects/iterobject.o Objects/listobject.o Objects/longobject.o Objects/dictobject.o Objects/odictobject.o Objects/memoryobject.o Objects/methodobject.o Obj ects/moduleobject.o Objects/namespaceobject.o Objects/object.o Objects/obmalloc.o Objects/capsule.o Objects/rangeobject.o Objects/setobject.o Objects/sliceobject.o Objects/structseq. o Objects/tupleobject.o Objects/typeobject.o Objects/unicodeobject.o Objects/unicodectype.o Objects/weakrefobject.o Python/_warnings.o Python/Python-ast.o Python/asdl.o Python/ast.o Python/ast_opt.o Python/ast_unparse.o Python/bltinmodule.o Python/ceval.o Python/compile.o Python/codecs.o Python/dynamic_annotations.o Python/errors.o Python/frozenmain.o Python/fut ure.o Python/getargs.o Python/getcompiler.o Python/getcopyright.o Python/getplatform.o Python/getversion.o Python/graminit.o Python/import.o Python/importdl.o Python/marshal.o Python /modsupport.o Python/mysnprintf.o Python/mystrtoul.o Python/pathconfig.o Python/peephole.o Python/pyarena.o Python/pyctype.o Python/pyfpe.o Python/pyhash.o Python/pylifecycle.o Pytho n/pymath.o Python/pystate.o Python/context.o Python/hamt.o Python/pythonrun.o Python/pytime.o Python/bootstrap_hash.o Python/structmember.o Python/symtable.o Python/sysmodule.o Pytho n/thread.o Python/traceback.o Python/getopt.o Python/pystrcmp.o Python/pystrtod.o Python/pystrhex.o Python/dtoa.o Python/formatter_unicode.o Python/fileutils.o Python/dynload_shlib.o Modules/config.o Modules/getpath.o Modules/main.o Modules/gcmodule.o Modules/posixmodule.o Modules/errnomodule.o Modules/pwdmodule.o Modules/_sre.o Modules/_codecsmodule.o Modules/_ weakref.o Modules/_functoolsmodule.o Modules/_operator.o Modules/_collectionsmodule.o Modules/_abc.o Modules/itertoolsmodule.o Modules/atexitmodule.o Modules/signalmodule.o Modules/_ stat.o Modules/timemodule.o Modules/_threadmodule.o Modules/_localemodule.o Modules/_iomodule.o Modules/iobase.o Modules/fileio.o Modules/bytesio.o Modules/bufferedio.o Modules/texti o.o Modules/stringio.o Modules/zipimport.o Modules/faulthandler.o Modules/_tracemalloc.o Modules/hashtable.o Modules/symtablemodule.o Modules/xxsubtype.o Python/frozen.o x86_64-pc-linux-gnu-gcc @/tmp/ccTN2VT6 Using built-in specs. COLLECT_GCC=x86_64-pc-linux-gnu-gcc Target: x86_64-pc-linux-gnu Configured with: /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/configure --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr --bindir=/usr/x8 6_64-pc-linux-gnu/gcc-bin/10.0.0-pre9999 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/10.0.0-pre9999/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/10.0.0-pre9999 --mandi r=/usr/share/gcc-data/x86_64-pc-linux-gnu/10.0.0-pre9999/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/10.0.0-pre9999/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux -gnu/10.0.0-pre9999/include/g++-v10 --with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/10.0.0-pre9999/python --enable-languages=c,c++,fortran --enable-obsolete --enable-secureplt --disable-werror --with-system-zlib --enable-nls --without-included-gettext --enable-checking=release --with-bugurl=https://bugs.gentoo.org/ --with-pkgversion='Gentoo 10.0.0_pre9999' --disable-esp --enable-libstdcxx-time --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --enable-multilib --with-multilib-list=m32,m64 --disable-alti vec --disable-fixed-point --enable-targets=all --enable-libgomp --disable-libmudflap --disable-libssp --disable-systemtap --disable-vtable-verify --disable-libvtv --enable-lto --with -isl --disable-isl-version-check --disable-libsanitizer --disable-default-pie --disable-default-ssp --enable-plugin --disable-vtable-verify --with-ppl=yes --disable-libunwind-excepti ons --disable-default-pie --with-glibc-version=2.19 --disable-libmpx --enable-bootstrap --with-tune=skylake --with-arch=skylake --enable-linker-build-id --with-gnu-ld --enable-libstd cxx-pch --with-fpmath=avx --with-zstd Thread model: posix Supported LTO compression algorithms: zlib zstd gcc version 10.0.0-pre9999 20191107 (experimental) (Gentoo 10.0.0_pre9999) COLLECT_GCC_OPTIONS='-c' '-fno-openmp' '-fno-openacc' '-g' '-O2' '-fPIC' '-pthread' '-shared' '-march=skylake' '-O2' '-Wno-error' '-v' '-save-temps' '-g' '-L.' '-dumpdir' './' '-dump base' 'libpython3.7m.so.1.0.wpa' '-fltrans-output-list=libpython3.7m.so.1.0.ltrans.out' '-fwpa=20' '-fresolution=-lm.res' '-flinker-output=dyn' /usr/libexec/gcc/x86_64-pc-linux-gnu/10.0.0-pre9999/lto1 -quiet -dumpdir ./ -dumpbase libpython3.7m.so.1.0.wpa -march=skylake -auxbase getbuildinfo -g -g -O2 -O2 -Wno-error -version -fno-openmp -fno-openacc -fPIC -fltrans-output-list=libpython3.7m.so.1.0.ltrans.out -fwpa=20 -fresolution=-lm.res -flinker-output=dyn @/tmp/cce0vDef GNU GIMPLE (Gentoo 10.0.0_pre9999) version 10.0.0-pre9999 20191107 (experimental) (x86_64-pc-linux-gnu) compiled by GNU C version 10.0.0-pre9999 20191107 (experimental), GMP version 6.1.2, MPFR version 4.0.2, MPC version 1.1.0, isl version isl-0.21-GMP GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 GNU GIMPLE (Gentoo 10.0.0_pre9999) version 10.0.0-pre9999 20191107 (experimental) (x86_64-pc-linux-gnu) compiled by GNU C version 10.0.0-pre9999 20191107 (experimental), GMP version 6.1.2, MPFR version 4.0.2, MPC version 1.1.0, isl version isl-0.21-GMP GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 during IPA pass: icf In function ‘bytes_dealloc’: lto1: internal compiler error: Segmentation fault 0x9c731f crash_signal /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/toplev.c:329 0x7f9763278b8f ??? /var/tmp/portage/sys-libs/glibc-2.30/work/glibc-2.30/signal/../sysdeps/unix/sysv/linux/x86_64/sigaction.c:0 0x8075ce ipa_call_summary::ipa_call_summary(ipa_call_summary const&) /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-fnsummary.h:253 0x8075ce ipa_call_summary_t::duplicate(cgraph_edge*, cgraph_edge*, ipa_call_summary*, ipa_call_summary*) /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-fnsummary.c:762 0x80cc8f analyze_function_body /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-fnsummary.c:2487 0x80ecf7 compute_fn_summary(cgraph_node*, bool) /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-fnsummary.c:2802 0x833a17 ipa_merge_profiles(cgraph_node*, cgraph_node*, bool) /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-utils.c:668 0x11598b2 ipa_icf::sem_function::merge(ipa_icf::sem_item*) /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-icf.c:1299 0x115dead ipa_icf::sem_item_optimizer::merge_classes(unsigned int) /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-icf.c:3503 0x1162dd7 ipa_icf::sem_item_optimizer::execute() /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-icf.c:2582 0x1164756 ipa_icf_driver /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-icf.c:3667 0x1164756 ipa_icf::pass_ipa_icf::execute(function*) /var/tmp/portage/sys-devel/gcc-10.0.0_pre9999/work/gcc-10.0.0_pre9999/gcc/ipa-icf.c:3714 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <https://bugs.gentoo.org/> for instructions. lto-wrapper: fatal error: x86_64-pc-linux-gnu-gcc returned 1 exit status compilation terminated. [Leaving LTRANS libpython3.7m.so.1.0.ltrans.out] /usr/lib/gcc/x86_64-pc-linux-gnu/10.0.0-pre9999/../../../../x86_64-pc-linux-gnu/bin/ld: error: lto-wrapper failed [Leaving libpython3.7m.so.1.0.lto_wrapper_args] collect2: error: ld returned 1 exit status ln: failed to access 'libpython3.7m.so.1.0': No such file or directory make: *** [Makefile:645: libpython3.7m.so] Error 1