public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Marcel Vollweiler <marcel@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc/devel/omp/gcc-12] OpenAcc: Correction of reduction enhancement
Date: Tue, 25 Oct 2022 15:15:05 +0000 (GMT)	[thread overview]
Message-ID: <20221025151505.6F743385AC29@sourceware.org> (raw)

https://gcc.gnu.org/g:4226421e6d6d4f94706ed92082581661cedf8071

commit 4226421e6d6d4f94706ed92082581661cedf8071
Author: Marcel Vollweiler <marcel@codesourcery.com>
Date:   Tue Oct 25 08:12:42 2022 -0700

    OpenAcc: Correction of reduction enhancement
    
    Commit bce2c92cfec2ae1eb9d79e36dff5a220b688bfa1 "Various OpenACC reduction
    enhancements - ME and nvptx changes" introduced several regressions:
    
            gcc/testsuite/c-c++-common/goacc/nested-reductions-1-routine.c
            gcc/testsuite/c-c++-common/goacc/nested-reductions-2-routine.c
            gcc/testsuite/c-c++-common/goacc/orphan-reductions-2.c
            gcc/testsuite/gfortran.dg/goacc/nested-reductions-1-routine.f90
            gcc/testsuite/gfortran.dg/goacc/nested-reductions-2-routine.f90
            gcc/testsuite/gfortran.dg/goacc/orphan-reductions-2.f90
    
    This fixes above regressions.
    
    gcc/ChangeLog:
    
            * omp-offload.cc (oacc_loop_auto_partitions): Removed OLF reduction
            handling.

Diff:
---
 gcc/ChangeLog.omp  | 5 +++++
 gcc/omp-offload.cc | 7 -------
 2 files changed, 5 insertions(+), 7 deletions(-)

diff --git a/gcc/ChangeLog.omp b/gcc/ChangeLog.omp
index 68d5eea01a7..9b2a2007ac1 100644
--- a/gcc/ChangeLog.omp
+++ b/gcc/ChangeLog.omp
@@ -1,3 +1,8 @@
+2022-10-25  Marcel Vollweiler  <marcel@codesourcery.com>
+
+	* omp-offload.cc (oacc_loop_auto_partitions): Removed OLF reduction
+	handling.
+
 2022-10-24  Andrew Stubbs  <ams@codesourcery.com>
 
 	* tree-vect-data-refs.cc (vect_analyze_data_refs): Workaround an
diff --git a/gcc/omp-offload.cc b/gcc/omp-offload.cc
index 979bc0badb2..b18f28f86b9 100644
--- a/gcc/omp-offload.cc
+++ b/gcc/omp-offload.cc
@@ -2265,13 +2265,6 @@ oacc_loop_auto_partitions (oacc_loop *loop, unsigned outer_mask,
 	 non-innermost available level.  */
       unsigned this_mask = GOMP_DIM_MASK (GOMP_DIM_GANG);
 
-      /* Orphan reductions cannot have gang partitioning.  */
-      if ((loop->flags & OLF_REDUCTION)
-	  && oacc_get_fn_attrib (current_function_decl)
-	  && !lookup_attribute ("omp target entrypoint",
-				DECL_ATTRIBUTES (current_function_decl)))
-	this_mask = GOMP_DIM_MASK (GOMP_DIM_WORKER);
-
       /* Find the first outermost available partition. */
       while (this_mask <= outer_mask)
 	this_mask <<= 1;

                 reply	other threads:[~2022-10-25 15:15 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=20221025151505.6F743385AC29@sourceware.org \
    --to=marcel@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).