From patchwork Fri Apr 8 13:41:00 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Thomas Schwinge X-Patchwork-Id: 608021 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3qhLGR0fhsz9t5s for ; Fri, 8 Apr 2016 23:41:33 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=g9BqaEmU; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type; q=dns; s=default; b=mQrAzYFD4QROMab2 nIbHa60JDv8hfiwejLl5OAHuR+S7YFcLSS5VskAOznf5/WwxaRQ9Sj8FA0LtBDYU 7THrArrqsqQKFtPuTVEtyTph7dd09bBlYCbRA9RtggU8BIioi/tGEgYNOzR1V03m U4Mf1nlVP/dPY+lJVgIplLEoQqg= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-type; s=default; bh=CAVwEuo6RlqdtHJZjDnGKc A7jiI=; b=g9BqaEmUcp7yMxrrLimOICvK5CCNlmP00AX0AWbLEhlQ5F44b0duEZ jf6cN4PyMLBKd1nYBtI7Cvg8SZwy3MDYrKC+Ndps0hl6pihmYo1TAk+gaCy34UrG az/N4qODeujSVqmY6SI6LxZeHvEMMIM2wWeYTtHPlETORSjeR1tBA= Received: (qmail 81898 invoked by alias); 8 Apr 2016 13:41:26 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 80579 invoked by uid 89); 8 Apr 2016 13:41:25 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_NONE, SPF_PASS, URIBL_RED autolearn=ham version=3.3.2 spammy=nov, Nov, UD:php X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Fri, 08 Apr 2016 13:41:15 +0000 Received: from svr-orw-fem-05.mgc.mentorg.com ([147.34.97.43]) by relay1.mentorg.com with esmtp id 1aoWeu-0005xY-1s from Thomas_Schwinge@mentor.com ; Fri, 08 Apr 2016 06:41:12 -0700 Received: from tftp-cs (147.34.91.1) by svr-orw-fem-05.mgc.mentorg.com (147.34.97.43) with Microsoft SMTP Server id 14.3.224.2; Fri, 8 Apr 2016 06:41:11 -0700 Received: by tftp-cs (Postfix, from userid 49978) id B5B12C21BE; Fri, 8 Apr 2016 06:41:10 -0700 (PDT) From: Thomas Schwinge To: Chung-Lin Tang CC: GCC Patches , Jakub Jelinek , Cesar Philippidis , James Norris Subject: Fortran OpenACC host_data construct ICE (was: [gomp4] Re: [OpenACC 0/7] host_data construct) In-Reply-To: <87r3j4lcrd.fsf@kepler.schwinge.homeip.net> References: <56293476.5020801@codesourcery.com> <562A578E.4080907@codesourcery.com> <20151026183422.GW478@tucnak.redhat.com> <20151102183339.365c3d33@octopus> <20151112111621.657650bc@octopus> <20151118124747.30a2ec5d@octopus> <20151119131345.GX5675@tucnak.redhat.com> <20151119142650.5a8842e4@octopus> <20151119155723.GA5675@tucnak.redhat.com> <20151130193034.71143aa4@octopus> <877fkwn8p6.fsf@kepler.schwinge.homeip.net> <87r3j4lcrd.fsf@kepler.schwinge.homeip.net> User-Agent: Notmuch/0.9-125-g4686d11 (http://notmuchmail.org) Emacs/24.5.1 (i586-pc-linux-gnu) Date: Fri, 8 Apr 2016 15:41:00 +0200 Message-ID: <878u0o6wwj.fsf@kepler.schwinge.homeip.net> MIME-Version: 1.0 Hi! On Wed, 2 Dec 2015 23:13:58 +0100, I wrote: > On Wed, 2 Dec 2015 16:58:45 +0100, I wrote: > > Cesar and Jim copied, for help with Fortran and generally testsuite > > things. (Just in case you happen to have any ideas.) > > On Mon, 30 Nov 2015 19:30:34 +0000, Julian Brown wrote: > > > [patch] > > > > First, thanks! > > Aside from a number of formatting/re-ordering changes, the front end > changes were basically still the same, but otherwise (middle end, > libgomp) the patch as committed to trunk in r231118 was quite (totally?) > ;-) different from the code we had on gomp-4_0-branch, so I had to spend > some time on merging, cleaning things up. > > Your submission/commit didn't have any execution tests for OpenACC > > host_data in Fortran. On gomp-4_0-branch, there is > > libgomp/testsuite/libgomp.oacc-fortran/host_data-1.f90 at least. > > ..., but this one now FAILs (ICE) as follows: > > [...]/source-gcc/libgomp/testsuite/libgomp.oacc-fortran/host_data-1.f90:11:0: internal compiler error: in scan_omp_target, at omp-low.c:3218 > 0xa33e80 scan_omp_target > [...]/source-gcc/gcc/omp-low.c:3218 > [...] Filed . > Maybe that's due to the gcc/gimplify.c:gimplify_scan_omp_clauses issue > mentioned in > , > or maybe something else? (XFAILed for now.) The following patch does not resolve the problem -- but we'll still want something like that, I suppose? Grüße Thomas --- gcc/gimplify.c +++ gcc/gimplify.c @@ -6544,18 +6544,20 @@ gimplify_scan_omp_clauses (tree *list_p, gimple_seq *pre_p, the Fortran FE is updated to OpenMP 4.5. */ ctx->target_map_scalars_firstprivate = true; } - if (!lang_GNU_Fortran ()) - switch (code) - { - case OMP_TARGET: - case OMP_TARGET_DATA: - case OMP_TARGET_ENTER_DATA: - case OMP_TARGET_EXIT_DATA: - case OACC_HOST_DATA: - ctx->target_firstprivatize_array_bases = true; - default: + switch (code) + { + case OMP_TARGET: + case OMP_TARGET_DATA: + case OMP_TARGET_ENTER_DATA: + case OMP_TARGET_EXIT_DATA: + if (lang_GNU_Fortran ()) break; - } + /* FALLTHRU */ + case OACC_HOST_DATA: + ctx->target_firstprivatize_array_bases = true; + default: + break; + } while ((c = *list_p) != NULL) {