public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/99861] New: [modules] ICE in hashtab_chk_error
@ 2021-04-01  4:51 alexander.lelyakin at googlemail dot com
  2021-04-01  7:49 ` [Bug c++/99861] " marxin at gcc dot gnu.org
                   ` (14 more replies)
  0 siblings, 15 replies; 16+ messages in thread
From: alexander.lelyakin at googlemail dot com @ 2021-04-01  4:51 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 99861
           Summary: [modules] ICE in hashtab_chk_error
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: alexander.lelyakin at googlemail dot com
  Target Milestone: ---

/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header latch
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header cfenv
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header clocale
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header cmath
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header ciso646
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header unordered_map
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header algorithm
----
hash table checking failed: equal operator returns true for a pair of values
with a different hash value
In file included from /usr/local/include/c++/11.0.1/vector:66,
                 from /usr/local/include/c++/11.0.1/functional:62,
                 from
/usr/local/include/c++/11.0.1/pstl/glue_algorithm_defs.h:13,
                 from /usr/local/include/c++/11.0.1/algorithm:74:
/usr/local/include/c++/11.0.1/bits/stl_uninitialized.h: In static member
function ‘static _ForwardIterator
std::__uninitialized_copy<true>::__uninit_copy(_InputIterator, _InputIterator,
_ForwardIterator)’:
/usr/local/include/c++/11.0.1/bits/stl_uninitialized.h:110:23: internal
compiler error: in hashtab_chk_error, at hash-table.c:137
  110 |         { return std::copy(__first, __last, __result); }
      |                       ^~~~
0x92894b hashtab_chk_error()
        ../../gcc/gcc/hash-table.c:137
0xb35fa5 hash_table<spec_hasher, false, xcallocator>::verify(spec_entry*
const&, unsigned int)
        ../../gcc/gcc/hash-table.h:1033
0xb3652e hash_table<spec_hasher, false,
xcallocator>::find_slot_with_hash(spec_entry* const&, unsigned int,
insert_option)
        ../../gcc/gcc/hash-table.h:968
0xaf315b match_mergeable_specialization(bool, spec_entry*)
        ../../gcc/gcc/cp/pt.c:29942
0xa6cf43 trees_in::key_mergeable(int, merge_kind, tree_node*, tree_node*,
tree_node*, tree_node*, bool)
        ../../gcc/gcc/cp/module.cc:10667
0xa70564 trees_in::decl_value()
        ../../gcc/gcc/cp/module.cc:7899
0xa693c7 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9150
0xa6f9eb module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14797
0xa6feed module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18068
0xa6ffaf module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18726
0xa6a230 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9661
0xa6b046 trees_in::core_vals(tree_node*)
        ../../gcc/gcc/cp/module.cc:6662
0xa68a97 trees_in::tree_node_vals(tree_node*)
        ../../gcc/gcc/cp/module.cc:7057
0xa68a97 trees_in::tree_value()
        ../../gcc/gcc/cp/module.cc:8927
0xa68ecf trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9145
0xa6acd1 trees_in::core_vals(tree_node*)
        ../../gcc/gcc/cp/module.cc:6413
0xa68a97 trees_in::tree_node_vals(tree_node*)
        ../../gcc/gcc/cp/module.cc:7057
0xa68a97 trees_in::tree_value()
        ../../gcc/gcc/cp/module.cc:8927
0xa68ecf trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9145
0xa6acd1 trees_in::core_vals(tree_node*)
        ../../gcc/gcc/cp/module.cc:6413
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
----
g++ (GCC) 11.0.1 20210331 (experimental)
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
@ 2021-04-01  7:49 ` marxin at gcc dot gnu.org
  2021-04-01  7:50 ` marxin at gcc dot gnu.org
                   ` (13 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-04-01  7:49 UTC (permalink / raw)
  To: gcc-bugs

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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |marxin at gcc dot gnu.org

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
...

> /usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header algorithm

I can confirm that, but with:
--param=hash-table-verification-limit=1000

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
  2021-04-01  7:49 ` [Bug c++/99861] " marxin at gcc dot gnu.org
