From patchwork Sun Jan 19 18:33:05 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John David Anglin X-Patchwork-Id: 312389 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org 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 ABFE22C00AC for ; Mon, 20 Jan 2014 05:33:34 +1100 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:from:to:content-type:subject:mime-version:date; q= dns; s=default; b=xxnMGphT6v+1E4YiD20qtdQxkPItr94Ot8cFeQ587m91vq /OgZle3RfqiW4k4/5RqjTqFVdqIqaWns9llZeoyFW35yyctQRjwqFmZqwSQb0x3l 74wRHyRtf8GgOQbjFBscgp/QM4Xn/tCeKhcOp/b3518yB0AcRYUIiwwX5j+zo= 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 :message-id:from:to:content-type:subject:mime-version:date; s= default; bh=SkLpbCIDE/oTiIxrLd9S7+pwcsI=; b=uCt/pq9WgMPlJb+JUHXj 4fQtUlSjAVF++SZyrMvW/hsrta0NIa02rqRKRNzJAJI/h1Z+LldtBpGZhj1/uTbP FjkRDUxf6dL2mt7dDWipV2Uy+rXAEpBzUEhimQiyp3WdtS541tz0YYdHrFMOoyHq tHEAWK+v8DtEjxRNVb0Rux8= Received: (qmail 18576 invoked by alias); 19 Jan 2014 18:33:26 -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 18565 invoked by uid 89); 19 Jan 2014 18:33:25 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL, BAYES_00, MSGID_FROM_MTA_HEADER, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.2 X-HELO: blu0-omc3-s15.blu0.hotmail.com Received: from blu0-omc3-s15.blu0.hotmail.com (HELO blu0-omc3-s15.blu0.hotmail.com) (65.55.116.90) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 19 Jan 2014 18:33:24 +0000 Received: from BLU0-SMTP42 ([65.55.116.73]) by blu0-omc3-s15.blu0.hotmail.com with Microsoft SMTPSVC(6.0.3790.4675); Sun, 19 Jan 2014 10:33:22 -0800 X-TMN: [jXIaEnBbPqUoYMDKSFpPKVjjONxNjaEJ] Message-ID: Received: from [192.168.2.10] ([69.158.170.59]) by BLU0-SMTP42.phx.gbl over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Sun, 19 Jan 2014 10:33:21 -0800 From: John David Anglin To: GCC Patches Subject: [committed] Fix length of long non-pic millicode calls on PA MIME-Version: 1.0 (Apple Message framework v936) Date: Sun, 19 Jan 2014 13:33:05 -0500 The attached change fixes a segmentation fault bootstrapping GCC on hppa2.0-hp-hpux11.11. The length of long non-pic millicode calls does not depend on TARGET_LONG_ABS_CALL. As a result, the length of long non-pic millicode calls was being overestimated. This broke the millicode call to $$sh_func_adrs. It has a couple of branches that branch past the call when a call isn't needed. Tested on hppa2.0w-hp-hpux11.11 and hppa-unknown-linux-gnu. Committed to active branches. Dave --- John David Anglin dave.anglin@bell.net 2014-01-19 John David Anglin * config/pa/pa.c (pa_attr_length_millicode_call): Correct length of long non-pic millicode calls. Index: config/pa/pa.c =================================================================== --- config/pa/pa.c (revision 206767) +++ config/pa/pa.c (working copy) @@ -7534,7 +7528,7 @@ if (!TARGET_LONG_CALLS && distance < MAX_PCREL17F_OFFSET) return 8; - if (TARGET_LONG_ABS_CALL && !flag_pic) + if (!flag_pic) return 12; return 24;