From patchwork Wed Sep 27 12:39:32 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom de Vries X-Patchwork-Id: 819124 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-463054-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="HSr2XmrQ"; dkim-atps=neutral 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 3y2HTT0GKGz9t33 for ; Wed, 27 Sep 2017 22:39:55 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:to:cc :from:subject:message-id:date:mime-version:content-type; q=dns; s=default; b=y7fsXWYSqoNF+58LMZAPcXX9DSIEd6CBYbo09MqbZcmyEvD5VU bg1fkKYzAbpX0mcZhFuvkLuF1CWf+/ZhwEQD1UwWsFBRDaaTZ3uHK9PXtyZx5Jev f/Pp5Y9zcsNmlffZclrlQMFmNOTtVCWxd7KAKjwXapZ0Om5C/+sKL1AYk= 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:to:cc :from:subject:message-id:date:mime-version:content-type; s= default; bh=GlNeWf2JSOixrHG3O9+eT5u56qU=; b=HSr2XmrQWkrNJSxDEb7F d/ctI4yonOYHiSZvQaOoimwoCvpntXwTG6/9bYolUYBBCG7YZ8a1lub7tMwriHWr v/zxqmKO+TC8txtHLwLHvpUHvVR74dFonpWd+z0u4kbhTWYqDbDwauJhpkNMfNmh cYkgJ0A6q3jhVt1KdxxmFJE= Received: (qmail 74437 invoked by alias); 27 Sep 2017 12:39:47 -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 74124 invoked by uid 89); 27 Sep 2017 12:39:46 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_PASS, URIBL_RED autolearn=ham version=3.3.2 spammy= 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 ESMTP; Wed, 27 Sep 2017 12:39:45 +0000 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=SVR-IES-MBX-04.mgc.mentorg.com) by relay1.mentorg.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-SHA384:256) id 1dxBcr-0003FY-1S from Tom_deVries@mentor.com ; Wed, 27 Sep 2017 05:39:41 -0700 Received: from [127.0.0.1] (137.202.0.87) by SVR-IES-MBX-04.mgc.mentorg.com (139.181.222.4) with Microsoft SMTP Server (TLS) id 15.0.1263.5; Wed, 27 Sep 2017 13:39:36 +0100 To: Jakub Jelinek CC: Thomas Schwinge , GCC Patches From: Tom de Vries Subject: [openacc, testsuite, committed] Fix libgomp.oacc-c-c++-common/parallel-reduction.c for non-nvidia devices Message-ID: <10fde951-9ceb-e238-7fdd-0468b81d084a@mentor.com> Date: Wed, 27 Sep 2017 14:39:32 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 X-ClientProxiedBy: svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) To SVR-IES-MBX-04.mgc.mentorg.com (139.181.222.4) Hi, this patch makes the test-case libgomp.oacc-c-c++-common/parallel-reduction.c work for non-nvidia devices. Committed as obvious. Thanks, - Tom Fix libgomp.oacc-c-c++-common/parallel-reduction.c for non-nvidia devices 2017-09-27 Tom de Vries * testsuite/libgomp.oacc-c-c++-common/parallel-reduction.c (main): Remove acc_device_nvidia references. --- libgomp/testsuite/libgomp.oacc-c-c++-common/parallel-reduction.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/parallel-reduction.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/parallel-reduction.c index b2c60e5..077571f 100644 --- a/libgomp/testsuite/libgomp.oacc-c-c++-common/parallel-reduction.c +++ b/libgomp/testsuite/libgomp.oacc-c-c++-common/parallel-reduction.c @@ -21,7 +21,7 @@ main () } } - if (acc_get_device_type () != acc_device_nvidia) + if (acc_get_device_type () == acc_device_host) { if (s1 != 1) abort (); @@ -41,7 +41,7 @@ main () s2 += N; } - if (acc_get_device_type () != acc_device_nvidia) + if (acc_get_device_type () == acc_device_host) { if (s1 != 1) abort ();