https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98072
Bug ID: 98072 Summary: [11 Regression] ICE in cp_parser_omp_var_list_no_open, at cp/parser.c:34843 Product: gcc Version: 11.0 Status: UNCONFIRMED Keywords: ice-on-invalid-code, openmp Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: asolokha at gmx dot com Target Milestone: --- g++-11.0.0-alpha20201129 snapshot (g:bb67ad5cff58a707aaae645d4f45a913d8511c86) ICEs when compiling the following testcase, reduced from test/OpenMP/depobj_ast_print.cpp from the clang 11.0.0 test suite, w/ -fopenmp: void dh (int *vp, int pm, int ca) { #pragma omp depobj (pm) depend (iterator (ca = 0 : *vp), in: vp[ca]) ; } % g++-11.0.0 -fopenmp -c wmttbiko.cpp wmttbiko.cpp: In function 'void dh(int*, int, int)': wmttbiko.cpp:4:65: internal compiler error: in cp_parser_omp_var_list_no_open, at cp/parser.c:34843 4 | #pragma omp depobj (pm) depend (iterator (ca = 0 : *vp), in: vp[ca]) | ^~ 0x9e4b1b cp_parser_omp_var_list_no_open /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:34843 0x9ec406 cp_parser_omp_clause_depend /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:37177 0x9d9540 cp_parser_omp_depobj /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:38787 0x9d9540 cp_parser_pragma /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:44282 0x9dfd68 cp_parser_statement /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:11561 0x9e0aed cp_parser_statement_seq_opt /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:11953 0x9e0bc8 cp_parser_compound_statement /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:11903 0x9fac64 cp_parser_function_body /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:23570 0x9fac64 cp_parser_ctor_initializer_opt_and_function_body /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:23621 0x9ff719 cp_parser_function_definition_after_declarator /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:29511 0xa00ab9 cp_parser_function_definition_from_specifiers_and_declarator /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:29427 0xa00ab9 cp_parser_init_declarator /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:21143 0x9ddaf7 cp_parser_simple_declaration /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:13963 0xa0aaa4 cp_parser_declaration /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:13660 0xa0b450 cp_parser_translation_unit /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:4806 0xa0b450 c_parse_file() /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/cp/parser.c:44630 0xb3082d c_common_parse_file() /var/tmp/portage/sys-devel/gcc-11.0.0_alpha20201129/work/gcc-11-20201129/gcc/c-family/c-opts.c:1198 The failing assert has been introduced in g:c0c7270cc4efd896fe99f8ad5409dbef089a407f.