@ 2021-04-01  7:50 ` marxin at gcc dot gnu.org
  2021-04-05 11:20 ` alexander.lelyakin at googlemail dot com
                   ` (12 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-04-01  7:50 UTC (permalink / raw)
  To: gcc-bugs

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

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2021-04-01

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
  2021-04-01  7:49 ` [Bug c++/99861] " marxin at gcc dot gnu.org
  2021-04-01  7:50 ` marxin at gcc dot gnu.org
@ 2021-04-05 11:20 ` alexander.lelyakin at googlemail dot com
  2021-04-09 16:28 ` alexander.lelyakin at googlemail dot com
                   ` (11 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: alexander.lelyakin at googlemail dot com @ 2021-04-05 11:20 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Alexander Lelyakin <alexander.lelyakin at googlemail dot com> ---
There is a shorter sequence:

/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header stdexcept
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header future
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header unordered_map
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header algorithm
----
hash table checking failed: equal operator returns true for a pair of values
with a different hash value
In file included from /usr/local/include/c++/11.0.1/vector:66,
                 from /usr/local/include/c++/11.0.1/functional:62,
                 from
/usr/local/include/c++/11.0.1/pstl/glue_algorithm_defs.h:13,
                 from /usr/local/include/c++/11.0.1/algorithm:74:
/usr/local/include/c++/11.0.1/bits/stl_uninitialized.h: In static member
function ‘static _ForwardIterator
std::__uninitialized_copy<true>::__uninit_copy(_InputIterator, _InputIterator,
_ForwardIterator)’:
/usr/local/include/c++/11.0.1/bits/stl_uninitialized.h:110:23: internal
compiler error: in hashtab_chk_error, at hash-table.c:137
  110 |         { return std::copy(__first, __last, __result); }
      |                       ^~~~
0x92db09 hashtab_chk_error()
        ../../gcc/gcc/hash-table.c:137
0xb3c135 hash_table<spec_hasher, false, xcallocator>::verify(spec_entry*
const&, unsigned int)
        ../../gcc/gcc/hash-table.h:1033
0xb3c6be hash_table<spec_hasher, false,
xcallocator>::find_slot_with_hash(spec_entry* const&, unsigned int,
insert_option)
        ../../gcc/gcc/hash-table.h:968
0xaf957b match_mergeable_specialization(bool, spec_entry*)
        ../../gcc/gcc/cp/pt.c:29908
0xa72a58 trees_in::key_mergeable(int, merge_kind, tree_node*, tree_node*,
tree_node*, tree_node*, bool)
        ../../gcc/gcc/cp/module.cc:10670
0xa76654 trees_in::decl_value()
        ../../gcc/gcc/cp/module.cc:7903
0xa6f4b7 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9153
0xa75adb module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14811
0xa75fdd module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7609f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa70320 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa757db module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa75fdd module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7609f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa70320 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa757db module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa75fdd module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7609f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa70320 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa757db module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
----
g++ (GCC) 11.0.1 20210405 (experimental)
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (2 preceding siblings ...)
  2021-04-05 11:20 ` alexander.lelyakin at googlemail dot com
@ 2021-04-09 16:28 ` alexander.lelyakin at googlemail dot com
  2021-04-15 17:15 ` alexander.lelyakin at googlemail dot com
                   ` (10 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: alexander.lelyakin at googlemail dot com @ 2021-04-09 16:28 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Alexander Lelyakin <alexander.lelyakin at googlemail dot com> ---
There is a shorter sequence:

/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header map
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header clocale
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header regex
----
hash table checking failed: equal operator returns true for a pair of values
with a different hash value
In file included from /usr/local/include/c++/11.0.1/bits/unique_ptr.h:42,
                 from /usr/local/include/c++/11.0.1/bits/locale_conv.h:41,
                 from /usr/local/include/c++/11.0.1/locale:43,
                 from /usr/local/include/c++/11.0.1/regex:44:
/usr/local/include/c++/11.0.1/ostream: In substitution of ‘template<class
_Ostream, class _Tp> typename
std::enable_if<std::__and_<std::__not_<std::is_lvalue_reference<_Tp> >,
std::__is_convertible_to_basic_ostream<_Ostream>, std::__is_insertable<typename
std::__is_convertible_to_basic_ostream<_Tp>::__ostream_type, const _Tp&, void>
>::value, typename
std::__is_convertible_to_basic_ostream<_Tp>::__ostream_type>::type
std::operator<<(_Ostream&&, const _Tp&) [with _Ostream = int; _Tp =
std::regex_constants::__syntax_option]’:
/usr/local/include/c++/11.0.1/bits/regex_constants.h:88:42:   required from
here
/usr/local/include/c++/11.0.1/ostream:773:5: internal compiler error: in
hashtab_chk_error, at hash-table.c:137
  773 |     operator<<(_Ostream&& __os, const _Tp& __x)
      |     ^~~~~~~~
0x92f047 hashtab_chk_error()
        ../../gcc/gcc/hash-table.c:137
0xb3ddf5 hash_table<spec_hasher, false, xcallocator>::verify(spec_entry*
const&, unsigned int)
        ../../gcc/gcc/hash-table.h:1033
0xb3e37e hash_table<spec_hasher, false,
xcallocator>::find_slot_with_hash(spec_entry* const&, unsigned int,
insert_option)
        ../../gcc/gcc/hash-table.h:968
0xafb10b match_mergeable_specialization(bool, spec_entry*)
        ../../gcc/gcc/cp/pt.c:29961
0xa74528 trees_in::key_mergeable(int, merge_kind, tree_node*, tree_node*,
tree_node*, tree_node*, bool)
        ../../gcc/gcc/cp/module.cc:10670
0xa78124 trees_in::decl_value()
        ../../gcc/gcc/cp/module.cc:7903
0xa70f87 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9153
0xa70ef9 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9203
0xa7182d trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9346
0xa72987 trees_in::core_vals(tree_node*)
        ../../gcc/gcc/cp/module.cc:6537
0xa781f9 trees_in::tree_node_vals(tree_node*)
        ../../gcc/gcc/cp/module.cc:7061
0xa781f9 trees_in::decl_value()
        ../../gcc/gcc/cp/module.cc:7942
0xa70f87 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9153
0xa775ab module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14811
0xa77aad module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa77b6f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa71df0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa772ab module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa77aad module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa77b6f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
----
g++ (GCC) 11.0.1 20210409 (experimental)
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (3 preceding siblings ...)
  2021-04-09 16:28 ` alexander.lelyakin at googlemail dot com
@ 2021-04-15 17:15 ` alexander.lelyakin at googlemail dot com
  2021-04-16  7:19 ` marxin at gcc dot gnu.org
                   ` (9 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: alexander.lelyakin at googlemail dot com @ 2021-04-15 17:15 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Alexander Lelyakin <alexander.lelyakin at googlemail dot com> ---
After every few commits one sequence stops to reproduce this error, but some
another appears.

See current status here: http://lelyakin.de/modules/in%20hashtab_chk_error/

Today shortest sequence is:

/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header cerrno
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header unordered_map
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header cstring
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header stdexcept
/usr/local/bin/g++ -std=c++20 -fmodules-ts -x c++-system-header algorithm
----
hash table checking failed: equal operator returns true for a pair of values
with a different hash value
In file included from /usr/local/include/c++/11.0.1/vector:66,
                 from /usr/local/include/c++/11.0.1/functional:62,
                 from
/usr/local/include/c++/11.0.1/pstl/glue_algorithm_defs.h:13,
                 from /usr/local/include/c++/11.0.1/algorithm:74:
/usr/local/include/c++/11.0.1/bits/stl_uninitialized.h: In static member
function ‘static _ForwardIterator
std::__uninitialized_copy<true>::__uninit_copy(_InputIterator, _InputIterator,
_ForwardIterator)’:
/usr/local/include/c++/11.0.1/bits/stl_uninitialized.h:110:23: internal
compiler error: in hashtab_chk_error, at hash-table.c:137
  110 |         { return std::copy(__first, __last, __result); }
      |                       ^~~~
0x92f4b5 hashtab_chk_error()
        ../../gcc/gcc/hash-table.c:137
0xb3e835 hash_table<spec_hasher, false, xcallocator>::verify(spec_entry*
const&, unsigned int)
        ../../gcc/gcc/hash-table.h:1033
0xb3edbe hash_table<spec_hasher, false,
xcallocator>::find_slot_with_hash(spec_entry* const&, unsigned int,
insert_option)
        ../../gcc/gcc/hash-table.h:968
0xafba1b match_mergeable_specialization(bool, spec_entry*)
        ../../gcc/gcc/cp/pt.c:30000
0xa74b08 trees_in::key_mergeable(int, merge_kind, tree_node*, tree_node*,
tree_node*, tree_node*, bool)
        ../../gcc/gcc/cp/module.cc:10670
0xa78704 trees_in::decl_value()
        ../../gcc/gcc/cp/module.cc:7903
0xa71567 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9153
0xa77b8b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14811
0xa7808d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7814f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa723d0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa7788b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa7808d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7814f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa723d0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa7788b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa7808d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7814f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa723d0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa7788b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
----
g++ (GCC) 11.0.1 20210415 (experimental)
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (4 preceding siblings ...)
  2021-04-15 17:15 ` alexander.lelyakin at googlemail dot com
@ 2021-04-16  7:19 ` marxin at gcc dot gnu.org
  2021-04-16 11:44 ` alexander.lelyakin at googlemail dot com
                   ` (8 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-04-16  7:19 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #5 from Martin Liška <marxin at gcc dot gnu.org> ---
You can experiment with something like this:
--param=hash-table-verification-limit=10000000

which will run hash table verification for more elements.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (5 preceding siblings ...)
  2021-04-16  7:19 ` marxin at gcc dot gnu.org
@ 2021-04-16 11:44 ` alexander.lelyakin at googlemail dot com
  2021-04-16 11:52 ` marxin at gcc dot gnu.org
                   ` (7 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: alexander.lelyakin at googlemail dot com @ 2021-04-16 11:44 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #6 from Alexander Lelyakin <alexander.lelyakin at googlemail dot com> ---
And where this parameter should be specified?
At configure?

Here the compiler was built with almost default parameters:
 configure --enable-languages=c++ --disable-multilib

Anyway at every commit it is possible to find sequences producing this error.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (6 preceding siblings ...)
  2021-04-16 11:44 ` alexander.lelyakin at googlemail dot com
@ 2021-04-16 11:52 ` marxin at gcc dot gnu.org
  2021-04-16 12:35 ` alexander.lelyakin at googlemail dot com
                   ` (6 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-04-16 11:52 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #7 from Martin Liška <marxin at gcc dot gnu.org> ---
(In reply to Alexander Lelyakin from comment #6)
> And where this parameter should be specified?
> At configure?

No, it's a compiler option.

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (7 preceding siblings ...)
  2021-04-16 11:52 ` marxin at gcc dot gnu.org
@ 2021-04-16 12:35 ` alexander.lelyakin at googlemail dot com
  2021-04-16 13:05 ` alexander.lelyakin at googlemail dot com
                   ` (5 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: alexander.lelyakin at googlemail dot com @ 2021-04-16 12:35 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #8 from Alexander Lelyakin <alexander.lelyakin at googlemail dot com> ---
Interesting: There is a pair of system headers
 <condition_variable> and <future> 
Almost any sequence of system headers having condition_variable and ending at
future will produce Segmentation fault

With parameter --param=hash-table-verification-limit=10000000
this pair produces hashtab_chk_error instead of Segmentation fault.

So probably for some or all or most of sequences producing "Segmentation fault"
the reason in somewhere in hashtab?
----
/usr/local/bin/g++ --param=hash-table-verification-limit=10000000 -std=c++20
-fmodules-ts -x c++-system-header condition_variable
/usr/local/bin/g++ --param=hash-table-verification-limit=10000000 -std=c++20
-fmodules-ts -x c++-system-header future
----
hash table checking failed: equal operator returns true for a pair of values
with a different hash value
In file included from /usr/local/include/c++/11.0.1/future:43:
/usr/local/include/c++/11.0.1/bits/atomic_futex.h:77:5: internal compiler
error: in hashtab_chk_error, at hash-table.c:137
   77 |     atomic<unsigned> _M_data;
      |     ^~~~~~
0x92f671 hashtab_chk_error()
        ../../gcc/gcc/hash-table.c:137
0xb3ec35 hash_table<spec_hasher, false, xcallocator>::verify(spec_entry*
const&, unsigned int)
        ../../gcc/gcc/hash-table.h:1033
0xb3f1be hash_table<spec_hasher, false,
xcallocator>::find_slot_with_hash(spec_entry* const&, unsigned int,
insert_option)
        ../../gcc/gcc/hash-table.h:968
0xafbd2b match_mergeable_specialization(bool, spec_entry*)
        ../../gcc/gcc/cp/pt.c:30034
0xa74e18 trees_in::key_mergeable(int, merge_kind, tree_node*, tree_node*,
tree_node*, tree_node*, bool)
        ../../gcc/gcc/cp/module.cc:10670
0xa78a14 trees_in::decl_value()
        ../../gcc/gcc/cp/module.cc:7903
0xa71877 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9153
0xa77e9b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14811
0xa7839d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7845f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa726e0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa77b9b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa7839d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7845f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa726e0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa77b9b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa7839d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa78558 lazy_load_binding(unsigned int, tree_node*, tree_node*, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18773
0xa8a17e name_lookup::search_namespace_only(tree_node*)
        ../../gcc/gcc/cp/name-lookup.c:928
0xa8b7cb name_lookup::search_unqualified(tree_node*, cp_binding_level*)
        ../../gcc/gcc/cp/name-lookup.c:1158
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
----
At commit: 784de5292c34e287c848b382b431599b818ea76e

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (8 preceding siblings ...)
  2021-04-16 12:35 ` alexander.lelyakin at googlemail dot com
@ 2021-04-16 13:05 ` alexander.lelyakin at googlemail dot com
  2021-12-30 16:11 ` pinskia at gcc dot gnu.org
                   ` (4 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: alexander.lelyakin at googlemail dot com @ 2021-04-16 13:05 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #9 from Alexander Lelyakin <alexander.lelyakin at googlemail dot com> ---
The same happens with the ICE in add_mergeable_specialization, PR99948,
http://lelyakin.de/modules/in%20add_mergeable_specialization/016_7ae8737cc3d793d796faedfe5de5d89d42b966b5/

After adding parameter --param=hash-table-verification-limit=1000
the error was transformed to:

hash table checking failed: equal operator returns true for a pair of values
with a different hash value
In file included from /usr/local/include/c++/11.0.1/memory:68,
                 from /usr/local/include/c++/11.0.1/regex:45:
/usr/local/include/c++/11.0.1/bits/stl_raw_storage_iter.h: In destructor
‘constexpr std::allocator< <template-parameter-1-1> >::~allocator() [with _Tp =
char32_t]’:
/usr/local/include/c++/11.0.1/bits/stl_raw_storage_iter.h:95:58: internal
compiler error: in hashtab_chk_error, at hash-table.c:137
   95 |         std::_Construct(std::__addressof(*_M_iter),
std::move(__element));
      |                                                          ^~~~
0x92f671 hashtab_chk_error()
        ../../gcc/gcc/hash-table.c:137
0xb3ec35 hash_table<spec_hasher, false, xcallocator>::verify(spec_entry*
const&, unsigned int)
        ../../gcc/gcc/hash-table.h:1033
0xb3f1be hash_table<spec_hasher, false,
xcallocator>::find_slot_with_hash(spec_entry* const&, unsigned int,
insert_option)
        ../../gcc/gcc/hash-table.h:968
0xafbd2b match_mergeable_specialization(bool, spec_entry*)
        ../../gcc/gcc/cp/pt.c:30034
0xa74e18 trees_in::key_mergeable(int, merge_kind, tree_node*, tree_node*,
tree_node*, tree_node*, bool)
        ../../gcc/gcc/cp/module.cc:10670
0xa78a14 trees_in::decl_value()
        ../../gcc/gcc/cp/module.cc:7903
0xa71877 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9153
0xa77e9b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14811
0xa7839d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7845f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa726e0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa77b9b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa7839d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7845f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa726e0 trees_in::tree_node(bool)
        ../../gcc/gcc/cp/module.cc:9664
0xa77b9b module_state::read_cluster(unsigned int)
        ../../gcc/gcc/cp/module.cc:14717
0xa7839d module_state::load_section(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18082
0xa7845f module_state::lazy_load(unsigned int, binding_slot*)
        ../../gcc/gcc/cp/module.cc:18740
0xa7b5b7 lazy_load_pendings(tree_node*)
        ../../gcc/gcc/cp/module.cc:18833
0xa83d58 maybe_lazily_declare
        ../../gcc/gcc/cp/name-lookup.c:1912
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

However this parameter significantly slows compilation.

And already two weeks this report remains unassigned...

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (9 preceding siblings ...)
  2021-04-16 13:05 ` alexander.lelyakin at googlemail dot com
@ 2021-12-30 16:11 ` pinskia at gcc dot gnu.org
  2021-12-30 16:12 ` pinskia at gcc dot gnu.org
                   ` (3 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-12-30 16:11 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99861
Bug 99861 depends on bug 100052, which changed state.

Bug 100052 Summary: [11/12 regression] ICE in compiling g++.dg/modules/xtreme-header-3_b.C after r11-8118
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100052

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |DUPLICATE

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (10 preceding siblings ...)
  2021-12-30 16:11 ` pinskia at gcc dot gnu.org
@ 2021-12-30 16:12 ` pinskia at gcc dot gnu.org
  2021-12-30 16:18 ` pinskia at gcc dot gnu.org
                   ` (2 subsequent siblings)
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-12-30 16:12 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |DUPLICATE
             Status|NEW                         |RESOLVED

--- Comment #10 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Dup of bug 99479.

*** This bug has been marked as a duplicate of bug 99479 ***

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (11 preceding siblings ...)
  2021-12-30 16:12 ` pinskia at gcc dot gnu.org
@ 2021-12-30 16:18 ` pinskia at gcc dot gnu.org
  2021-12-30 16:20 ` pinskia at gcc dot gnu.org
  2022-01-01  4:19 ` pinskia at gcc dot gnu.org
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-12-30 16:18 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #11 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
This is actually a dup of bug 103769.

*** This bug has been marked as a duplicate of bug 103769 ***

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (12 preceding siblings ...)
  2021-12-30 16:18 ` pinskia at gcc dot gnu.org
@ 2021-12-30 16:20 ` pinskia at gcc dot gnu.org
  2022-01-01  4:19 ` pinskia at gcc dot gnu.org
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-12-30 16:20 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99861
Bug 99861 depends on bug 100052, which changed state.

Bug 100052 Summary: [11/12 regression] ICE in compiling g++.dg/modules/xtreme-header-3_b.C after r11-8118
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100052

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |NEW
         Resolution|DUPLICATE                   |---

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [Bug c++/99861] [modules] ICE in hashtab_chk_error
  2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
                   ` (13 preceding siblings ...)
  2021-12-30 16:20 ` pinskia at gcc dot gnu.org
@ 2022-01-01  4:19 ` pinskia at gcc dot gnu.org
  14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-01-01  4:19 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99861
Bug 99861 depends on bug 100002, which changed state.

Bug 100002 Summary: internal compiler error: in hashtab_chk_error, at hash-table.c:137
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100002

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |DUPLICATE

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2022-01-01  4:19 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-01  4:51 [Bug c++/99861] New: [modules] ICE in hashtab_chk_error alexander.lelyakin at googlemail dot com
2021-04-01  7:49 ` [Bug c++/99861] " marxin at gcc dot gnu.org
2021-04-01  7:50 ` marxin at gcc dot gnu.org
2021-04-05 11:20 ` alexander.lelyakin at googlemail dot com
2021-04-09 16:28 ` alexander.lelyakin at googlemail dot com
2021-04-15 17:15 ` alexander.lelyakin at googlemail dot com
2021-04-16  7:19 ` marxin at gcc dot gnu.org
2021-04-16 11:44 ` alexander.lelyakin at googlemail dot com
2021-04-16 11:52 ` marxin at gcc dot gnu.org
2021-04-16 12:35 ` alexander.lelyakin at googlemail dot com
2021-04-16 13:05 ` alexander.lelyakin at googlemail dot com
2021-12-30 16:11 ` pinskia at gcc dot gnu.org
2021-12-30 16:12 ` pinskia at gcc dot gnu.org
2021-12-30 16:18 ` pinskia at gcc dot gnu.org
2021-12-30 16:20 ` pinskia at gcc dot gnu.org
2022-01-01  4:19 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).