From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4003 invoked by alias); 18 Dec 2018 12:25:41 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 3979 invoked by uid 89); 18 Dec 2018 12:25:41 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-11.9 required=5.0 tests=BAYES_00,GIT_PATCH_2,GIT_PATCH_3,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=30pm, HTo:U*julian X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 18 Dec 2018 12:25:39 +0000 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 758288B10D; Tue, 18 Dec 2018 12:25:38 +0000 (UTC) Received: from tucnak.zalov.cz (ovpn-117-214.ams2.redhat.com [10.36.117.214]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B5E856012B; Tue, 18 Dec 2018 12:25:37 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.15.2/8.15.2) with ESMTP id wBICPY7h015987; Tue, 18 Dec 2018 13:25:35 +0100 Received: (from jakub@localhost) by tucnak.zalov.cz (8.15.2/8.15.2/Submit) id wBICPWen015986; Tue, 18 Dec 2018 13:25:32 +0100 Date: Tue, 18 Dec 2018 12:25:00 -0000 From: Jakub Jelinek To: Julian Brown , Thomas Schwinge Cc: gcc-patches@gcc.gnu.org, Chung-Lin Tang , Catherine_Moore@mentor.com, fortran@gcc.gnu.org Subject: Re: [PATCH] OpenACC 2.6 manual deep copy support (attach/detach) Message-ID: <20181218122532.GI23305@tucnak> Reply-To: Jakub Jelinek References: <1543578069-386-1-git-send-email-julian@codesourcery.com> <20181207135019.GI12380@tucnak> <20181210194137.27720f3e@squid.athome> <20181213105705.GU12380@tucnak> <20181214190030.763feaeb@squid.athome> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181214190030.763feaeb@squid.athome> User-Agent: Mutt/1.9.2 (2017-12-15) X-IsSubscribed: yes X-SW-Source: 2018-12/txt/msg01292.txt.bz2 On Fri, Dec 14, 2018 at 07:00:30PM +0000, Julian Brown wrote: > OpenACC 2.6 manual deep copy support (attach/detach) > > gcc/c-family/ > * c-pragma.h (pragma_omp_clause): Add PRAGMA_OACC_CLAUSE_ATTACH, > PRAGMA_OACC_CLAUSE_DETACH. and instead of , ? > --- a/gcc/c-family/c-common.h > +++ b/gcc/c-family/c-common.h > @@ -1176,6 +1176,7 @@ extern void c_omp_split_clauses (location_t, enum tree_code, omp_clause_mask, > extern tree c_omp_declare_simd_clauses_to_numbers (tree, tree); > extern void c_omp_declare_simd_clauses_to_decls (tree, tree); > extern enum omp_clause_default_kind c_omp_predetermined_sharing (tree); > +extern const char * c_omp_map_clause_name (tree, bool); No space after * in this case. > +const char * > +c_omp_map_clause_name (tree clause, bool oacc) > +{ > + if (oacc && OMP_CLAUSE_CODE (clause) == OMP_CLAUSE_MAP) > + switch (OMP_CLAUSE_MAP_KIND (clause)) > + { > + case GOMP_MAP_FORCE_ALLOC: > + case GOMP_MAP_ALLOC: return "create"; > + case GOMP_MAP_FORCE_TO: > + case GOMP_MAP_TO: return "copyin"; > + case GOMP_MAP_FORCE_FROM: > + case GOMP_MAP_FROM: return "copyout"; > + case GOMP_MAP_FORCE_TOFROM: > + case GOMP_MAP_TOFROM: return "copy"; > + case GOMP_MAP_RELEASE: return "delete"; > + case GOMP_MAP_FORCE_PRESENT: return "present"; > + case GOMP_MAP_ATTACH: return "attach"; > + case GOMP_MAP_FORCE_DETACH: > + case GOMP_MAP_DETACH: return "detach"; > + case GOMP_MAP_DEVICE_RESIDENT: return "device_resident"; > + case GOMP_MAP_LINK: return "link"; > + case GOMP_MAP_FORCE_DEVICEPTR: return "deviceptr"; > + default:; Please use default: break; instead. > for (i = 0; i < tgt->list_count; i++) > { > splay_tree_key k = tgt->list[i].key; > + > if (k == NULL) > continue; Why the blank change? Otherwise LGTM, if Thomas is ok with it. Jakub