https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93465
Bug ID: 93465 Summary: [10 Regression] ICE in oacc_verify_routine_clauses, at omp-general.c:1802 Product: gcc Version: 10.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: gs...@t-online.de Target Milestone: --- Changed between 20190512 and 20190519, rejects C variant : $ cat z0.c #pragma omp declare target #include <openacc.h> $ cat z1.cc #pragma omp declare target #include <openacc.h> $ gcc-10-20200126 -c z0.c -fopenmp -fopenacc z0.c:3: error: '#pragma omp declare target' without corresponding '#pragma omp end declare target' $ g++-10-20190512 -c z1.cc -fopenmp -fopenacc $ $ g++-10-20200126 -c z1.cc -fopenmp -fopenacc In file included from z1.cc:2: .../lib64/gcc/x86_64-pc-linux-gnu/10.0.1/include/openacc.h: In function 'int acc_on_device(acc_device_t)': .../lib64/gcc/x86_64-pc-linux-gnu/10.0.1/include/openacc.h:162:1: internal compiler error: Segmentation fault 162 | { | ^ 0xc3085f crash_signal ../../gcc/toplev.c:328 0xb17d41 oacc_verify_routine_clauses(tree_node*, tree_node**, unsigned int, char const*) ../../gcc/omp-general.c:1802 0x6e2732 cp_finalize_oacc_routine ../../gcc/cp/parser.c:42750 0x718bdc cp_parser_function_definition_from_specifiers_and_declarator ../../gcc/cp/parser.c:28734 0x718bdc cp_parser_init_declarator ../../gcc/cp/parser.c:20590 0x6fc6ee cp_parser_simple_declaration ../../gcc/cp/parser.c:13669 0x71f6d9 cp_parser_declaration ../../gcc/cp/parser.c:13368 0x6f786a cp_parser_oacc_routine ../../gcc/cp/parser.c:42669 0x6f786a cp_parser_pragma ../../gcc/cp/parser.c:43459 0x71fe51 cp_parser_translation_unit ../../gcc/cp/parser.c:4731 0x71fe51 c_parse_file() ../../gcc/cp/parser.c:43675 0x7e2560 c_common_parse_file() ../../gcc/c-family/c-opts.c:1186