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

            Bug ID: 92552
           Summary: [10 Regression] internal compiler error: in
                    lazily_declare_fn, at cp/method.c:3045 with -fconcepts
           Product: gcc
           Version: 10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gcc-bugs at marehr dot dialup.fu-berlin.de
  Target Milestone: ---

Created attachment 47287
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=47287&action=edit
ice.cpp

Hi gcc-team,

The patch from https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91930 didn't
resolve this ice for me.

I tried to reduce the problem, but I'm stuck at the current version maybe
someone else can continue the help with the reduction.

```
> /usr/local/bin/g++-git  -std=c++17 -fconcepts  -c ice.cpp

ice.cpp: In instantiation of ‘g<view, simd>::iter::iter(g<view, simd>) [with
view = std::span<std::vector<int>, -1>; simd = unsigned int; g<view, simd> =
g<std::span<std::vector<int>, -1>, unsigned int>]’:
ice.cpp:184:26:   required from ‘g<view, simd>::iter g<view, simd>::begin()
[with view = std::span<std::vector<int>, -1>; simd = unsigned int]’
ice.cpp:63:21:   required from ‘constexpr auto
ranges::_begin_::fn::impl_<<anonymous> >::operator()(R&&) const [with R =
g<std::span<std::vector<int>, -1>, unsigned int>&; bool <anonymous> = true]’
ice.cpp:71:21:   required from ‘constexpr auto
ranges::_begin_::fn::operator()(R&&) const [with R =
g<std::span<std::vector<int>, -1>, unsigned int>&]’
ice.cpp:74:47:   required by substitution of ‘template<class R> using _t =
decltype (ranges::_begin_::fn{}(declval<R>())) [with R =
g<std::span<std::vector<int>, -1>, unsigned int>&]’
ice.cpp:80:10:   required from here
ice.cpp:10:50: internal compiler error: in lazily_declare_fn, at
cp/method.c:3045
   10 | template <typename T> concept bool semiregular = __is_constructible(T);
      |                                                  ^~~~~~~~~~~~~~~~~~~~~
0x5de62d lazily_declare_fn(special_function_kind, tree_node*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:3045
0x6cec2c get_class_binding(tree_node*, tree_node*, bool)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/name-lookup.c:1285
0x7598b6 lookup_field_r
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:993
0x75a1db dfs_walk_all(tree_node*, tree_node* (*)(tree_node*, void*), tree_node*
(*)(tree_node*, void*), void*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:1433
0x75a1db lookup_member(tree_node*, tree_node*, int, bool, int,
access_failure_info*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:1147
0x75a673 lookup_fnfields(tree_node*, tree_node*, int)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:1352
0x6c7b4d locate_fn_flags
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:1600
0x6c7ec1 synthesized_method_base_walk
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:2080
0x6c8860 synthesized_method_walk
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:2246
0x6c9b79 implicitly_declare_fn(special_function_kind, tree_node*, bool,
tree_node*, tree_node*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:2677
0x6c9f23 lazily_declare_fn(special_function_kind, tree_node*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:3017
0x6cec2c get_class_binding(tree_node*, tree_node*, bool)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/name-lookup.c:1285
0x7598b6 lookup_field_r
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:993
0x75a1db dfs_walk_all(tree_node*, tree_node* (*)(tree_node*, void*), tree_node*
(*)(tree_node*, void*), void*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:1433
0x75a1db lookup_member(tree_node*, tree_node*, int, bool, int,
access_failure_info*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:1147
0x75a673 lookup_fnfields(tree_node*, tree_node*, int)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/search.c:1352
0x63307f build_special_member_call(tree_node*, tree_node*, vec<tree_node*,
va_gc, vl_embed>**, tree_node*, int, int)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/call.c:9672
0x6cad77 constructible_expr
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:1733
0x6cb013 is_xible_helper
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:1783
0x6cb013 is_xible(tree_code, tree_node*, tree_node*)
        /home/marehr/Packages/gcc-git/src/gcc/gcc/cp/method.c:1810
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://bugs.archlinux.org/> for instructions.
```

```
> g++-git -v
Using built-in specs.
COLLECT_GCC=g++-git
COLLECT_LTO_WRAPPER=/opt/gcc/gcc-git/bin/../lib/gcc/x86_64-pc-linux-gnu/10.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /home/marehr/Packages/gcc-git/src/gcc/configure --prefix=/usr
--libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man
--infodir=/usr/share/info --with-bugurl=https://bugs.archlinux.org/
--enable-languages=c,c++ --enable-shared --enable-threads=posix
--with-system-zlib --with-isl --enable-__cxa_atexit
--disable-libunwind-exceptions --enable-clocale=gnu --disable-libstdcxx-pch
--disable-libssp --enable-gnu-unique-object --enable-linker-build-id
--enable-lto --enable-plugin --enable-install-libiberty
--with-linker-hash-style=gnu --enable-gnu-indirect-function --enable-multilib
--disable-werror --enable-checking=release --enable-default-pie
--enable-default-ssp --enable-cet=auto --disable-boostrap
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 10.0.0 20191116 (experimental) (GCC)
```

Thank you!

Reply via email to