From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 81213 invoked by alias); 9 Jan 2019 00:10:42 -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 81173 invoked by uid 89); 9 Jan 2019 00:10:41 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,SPF_PASS autolearn=ham version=3.3.2 spammy=99, dimensions X-HELO: mx1.suse.de Received: from mx2.suse.de (HELO mx1.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 09 Jan 2019 00:10:39 +0000 Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 1C841AB87; Wed, 9 Jan 2019 00:10:37 +0000 (UTC) Date: Wed, 09 Jan 2019 00:10:00 -0000 From: Tom de Vries To: gcc-patches@gcc.gnu.org Cc: Thomas Schwinge Subject: [committed][libgomp, testsuite, openacc] Don't use const int for dimensions Message-ID: <20190109001113.GA29825@delia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) X-IsSubscribed: yes X-SW-Source: 2019-01/txt/msg00454.txt.bz2 Hi, Const int is handled differently at -O0 for -xc and -xc++, which can cause noise in testsuite/libgomp.oacc-c-c++-common test-cases (which are both run for c and c++) if const int is used for launch dimensions. Fix this by using #defines instead. Committed to trunk. Thanks, - Tom [libgomp, testsuite, openacc] Don't use const int for dimensions 2019-01-08 Tom de Vries PR target/88756 * testsuite/libgomp.oacc-c-c++-common/reduction-1.c (ng, nw, vl): Use #define instead of "const int". * testsuite/libgomp.oacc-c-c++-common/reduction-2.c (ng, nw, vl): Same. * testsuite/libgomp.oacc-c-c++-common/reduction-3.c (ng, nw, vl): Same. * testsuite/libgomp.oacc-c-c++-common/reduction-4.c (ng, nw, vl): Same. * testsuite/libgomp.oacc-c-c++-common/reduction-5.c (ng, nw, vl): Same. --- libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-1.c | 6 +++--- libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-2.c | 6 +++--- libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-3.c | 6 +++--- libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-4.c | 6 +++--- libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-5.c | 6 +++--- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-1.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-1.c index e8a8911faeb..3fe9ae65309 100644 --- a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-1.c +++ b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-1.c @@ -8,9 +8,9 @@ #include #include "reduction.h" -const int ng = 8; -const int nw = 4; -const int vl = 32; +#define ng 8 +#define nw 4 +#define vl 32 static void test_reductions (void) diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-2.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-2.c index d19b1c825ca..83986abf7e0 100644 --- a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-2.c +++ b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-2.c @@ -8,9 +8,9 @@ #include #include "reduction.h" -const int ng = 8; -const int nw = 4; -const int vl = 32; +#define ng 8 +#define nw 4 +#define vl 32 static void test_reductions (void) diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-3.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-3.c index 1b948bef5a0..3ac0f996a86 100644 --- a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-3.c +++ b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-3.c @@ -8,9 +8,9 @@ #include #include "reduction.h" -const int ng = 8; -const int nw = 4; -const int vl = 32; +#define ng 8 +#define nw 4 +#define vl 32 static void test_reductions (void) diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-4.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-4.c index 79355eded80..b8fa954cfee 100644 --- a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-4.c +++ b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-4.c @@ -9,9 +9,9 @@ #include #include "reduction.h" -const int ng = 8; -const int nw = 4; -const int vl = 32; +#define ng 8 +#define nw 4 +#define vl 32 static void test_reductions (void) diff --git a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-5.c b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-5.c index 46b553a61ff..215d919a103 100644 --- a/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-5.c +++ b/libgomp/testsuite/libgomp.oacc-c-c++-common/reduction-5.c @@ -9,9 +9,9 @@ #include #include -const int ng = 8; -const int nw = 4; -const int vl = 32; +#define ng 8 +#define nw 4 +#define vl 32 const int n = 100;