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

            Bug ID: 108543
           Summary: ICE in build_call_expr_loc_array, at tree.cc:10686
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gs...@t-online.de
  Target Milestone: ---

Started with r8 :


$ cat z1.cc
#include <vector>


$ g++-13-20230122 -c z1.cc -fsanitize=address -fno-sanitize=kernel-address
-fsanitize=pointer-subtract
In file included from .../gcc-13-20230122/include/c++/13.0.1/vector:67,
                 from z1.cc:1:
.../gcc-13-20230122/include/c++/13.0.1/bits/stl_bvector.h: In function
'std::ptrdiff_t std::operator-(const _Bit_iterator_base&, const
_Bit_iterator_base&)':
.../gcc-13-20230122/include/c++/13.0.1/bits/stl_bvector.h:269:50: internal
compiler error: Segmentation fault
  269 |       return (int(_S_word_bit) * (__x._M_p - __y._M_p)
      |                                                  ^~~~
0xeb575f crash_signal
        ../../gcc/toplev.cc:314
0x114833e build_call_expr_loc_array(unsigned int, tree_node*, int, tree_node**)
        ../../gcc/tree.cc:10686
0x114842f build_call_expr_loc(unsigned int, tree_node*, int, ...)
        ../../gcc/tree.cc:10719
0x98b393 pointer_diff
        ../../gcc/cp/typeck.cc:6728
0x98b393 cp_build_binary_op(op_location_t const&, tree_code, tree_node*,
tree_node*, int)
        ../../gcc/cp/typeck.cc:5350
0x7c8c8c build_new_op(op_location_t const&, tree_code, int, tree_node*,
tree_node*, tree_node*, tree_node*, tree_node**, int)
        ../../gcc/cp/call.cc:7369
0x97de10 build_x_binary_op(op_location_t const&, tree_code, tree_node*,
tree_code, tree_node*, tree_code, tree_node*, tree_node**, int)
        ../../gcc/cp/typeck.cc:4722
0x8d16e3 cp_parser_binary_expression
        ../../gcc/cp/parser.cc:10283
0x8d1eb4 cp_parser_assignment_expression
        ../../gcc/cp/parser.cc:10444
0x8d35f2 cp_parser_expression
        ../../gcc/cp/parser.cc:10614
0x8e50c1 cp_parser_primary_expression
        ../../gcc/cp/parser.cc:5722
0x8e8a76 cp_parser_postfix_expression
        ../../gcc/cp/parser.cc:7731
0x8fbfff cp_parser_unary_expression
        ../../gcc/cp/parser.cc:9095
0x8d0bff cp_parser_cast_expression
        ../../gcc/cp/parser.cc:9999
0x8d190c cp_parser_simple_cast_expression
        ../../gcc/cp/parser.cc:32523
0x8d190c cp_parser_binary_expression
        ../../gcc/cp/parser.cc:10168
0x8d1eb4 cp_parser_assignment_expression
        ../../gcc/cp/parser.cc:10444
0x8d35f2 cp_parser_expression
        ../../gcc/cp/parser.cc:10614
0x8e50c1 cp_parser_primary_expression
        ../../gcc/cp/parser.cc:5722
0x8e8a76 cp_parser_postfix_expression
        ../../gcc/cp/parser.cc:7731

Reply via email to