From: Hafiz Abid Qadeer Date: Mon, 21 Feb 2022 13:54:57 +0000 (+0000) Subject: Set omp_requires_mask for dynamic_allocators. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7eda84c4837b0e025e6f7b34c72ac0f72a74805a;p=thirdparty%2Fgcc.git Set omp_requires_mask for dynamic_allocators. This is backport of a patch posted in https://gcc.gnu.org/pipermail/gcc-patches/2022-February/590655.html This patch fixes an issue that although gfortran accepts 'requires dynamic_allocators', it does not set the omp_requires_mask accordingly. gcc/fortran/ChangeLog: * parse.cc (gfc_parse_file): Set OMP_REQUIRES_DYNAMIC_ALLOCATORS bit in omp_requires_mask. --- diff --git a/gcc/fortran/ChangeLog.omp b/gcc/fortran/ChangeLog.omp index bbe23e93e1d2..a9815696d21e 100644 --- a/gcc/fortran/ChangeLog.omp +++ b/gcc/fortran/ChangeLog.omp @@ -1,3 +1,8 @@ +2022-03-08 Abid Qadeer + + * parse.cc (gfc_parse_file): Set OMP_REQUIRES_DYNAMIC_ALLOCATORS + bit in omp_requires_mask. + 2022-03-01 Tobias Burnus * class.cc (finalization_scalarizer): Mark syms as artificial. diff --git a/gcc/fortran/parse.cc b/gcc/fortran/parse.cc index 1d216247bc3d..14c31d53b273 100644 --- a/gcc/fortran/parse.cc +++ b/gcc/fortran/parse.cc @@ -7022,6 +7022,9 @@ done: break; } + if (omp_requires & OMP_REQ_DYNAMIC_ALLOCATORS) + omp_requires_mask + = (enum omp_requires) (omp_requires_mask | OMP_REQUIRES_DYNAMIC_ALLOCATORS); /* Do the parse tree dump. */ gfc_current_ns = flag_dump_fortran_original ? gfc_global_ns_list : NULL;