From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23037 invoked by alias); 12 Feb 2014 10:28:53 -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 23028 invoked by uid 89); 12 Feb 2014 10:28:52 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_SEMBACKSCATTER,RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: e06smtp12.uk.ibm.com Received: from e06smtp12.uk.ibm.com (HELO e06smtp12.uk.ibm.com) (195.75.94.108) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Wed, 12 Feb 2014 10:28:47 +0000 Received: from /spool/local by e06smtp12.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 12 Feb 2014 10:28:43 -0000 Received: from d06dlp03.portsmouth.uk.ibm.com (9.149.20.15) by e06smtp12.uk.ibm.com (192.168.101.142) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Wed, 12 Feb 2014 10:28:40 -0000 Received: from b06cxnps4075.portsmouth.uk.ibm.com (d06relay12.portsmouth.uk.ibm.com [9.149.109.197]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id BE46D1B08066 for ; Wed, 12 Feb 2014 10:28:14 +0000 (GMT) Received: from d06av03.portsmouth.uk.ibm.com (d06av03.portsmouth.uk.ibm.com [9.149.37.213]) by b06cxnps4075.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id s1CASRv663832278 for ; Wed, 12 Feb 2014 10:28:27 GMT Received: from d06av03.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av03.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s1CASdYT002308 for ; Wed, 12 Feb 2014 03:28:39 -0700 Received: from bl3ahm9f.de.ibm.com (dyn-9-152-212-163.boeblingen.de.ibm.com [9.152.212.163]) by d06av03.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVin) with ESMTP id s1CAScRO002279 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NO); Wed, 12 Feb 2014 03:28:38 -0700 Received: from dvogt by bl3ahm9f.de.ibm.com with local (Exim 4.76) (envelope-from ) id 1WDX3W-0002z3-DE; Wed, 12 Feb 2014 11:28:38 +0100 Date: Wed, 12 Feb 2014 10:28:00 -0000 From: Dominik Vogt To: gcc-patches@gcc.gnu.org Cc: Andreas Krebbel Subject: [PATCH] S390: Fix crash with -mhotpatch and gfortran Message-ID: <20140212102838.GA10947@linux.vnet.ibm.com> Reply-To: vogt@linux.vnet.ibm.com MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="sdtB3X0nJg68CQEu" Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 14021210-8372-0000-0000-000008A3B4AF X-SW-Source: 2014-02/txt/msg00762.txt.bz2 --sdtB3X0nJg68CQEu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-length: 310 The attached patch fixes a crash if gfortran encounters a nested function when -mhotpatch is enabled. (It slightly improves the warning message too.) This patch affects s390 only. Andreas Krebbel will commit the patch soon, if there are no objections. Ciao Dominik ^_^ ^_^ -- Dominik Vogt IBM Germany --sdtB3X0nJg68CQEu Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="gcc-4.9-0001-S390-Fix-crash-when-mhotpatch-encounters-nested-func.patch" Content-length: 975 >From 352cf98ffb32c1f0fa8b961314faf6e6afffb661 Mon Sep 17 00:00:00 2001 From: Dominik Vogt Date: Wed, 12 Feb 2014 05:53:34 +0000 Subject: [PATCH 1/2] S390: Fix crash when -mhotpatch encounters nested functions (e.g. with gfortran). --- gcc/config/s390/s390.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gcc/config/s390/s390.c b/gcc/config/s390/s390.c index 32a25a4..9ae8ffd 100644 --- a/gcc/config/s390/s390.c +++ b/gcc/config/s390/s390.c @@ -5510,9 +5510,8 @@ s390_asm_output_function_label (FILE *asm_out_file, const char *fname, if (hotpatch_trampoline_halfwords >= 0 && decl_function_context (decl) != NULL_TREE) { - warning_at (0, DECL_SOURCE_LOCATION (decl), - "hotpatch_prologue is not compatible with nested" - " function"); + warning_at (0, OPT_mhotpatch, + "hotpatching is not compatible with nested functions"); hotpatch_trampoline_halfwords = -1; } } -- 1.8.3.1 --sdtB3X0nJg68CQEu Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="gcc-4.9-ChangeLog" Content-length: 225 2014-02-12 Dominik Vogt * config/s390/s390.c (s390_asm_output_function_label): fix crash caused by bad second argument to warning_at() with -mhotpatch and nested functions (e.g. with gfortran) --sdtB3X0nJg68CQEu--