public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/95192] New: [11 Regression] ICE: tree check: expected tree_list, have error_mark in handle_assume_aligned_attribute, at c-family/c-attribs.c:2996
@ 2020-05-18 19:57 asolokha at gmx dot com
  2020-05-18 20:03 ` [Bug c++/95192] " mpolacek at gcc dot gnu.org
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: asolokha at gmx dot com @ 2020-05-18 19:57 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 95192
           Summary: [11 Regression] ICE: tree check: expected tree_list,
                    have error_mark in handle_assume_aligned_attribute, at
                    c-family/c-attribs.c:2996
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Keywords: ice-on-invalid-code
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: asolokha at gmx dot com
  Target Milestone: ---

gcc-11.0.0-alpha20200517 snapshot (g:2b9a271b2d0ba340234a138b7f8289bd7dca2fc5)
ICEs when compiling the following testcase, extracted from
test/SemaCXX/builtin-assume-aligned-tmpl.cpp from the clang 10.0.0 test suite:

template<typename T> __attribute__((assume_aligned(sizeof(int(T()))))) T *f();
void test21() {
  void *p = f<void>()
}

% g++-11.0.0 -c iu1wkpbg.cpp
iu1wkpbg.cpp: In substitution of 'template<class T> T* f() [with T = void]':
iu1wkpbg.cpp:3:21:   required from here
iu1wkpbg.cpp:1:75: internal compiler error: tree check: expected tree_list,
have error_mark in handle_assume_aligned_attribute, at
c-family/c-attribs.c:2996
    1 | template<typename T> __attribute__((assume_aligned(sizeof(int(T())))))
T *f();
      |                                                                        
  ^
0x7c0c50 tree_check_failed(tree_node const*, char const*, int, char const*,
...)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/tree.c:9686
0x6af9db tree_check(tree_node*, char const*, int, char const*, tree_code)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/tree.h:3296
0x6af9db handle_assume_aligned_attribute
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/c-family/c-attribs.c:2996
0x6af9db handle_assume_aligned_attribute
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/c-family/c-attribs.c:2977
0xa96507 decl_attributes(tree_node**, tree_node*, int, tree_node*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/attribs.c:714
0x9236f7 cplus_decl_attributes(tree_node**, tree_node*, int)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/decl2.c:1598
0xa178f4 tsubst_function_decl
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/pt.c:13929
0xa0196f tsubst_decl
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/pt.c:14182
0xa11b19 instantiate_template_1
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/pt.c:20678
0xa2137c instantiate_template(tree_node*, tree_node*, int)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/pt.c:20735
0xa2137c fn_type_unification(tree_node*, tree_node*, tree_node*, tree_node*
const*, unsigned int, tree_node*, unification_kind_t, int, conversion**, bool,
bool)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/pt.c:21179
0x876223 add_template_candidate_real
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/call.c:3415
0x876cf6 add_template_candidate
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/call.c:3500
0x876cf6 add_candidates
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/call.c:5866
0x8771e7 add_candidates
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/call.c:4522
0x8771e7 perform_overload_resolution
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/call.c:4530
0x87eea5 build_new_function_call(tree_node*, vec<tree_node*, va_gc,
vl_embed>**, int)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/call.c:4604
0xa3d1b4 finish_call_expr(tree_node*, vec<tree_node*, va_gc, vl_embed>**, bool,
bool, int)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/semantics.c:2675
0x9b3e51 cp_parser_postfix_expression
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/parser.c:7465
0x9958e9 cp_parser_binary_expression
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200517/work/gcc-11-20200517/gcc/cp/parser.c:9559

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

end of thread, other threads:[~2021-02-04  2:40 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-18 19:57 [Bug c++/95192] New: [11 Regression] ICE: tree check: expected tree_list, have error_mark in handle_assume_aligned_attribute, at c-family/c-attribs.c:2996 asolokha at gmx dot com
2020-05-18 20:03 ` [Bug c++/95192] " mpolacek at gcc dot gnu.org
2020-05-19  6:41 ` rguenth at gcc dot gnu.org
2020-10-16 11:45 ` rguenth at gcc dot gnu.org
2020-11-18 14:59 ` jakub at gcc dot gnu.org
2020-12-04 14:17 ` marxin at gcc dot gnu.org
2020-12-04 14:20 ` jakub at gcc dot gnu.org
2021-02-01 21:46 ` jason at gcc dot gnu.org
2021-02-04  2:38 ` cvs-commit at gcc dot gnu.org
2021-02-04  2:40 ` jason 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).