From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1729) id 633513A3E420; Thu, 13 May 2021 16:12:14 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 633513A3E420 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Kwok Yeung To: gcc-cvs@gcc.gnu.org Subject: [gcc/devel/omp/gcc-11] Fix tree check failure with reduction localization X-Act-Checkin: gcc X-Git-Author: Julian Brown X-Git-Refname: refs/heads/devel/omp/gcc-11 X-Git-Oldrev: 2ec47f0ddcc6bc3414ac067e5833b2d8f5b09345 X-Git-Newrev: c6c7c943936183ca89ee287c3651a105f3b38444 Message-Id: <20210513161214.633513A3E420@sourceware.org> Date: Thu, 13 May 2021 16:12:14 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 May 2021 16:12:14 -0000 https://gcc.gnu.org/g:c6c7c943936183ca89ee287c3651a105f3b38444 commit c6c7c943936183ca89ee287c3651a105f3b38444 Author: Julian Brown Date: Fri Sep 6 04:42:16 2019 -0700 Fix tree check failure with reduction localization gcc/ * gimplify.c (gimplify_omp_workshare): Use OMP_CLAUSES, OMP_BODY instead of OMP_TARGET_CLAUSES, OMP_TARGET_BODY. Diff: --- gcc/ChangeLog.omp | 5 +++++ gcc/gimplify.c | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/gcc/ChangeLog.omp b/gcc/ChangeLog.omp index 228dbd54b58..0332bca6b67 100644 --- a/gcc/ChangeLog.omp +++ b/gcc/ChangeLog.omp @@ -1,3 +1,8 @@ +2019-09-06 Julian Brown + + * gimplify.c (gimplify_omp_workshare): Use OMP_CLAUSES, OMP_BODY + instead of OMP_TARGET_CLAUSES, OMP_TARGET_BODY. + 2019-09-05 Julian Brown * config/gcn/gcn.c (gcn_goacc_validate_dims): Remove diff --git a/gcc/gimplify.c b/gcc/gimplify.c index 07e85d98c3b..05f88eae7e0 100644 --- a/gcc/gimplify.c +++ b/gcc/gimplify.c @@ -13587,8 +13587,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)