public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Kwok Yeung <kcy@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc/devel/omp/gcc-12] Set omp_requires_mask for dynamic_allocators.
Date: Wed, 29 Jun 2022 14:44:44 +0000 (GMT)	[thread overview]
Message-ID: <20220629144444.D505C3850841@sourceware.org> (raw)

https://gcc.gnu.org/g:7eda84c4837b0e025e6f7b34c72ac0f72a74805a

commit 7eda84c4837b0e025e6f7b34c72ac0f72a74805a
Author: Hafiz Abid Qadeer <abidh@codesourcery.com>
Date:   Mon Feb 21 13:54:57 2022 +0000

    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:
---
 gcc/fortran/ChangeLog.omp | 5 +++++
 gcc/fortran/parse.cc      | 3 +++
 2 files changed, 8 insertions(+)

diff --git a/gcc/fortran/ChangeLog.omp b/gcc/fortran/ChangeLog.omp
index bbe23e93e1d..a9815696d21 100644
--- a/gcc/fortran/ChangeLog.omp
+++ b/gcc/fortran/ChangeLog.omp
@@ -1,3 +1,8 @@
+2022-03-08  Abid Qadeer  <abidh@codesourcery.com>
+
+	* parse.cc (gfc_parse_file): Set OMP_REQUIRES_DYNAMIC_ALLOCATORS
+	bit in omp_requires_mask.
+
 2022-03-01  Tobias Burnus  <tobias@codesourcery.com>
 
 	* class.cc (finalization_scalarizer): Mark syms as artificial.
diff --git a/gcc/fortran/parse.cc b/gcc/fortran/parse.cc
index 1d216247bc3..14c31d53b27 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;


                 reply	other threads:[~2022-06-29 14:44 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220629144444.D505C3850841@sourceware.org \
    --to=kcy@gcc.gnu.org \
    --cc=gcc-cvs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).