public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH 1/2] [og9] Fix tree check failure with reduction localization
@ 2019-09-06 12:15 Julian Brown
  2019-09-06 12:15 ` [PATCH 2/2] [og9] Remove duplicate SESE code in NVPTX backend Julian Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Julian Brown @ 2019-09-06 12:15 UTC (permalink / raw)
  To: gcc-patches; +Cc: Chung-Lin Tang, Andrew Stubbs

This patch fixes a tree-checking failure with the recently-applied patch
on the openacc-gcc-9-branch to localize reductions.

Tested with offloading to NVPTX. I will apply shortly.

Julian

ChangeLog

	gcc/
	* gimplify.c (gimplify_omp_workshare): Use OMP_CLAUSES, OMP_BODY
	instead of OMP_TARGET_CLAUSES, OMP_TARGET_BODY.
---
 gcc/ChangeLog.openacc | 5 +++++
 gcc/gimplify.c        | 3 +--
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/gcc/ChangeLog.openacc b/gcc/ChangeLog.openacc
index ddde3b8f84f..9e7893aa11e 100644
--- a/gcc/ChangeLog.openacc
+++ b/gcc/ChangeLog.openacc
@@ -1,3 +1,8 @@
+2019-09-06  Julian Brown  <julian@codesourcery.com>
+
+	* gimplify.c (gimplify_omp_workshare): Use OMP_CLAUSES, OMP_BODY
+	instead of OMP_TARGET_CLAUSES, OMP_TARGET_BODY.
+
 2019-09-05  Andrew Stubbs  <ams@codesourcery.com>
 
 	Backport from mainline:
diff --git a/gcc/gimplify.c b/gcc/gimplify.c
index 685db1763e0..3d869447d70 100644
--- a/gcc/gimplify.c
+++ b/gcc/gimplify.c
@@ -12253,8 +12253,7 @@ gimplify_omp_workshare (tree *expr_p, gimple_seq *pre_p)
 
       /* FIXME: Reductions are not supported in kernels regions yet.  */
       if (/*ort == ORT_ACC_KERNELS ||*/ ort == ORT_ACC_PARALLEL)
-        localize_reductions (OMP_TARGET_CLAUSES (*expr_p),
-			     OMP_TARGET_BODY (*expr_p));
+        localize_reductions (OMP_CLAUSES (expr), OMP_BODY (expr));
 
       gimple *g = gimplify_and_return_first (OMP_BODY (expr), &body);
       if (gimple_code (g) == GIMPLE_BIND)
-- 
2.22.0

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-09-06 12:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-06 12:15 [PATCH 1/2] [og9] Fix tree check failure with reduction localization Julian Brown
2019-09-06 12:15 ` [PATCH 2/2] [og9] Remove duplicate SESE code in NVPTX backend Julian Brown

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).