From patchwork Mon Aug 1 13:51:49 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 107739 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]) by ozlabs.org (Postfix) with SMTP id 4FC4AB7091 for ; Mon, 1 Aug 2011 23:52:16 +1000 (EST) Received: (qmail 21732 invoked by alias); 1 Aug 2011 13:52:07 -0000 Received: (qmail 21715 invoked by uid 22791); 1 Aug 2011 13:52:05 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW X-Spam-Check-By: sourceware.org Received: from mail-qy0-f175.google.com (HELO mail-qy0-f175.google.com) (209.85.216.175) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 01 Aug 2011 13:51:50 +0000 Received: by qyk30 with SMTP id 30so1006995qyk.20 for ; Mon, 01 Aug 2011 06:51:49 -0700 (PDT) MIME-Version: 1.0 Received: by 10.229.81.198 with SMTP id y6mr3315315qck.8.1312206709795; Mon, 01 Aug 2011 06:51:49 -0700 (PDT) Received: by 10.229.177.164 with HTTP; Mon, 1 Aug 2011 06:51:49 -0700 (PDT) In-Reply-To: References: <20110526175634.4bcab9b5@rex.config> Date: Mon, 1 Aug 2011 06:51:49 -0700 Message-ID: Subject: Re: [PATCH] ARM fixed-point support [5.5/6]: argument & return padding for libcalls From: "H.J. Lu" To: Julian Brown Cc: gcc-patches@gcc.gnu.org X-IsSubscribed: yes 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 On Mon, Aug 1, 2011 at 6:38 AM, H.J. Lu wrote: > On Thu, May 26, 2011 at 9:56 AM, Julian Brown wrote: >> This patch allows padding to be specified per-target for libcalls. This >> hasn't been traditionally important, because libcalls haven't accepted >> quantities which might need padding, but that's no longer true with the >> new(-ish) fixed-point support helper functions. >> >> Tested (alongside other fixed-point support patches) with cross to ARM >> EABI in both big & little-endian mode (the target-specific part is to >> avoid a behaviour change for half-float types on ARM). OK to apply? >> >> Thanks, >> >> Julian >> >> ChangeLog >> >>    gcc/ >>    * calls.c (emit_library_call_value_1): Support padding for libcall >>    arguments and return values. >>    * config/arm/arm.c (arm_pad_arg_upward): Pad half-float values >>    downwards in big-endian mode. > > This breaks bootstrap on Linux/x86: > > http://gcc.gnu.org/ml/gcc-regression/2011-08/msg00007.html > > ../../src-trunk/gcc/calls.c: In function 'rtx_def* > emit_library_call_value_1(int, rtx, rtx, libcall_type, machine_mode, > int, __va_list_tag*)': > ../../src-trunk/gcc/calls.c:3832:11: error: unused variable 'size' > [-Werror=unused-variable] > cc1plus: all warnings being treated as errors > > make[6]: *** [calls.o] Error 1 > I am testing this patch. diff --git a/gcc/calls.c b/gcc/calls.c index 7ad30b4..c4f8b46 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -3829,7 +3829,9 @@ emit_library_call_value_1 (int retval, rtx orgfun, rtx val ue, rtx val = argvec[argnum].value; rtx reg = argvec[argnum].reg; int partial = argvec[argnum].partial; +#ifdef BLOCK_REG_PADDING int size = 0; +#endif /* Handle calls that pass values in multiple non-contiguous