https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114912
Bug ID: 114912 Summary: [15 regression] SIGBUS in wi::copy<> on SPARC Product: gcc Version: 15.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: middle-end Assignee: unassigned at gcc dot gnu.org Reporter: ro at gcc dot gnu.org CC: aldyh at gcc dot gnu.org Target Milestone: --- Target: sparc-sun-solaris2.11 Between 20240430 (0b2735e0797fee9b4ec5cd74f22afe0483f888dd) and 20240501 (c3bc2787b8beb7aae67fdf2a7f7271a9a4edca7c), Solaris/SPARC bootstrap began to fail with a SIGBUS in cc1 compiling stage 1 libgcc. E.g. /var/gcc/reghunt/sigbus-range/288807/./gcc/xgcc -B/var/gcc/reghunt/sigbus-range/288807/./gcc/ -B/usr/local/sparc-sun-solaris2.11/bin/ -B/usr/local/sparc-sun-solaris2.11/lib/ -isystem /usr/local/sparc-sun-solaris2.11/include -isystem /usr/local/sparc-sun-solaris2.11/sys-include -g -O2 -O2 -g -O2 -DIN_GCC -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -fPIC -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector -fPIC -I. -I. -I../.././gcc -I/var/gcc/reghunt/master/libgcc -I/var/gcc/reghunt/master/libgcc/. -I/var/gcc/reghunt/master/libgcc/../gcc -I/var/gcc/reghunt/master/libgcc/../include -o _muldi3.o -MT _muldi3.o -MD -MP -MF _muldi3.dep -DL_muldi3 -c /var/gcc/reghunt/master/libgcc/libgcc2.c -fvisibility=hidden -DHIDE_EXPORTS during GIMPLE pass: evrp /var/gcc/reghunt/master/libgcc/libgcc2.c: In function ‘__muldi3’: /var/gcc/reghunt/master/libgcc/libgcc2.c:538:1: internal compiler error: Bus Error 538 | } | ^ 0xf26783 crash_signal /var/gcc/reghunt/master/gcc/toplev.cc:319 0x723e58 void wi::copy<wide_int_storage, generic_wide_int<wide_int_ref_storage<true, false> > >(wide_int_storage&, generic_wide_int<wide_int_ref_storage<true, false> > const&) /var/gcc/reghunt/master/gcc/wide-int.h:2191 0x723e58 wide_int_storage& wide_int_storage::operator=<wi::hwi_with_prec>(wi::hwi_with_prec const&) /var/gcc/reghunt/master/gcc/wide-int.h:1247 0x723e58 generic_wide_int<wide_int_storage>& generic_wide_int<wide_int_storage>::operator=<wi::hwi_with_prec>(wi::hwi_with_prec const&) /var/gcc/reghunt/master/gcc/wide-int.h:1002 0x723e58 irange_bitmask::set_unknown(unsigned int) /var/gcc/reghunt/master/gcc/value-range.h:163 0x723e58 irange::set_varying(tree_node*) /var/gcc/reghunt/master/gcc/value-range.h:1067 0x13680db gimple_range_global(vrange&, tree_node*, function*) /var/gcc/reghunt/master/gcc/value-query.cc:419 0x136954f global_range_query::range_of_expr(vrange&, tree_node*, gimple*) /var/gcc/reghunt/master/gcc/value-query.cc:436 0x1ad000b fur_stmt::get_operand(vrange&, tree_node*) /var/gcc/reghunt/master/gcc/gimple-range-fold.cc:162 0x1ad5edb fold_using_range::range_of_range_op(vrange&, gimple_range_op_handler&, fur_source&) /var/gcc/reghunt/master/gcc/gimple-range-fold.cc:673 0x1ad831f fold_using_range::fold_stmt(vrange&, gimple*, fur_source&, tree_node*) /var/gcc/reghunt/master/gcc/gimple-range-fold.cc:604 0x1ad8927 fold_range(vrange&, gimple*, range_query*) /var/gcc/reghunt/master/gcc/gimple-range-fold.cc:324 0x1ac8727 ranger_cache::get_global_range(vrange&, tree_node*, bool&) /var/gcc/reghunt/master/gcc/gimple-range-cache.cc:1054 0x1abefaf gimple_ranger::range_of_stmt(vrange&, gimple*, tree_node*) /var/gcc/reghunt/master/gcc/gimple-range.cc:323 0x1367d2f range_query::value_of_stmt(gimple*, tree_node*) /var/gcc/reghunt/master/gcc/value-query.cc:133 0x1315c3f rvrp_folder::value_of_stmt(gimple*, tree_node*) /var/gcc/reghunt/master/gcc/tree-vrp.cc:1001 0x11ab12f substitute_and_fold_dom_walker::before_dom_children(basic_block_def*) /var/gcc/reghunt/master/gcc/tree-ssa-propagate.cc:820 0x1a4df83 dom_walker::walk(basic_block_def*) /var/gcc/reghunt/master/gcc/domwalk.cc:311 0x11a9d07 substitute_and_fold_engine::substitute_and_fold(basic_block_def*) /var/gcc/reghunt/master/gcc/tree-ssa-propagate.cc:999 0x13132f7 execute_ranger_vrp(function*, bool, bool) /var/gcc/reghunt/master/gcc/tree-vrp.cc:1066 A reghunt identified commit c60b3e211c555706cdc2dc8bfcdd540152cff350 Author: Aldy Hernandez <al...@redhat.com> Date: Tue Apr 30 19:39:00 2024 +0200 Reduce startup costs for Value_Range. as the culprit.