From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2508 invoked by alias); 20 Apr 2017 16:37:17 -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 2115 invoked by uid 89); 20 Apr 2017 16:37:16 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: smtp.ispras.ru Received: from bran.ispras.ru (HELO smtp.ispras.ru) (83.149.199.196) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 20 Apr 2017 16:37:14 +0000 Received: from monopod.intra.ispras.ru (monopod.intra.ispras.ru [10.10.3.121]) by smtp.ispras.ru (Postfix) with ESMTP id 62F5D5FB26; Thu, 20 Apr 2017 19:37:13 +0300 (MSK) Date: Thu, 20 Apr 2017 16:48:00 -0000 From: Alexander Monakov To: Jakub Jelinek cc: gcc-patches@gcc.gnu.org Subject: Re: [PATCH 2/5] omp-low: implement SIMT privatization, part 1 In-Reply-To: <20170420151622.GV1809@tucnak> Message-ID: References: <1490197595-31938-1-git-send-email-amonakov@ispras.ru> <1490197595-31938-3-git-send-email-amonakov@ispras.ru> <20170323103159.GM11094@tucnak> <20170420151622.GV1809@tucnak> User-Agent: Alpine 2.20.13 (LNX 116 2015-12-14) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-SW-Source: 2017-04/txt/msg00909.txt.bz2 On Thu, 20 Apr 2017, Jakub Jelinek wrote: > > This wasn't caught in testing, as apparently all testcases that have target > > simd loops with linear/lastprivate clauses also have the corresponding variables > > mentioned in target map clause, which makes them addressable (is that necessary?), > > Yes, in order to map something you need to map its address (+ size) on the > host to its address on the device, so it needs to be addressable. > Compared to that, firstprivate on target should not make it addressable. But ideally if nothing else is taking the address of a mapped variable inside of a target region, then it'd be more efficient to create a non-addressable instance and just copy its value from/to the addressable one on target region entry/exit. > Would be nice to also test explicit linear, perhaps in the same testcase, > just add ch and c and use say linear(c:2). Unfortunately that uncovers a separate wrong-code issue, explicit linear is not specifically handled in simt regions, but it should be, since we change the loop iteration step. Thanks. Alexander