From patchwork Wed Apr 29 08:35:54 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Thomas Schwinge X-Patchwork-Id: 1279099 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=8.43.85.97; helo=sourceware.org; envelope-from=gcc-patches-bounces@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 49BsL235RPz9sSq for ; Wed, 29 Apr 2020 18:36:09 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 49740395444C; Wed, 29 Apr 2020 08:36:06 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from esa3.mentor.iphmx.com (esa3.mentor.iphmx.com [68.232.137.180]) by sourceware.org (Postfix) with ESMTPS id C8C8838930E0 for ; Wed, 29 Apr 2020 08:36:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org C8C8838930E0 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=Thomas_Schwinge@mentor.com IronPort-SDR: Vsz69X/rPIwVPvRZMStBLM8HERy3ZUc+cnq6Vmi9QKmWXL8B8clsx6d2PtY9LujDM+h+LTrhu3 qrLLKkQqD60y7KuJxLhLbT2VFFzFH0sfUg0DqKVEnxBXsDXEuQZMgYXztIr9irmnV+YDTe2RKr S8T2HGG7rSFNj+T1eX1o5TK0cPDuCqCtvC/yai3xTYCml14SZY8UGaLEMgh7wzBRqOIi8ZN3tq zBhocG5sm3LaoB2gBKrr5om+E8yfoMfepLAKFc2OC+ukN2C3RroamnbUAxZCkl0toNgQqJtV+8 kFk= X-IronPort-AV: E=Sophos;i="5.73,330,1583222400"; d="scan'208,223";a="48337914" Received: from orw-gwy-02-in.mentorg.com ([192.94.38.167]) by esa3.mentor.iphmx.com with ESMTP; 29 Apr 2020 00:36:03 -0800 IronPort-SDR: nJYZ4X+3pYQ/Q4QyiSJkuJIpXoATHzHSMktcMTomHGU14B+/Po+wp95Kt5c3OTXaaV2qNaCsya QNejvAvuizEL9jyR6G11zWOhyCw6s0tPgR57oFLnVjL95kL6eapI8cVshSw/5c+bsNQ9dYv/25 pV0kOQxOpaHdqlXS2SBDuOa92bQhlmQUkZYVftKX+WFihWoVgcSn2a+BZ1osRH7LTn2nTMnKBg oFnuq8Utxn/rEjFa/4npDVZ4+NWovnnrl/JODbhLi4wizSn8xMreAkwksPVOWxnJzlrrKsCPg1 Mx4= From: Thomas Schwinge To: Andrew Stubbs , Kwok Cheung Yeung , Subject: [gcn] Set 'UI_NONE' for 'TARGET_EXCEPT_UNWIND_INFO' [PR94282] (was: [PATCH] amdgcn: Add stub personality function) In-Reply-To: <87lfmm8nsy.fsf@euler.schwinge.homeip.net> References: <1efeee77-2062-bb35-fca7-8e44ff422ea1@codesourcery.com> <325995d0-3204-20a0-be04-91f9134f07f9@codesourcery.com> <87lfmm8nsy.fsf@euler.schwinge.homeip.net> User-Agent: Notmuch/0.29.1+93~g67ed7df (https://notmuchmail.org) Emacs/26.1 (x86_64-pc-linux-gnu) Date: Wed, 29 Apr 2020 10:35:54 +0200 Message-ID: <87mu6ubset.fsf@euler.schwinge.homeip.net> MIME-Version: 1.0 X-Spam-Status: No, score=-21.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, KAM_SHORT, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces@gcc.gnu.org Sender: "Gcc-patches" Hi! On 2020-04-23T13:05:33+0200, I wrote: > On 2020-04-23T09:15:29+0100, Andrew Stubbs wrote: >> On 22/04/2020 22:10, Kwok Cheung Yeung wrote: >>> [...] allows the following tests in the libgomp >>> testsuite that were previously failing with a linker error to compile >>> and run, provided that they do not throw any exceptions: >>> >>> libgomp.c-c++-common/function-not-offloaded.c >>> libgomp.c++/for-15.C >>> libgomp.c++/for-24.C >>> libgomp.oacc-c-c++-common/routine-1.c >>> libgomp.oacc-c++/pr71959.C >>> libgomp.oacc-c++/routine-1-auto.C >>> libgomp.oacc-c++/routine-1-template-auto.C >>> libgomp.oacc-c++/routine-1-template-trailing-return-type.C >>> libgomp.oacc-c++/routine-1-template.C >>> libgomp.oacc-c++/routine-1-trailing-return-type.C > > That's "[amdgcn] ld: error: undefined > symbol: __gxx_personality_v0" > I suggest we [...] apply what I'd proposed a month ago in > "[amdgcn] ld: error: undefined symbol: > __gxx_personality_v0", and now yesterday (coincidentally) posted. Now pushed to master branch in commit 7f1989249e25af6fc0f124452efa24b3796b767a "[gcn] Set 'UI_NONE' for 'TARGET_EXCEPT_UNWIND_INFO' [PR94282]", see attached. Grüße Thomas ----------------- Mentor Graphics (Deutschland) GmbH, Arnulfstraße 201, 80634 München / Germany Registergericht München HRB 106955, Geschäftsführer: Thomas Heurung, Alexander Walter From 7f1989249e25af6fc0f124452efa24b3796b767a Mon Sep 17 00:00:00 2001 From: Thomas Schwinge Date: Tue, 21 Apr 2020 22:39:33 +0200 Subject: [PATCH] [gcn] Set 'UI_NONE' for 'TARGET_EXCEPT_UNWIND_INFO' [PR94282] In libgomp offloading testing, this resolves all the 'ld: error: undefined symbol: __gxx_personality_v0' FAILs. gcc/ PR target/94282 * common/config/gcn/gcn-common.c (gcn_except_unwind_info): New function. (TARGET_EXCEPT_UNWIND_INFO): Define. libgomp/ PR target/94282 * testsuite/libgomp.c-c++-common/function-not-offloaded.c: Remove 'dg-allow-blank-lines-in-output'. --- gcc/ChangeLog | 7 +++++++ gcc/common/config/gcn/gcn-common.c | 9 +++++++++ libgomp/ChangeLog | 4 ++++ .../libgomp.c-c++-common/function-not-offloaded.c | 1 - 4 files changed, 20 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 3321e8839707..2ba39f67200f 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2020-04-29 Thomas Schwinge + + PR target/94282 + * common/config/gcn/gcn-common.c (gcn_except_unwind_info): New + function. + (TARGET_EXCEPT_UNWIND_INFO): Define. + 2020-04-29 Jakub Jelinek PR target/94248 diff --git a/gcc/common/config/gcn/gcn-common.c b/gcc/common/config/gcn/gcn-common.c index 84a567b2bbbb..9642f9cc5a6c 100644 --- a/gcc/common/config/gcn/gcn-common.c +++ b/gcc/common/config/gcn/gcn-common.c @@ -34,4 +34,13 @@ static const struct default_options gcn_option_optimization_table[] = #undef TARGET_OPTION_OPTIMIZATION_TABLE #define TARGET_OPTION_OPTIMIZATION_TABLE gcn_option_optimization_table +static enum unwind_info_type +gcn_except_unwind_info (struct gcc_options *opts ATTRIBUTE_UNUSED) +{ + return UI_NONE; +} + +#undef TARGET_EXCEPT_UNWIND_INFO +#define TARGET_EXCEPT_UNWIND_INFO gcn_except_unwind_info + struct gcc_targetm_common targetm_common = TARGETM_COMMON_INITIALIZER; diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index cfe6e0653c92..1a7046f2fc64 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,5 +1,9 @@ 2020-04-29 Thomas Schwinge + PR target/94282 + * testsuite/libgomp.c-c++-common/function-not-offloaded.c: Remove + 'dg-allow-blank-lines-in-output'. + * oacc-init.c (get_openacc_name): Handle 'gcn'. * testsuite/lib/libgomp.exp (offload_target_to_openacc_device_type) [amdgcn*]: Return diff --git a/libgomp/testsuite/libgomp.c-c++-common/function-not-offloaded.c b/libgomp/testsuite/libgomp.c-c++-common/function-not-offloaded.c index f01a64e72c07..9e59ef8864e7 100644 --- a/libgomp/testsuite/libgomp.c-c++-common/function-not-offloaded.c +++ b/libgomp/testsuite/libgomp.c-c++-common/function-not-offloaded.c @@ -1,6 +1,5 @@ /* { dg-do link } */ /* { dg-excess-errors "unresolved symbol foo, lto1, mkoffload and lto-wrapper fatal errors" { target offload_device_nonshared_as } } */ -/* { dg-allow-blank-lines-in-output 1 } */ /* { dg-additional-sources "function-not-offloaded-aux.c" } */ #pragma omp declare target -- 2.26.2