From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12462 invoked by alias); 8 Feb 2002 16:13:53 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 12299 invoked from network); 8 Feb 2002 16:13:49 -0000 Received: from unknown (HELO cygnus.com) (205.180.230.5) by sources.redhat.com with SMTP; 8 Feb 2002 16:13:49 -0000 Received: from cygbert.vinschen.de (cse.cygnus.com [205.180.230.236]) by runyon.cygnus.com (8.8.7-cygnus/8.8.7) with ESMTP id IAA10027 for ; Fri, 8 Feb 2002 08:13:08 -0800 (PST) Received: (from corinna@localhost) by cygbert.vinschen.de (8.11.6/8.9.3/Linux sendmail 8.9.3) id g18GD6M16651 for gdb-patches@sources.redhat.com; Fri, 8 Feb 2002 17:13:06 +0100 Date: Fri, 08 Feb 2002 08:13:00 -0000 From: Corinna Vinschen To: gdb-patches Subject: Re: [RFA]: ARM: Fix parameter handling of FP types in arm_push_arguments() Message-ID: <20020208171305.T14241@cygbert.vinschen.de> Reply-To: gdb-patches Mail-Followup-To: gdb-patches References: <20020208164956.R14241@cygbert.vinschen.de> <200202081605.QAA01859@cam-mail2.cambridge.arm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200202081605.QAA01859@cam-mail2.cambridge.arm.com> User-Agent: Mutt/1.3.22.1i X-SW-Source: 2002-02/txt/msg00231.txt.bz2 On Fri, Feb 08, 2002 at 04:05:13PM +0000, Richard Earnshaw wrote: > > Hi, > > > > while running the testsuite on ARM, I found that the handling > > of type `float' as argument type in the function arm_push_arguments() > > is pretty buggy. > > > > For some reason the size of float arguments was always given as > > sizeof(float) even when K&R style functions are called which > > expect the float arguments with sizeof(double). > > Up to this point one would expect that calling K&R functions with > > float arguments is broken. > > > > As a matter of fact, arm_push_arguments() coerced float args > > always to double types so that K&R functions were happy while > > calling ANSI style functions getting float args were broken. > > > > The below fix is doing two things now. > > > > - It adds the macro COERCE_FLOAT_TO_DOUBLE() to config/arm/tm-arm.h, > > calling standard_coerce_float_to_double(). This results in > > floats being coerced to double already *before* arm_push_arguments() > > is called. > > > > - It eliminates the now useless (and wrong) special float handling > > from arm_push_arguments(). > > > > Corinna > > > > 2002-02-08 Corinna Vinschen > > > > * arm-tdep.c (arm_push_arguments): Eliminate special float > > type handling. > > * config/arm/tm-arm.h (COERCE_FLOAT_TO_DOUBLE): Define to > > call standard_coerce_float_to_double(). > > This looks good to me. Is there a anything in the testsuite that is fixed > by this? If not, can you provide one. Together with the "Fix FP handling for non-multiarched targets" patch from a few minutes ago this fixes at least the FAILs in callfuncs.exp, display.exp and oct.exp. I don't have the whole list handy by now. Corinna -- Corinna Vinschen Cygwin Developer Red Hat, Inc. mailto:vinschen@redhat.com