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

--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Sandra Loosemore <san...@gcc.gnu.org>:

https://gcc.gnu.org/g:4e20914d3306d8898ce586313a40fb92ef0b8964

commit r15-6961-g4e20914d3306d8898ce586313a40fb92ef0b8964
Author: Sandra Loosemore <sloosem...@baylibre.com>
Date:   Tue Jan 14 23:27:53 2025 +0000

    OpenMP: Add C support for metadirectives and dynamic selectors.

    Additional shared C/C++ testcases are included in a subsequent patch in
this
    series.

    gcc/c-family/ChangeLog
            PR middle-end/112779
            PR middle-end/113904
            * c-common.h (enum c_omp_directive_kind): Add C_OMP_DIR_META.
            (c_omp_expand_variant_construct): Declare.
            * c-gimplify.cc: Include omp-general.h.
            (genericize_omp_metadirective_stmt): New.
            (c_genericize_control_stmt): Add case for OMP_METADIRECTIVE.
            * c-omp.cc (c_omp_directives): Fix entries for metadirective.
            (c_omp_expand_variant_construct_r): New.
            (c_omp_expand_variant_construct): New.
            * c-pragma.cc (omp_pragmas): Add metadirective.
            * c-pragma.h (enum pragma_kind): Add PRAGMA_OMP_METADIRECTIVE.

    gcc/c/ChangeLog
            PR middle-end/112779
            PR middle-end/113904
            * c-parser.cc (struct c_parser): Add omp_metadirective_state field.
            (c_parser_skip_to_end_of_block_or_statement): Add metadirective_p
            parameter and handle skipping over the parentheses in a "for"
            statement.
            (struct omp_metadirective_parse_data): New.
            (mangle_metadirective_region_label): New.
            (c_parser_label): Mangle label names in a metadirective body.
            (c_parser_statement_after_labels): Likewise.
            (c_parser_pragma): Handle PRAGMA_OMP_METADIRECTIVE.
            (c_parser_omp_context_selector): Allow arbitrary expressions in
            device_num and condition properties.
            (c_parser_omp_assumption_clauses): Handle C_OMP_DIR_META.
            (analyze_metadirective_body): New.
            (c_parser_omp_metadirective): New.

    gcc/testsuite/
            PR middle-end/112779
            * c-c++-common/gomp/declare-variant-2.c: Adjust expected output for
C.
            * gcc.dg/gomp/metadirective-1.c: New.

    Co-Authored-By: Kwok Cheung Yeung <k...@codesourcery.com>
    Co-Authored-By: Sandra Loosemore <san...@codesourcery.com>

Reply via email to