Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* Get rid of arm_linux_extract_return_value
@ 2007-01-01 11:33 Mark Kettenis
  2007-01-03 18:43 ` Daniel Jacobowitz
  0 siblings, 1 reply; 3+ messages in thread
From: Mark Kettenis @ 2007-01-01 11:33 UTC (permalink / raw)
  To: gdb-patches

Can someone with access to a Linux ARM platform please test this?

I'm considering to just commit this in two weeks if nobody does.  I
mean, come on, there are at least a couple of commercial entities that
rely on this code, and nobody has body to clean it up anywhere in the
last four years.

Index: ChangeLog
from  Mark Kettenis  <kettenis@gnu.org>

	* arm-linux-tdep.c (arm_linux_extract_return_value): Remove.
	(arm_linux_init_abi): Don't set deprecated_extract_return_value.

Index: arm-linux-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/arm-linux-tdep.c,v
retrieving revision 1.55
diff -u -p -r1.55 arm-linux-tdep.c
--- arm-linux-tdep.c 12 Jul 2006 20:46:32 -0000 1.55
+++ arm-linux-tdep.c 1 Jan 2007 11:25:35 -0000
@@ -1,6 +1,6 @@
 /* GNU/Linux on ARM target support.
 
-   Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+   Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
    Free Software Foundation, Inc.
 
    This file is part of GDB.
@@ -74,29 +74,6 @@ static const char arm_linux_thumb_le_bre
 #define ARM_LINUX_JB_ELEMENT_SIZE	INT_REGISTER_SIZE
 #define ARM_LINUX_JB_PC			21
 
-/* Extract from an array REGBUF containing the (raw) register state
-   a function return value of type TYPE, and copy that, in virtual format,
-   into VALBUF.  */
-/* FIXME rearnsha/2002-02-23: This function shouldn't be necessary.
-   The ARM generic one should be able to handle the model used by
-   linux and the low-level formatting of the registers should be
-   hidden behind the regcache abstraction.  */
-static void
-arm_linux_extract_return_value (struct type *type,
-				gdb_byte regbuf[],
-				gdb_byte *valbuf)
-{
-  /* ScottB: This needs to be looked at to handle the different
-     floating point emulators on ARM GNU/Linux.  Right now the code
-     assumes that fetch inferior registers does the right thing for
-     GDB.  I suspect this won't handle NWFPE registers correctly, nor
-     will the default ARM version (arm_extract_return_value()).  */
-
-  int regnum = ((TYPE_CODE_FLT == TYPE_CODE (type))
-		? ARM_F0_REGNUM : ARM_A1_REGNUM);
-  memcpy (valbuf, &regbuf[DEPRECATED_REGISTER_BYTE (regnum)], TYPE_LENGTH (type));
-}
-   	  
 /*
    Dynamic Linking on ARM GNU/Linux
    --------------------------------
@@ -628,9 +605,6 @@ arm_linux_init_abi (struct gdbarch_info 
   set_solib_svr4_fetch_link_map_offsets
     (gdbarch, svr4_ilp32_fetch_link_map_offsets);
 
-  /* The following override shouldn't be needed.  */
-  set_gdbarch_deprecated_extract_return_value (gdbarch, arm_linux_extract_return_value);
-
   /* Shared library handling.  */
   set_gdbarch_skip_trampoline_code (gdbarch, find_solib_trampoline_target);
   set_gdbarch_skip_solib_resolver (gdbarch, glibc_skip_solib_resolver);


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Get rid of arm_linux_extract_return_value
  2007-01-01 11:33 Get rid of arm_linux_extract_return_value Mark Kettenis
@ 2007-01-03 18:43 ` Daniel Jacobowitz
  2007-01-03 21:07   ` Mark Kettenis
  0 siblings, 1 reply; 3+ messages in thread
From: Daniel Jacobowitz @ 2007-01-03 18:43 UTC (permalink / raw)
  To: Mark Kettenis; +Cc: gdb-patches

On Mon, Jan 01, 2007 at 12:33:09PM +0100, Mark Kettenis wrote:
> Can someone with access to a Linux ARM platform please test this?
> 
> I'm considering to just commit this in two weeks if nobody does.  I
> mean, come on, there are at least a couple of commercial entities that
> rely on this code, and nobody has body to clean it up anywhere in the
> last four years.

If part of that was aimed my direction, we actually don't - this is
strictly old ABI code, and we only work with the EABI nowadays.
And in fact don't have handy test configurations for the old ABI,
which is how I never got around to it.  This prompted me to set one
up though.

> Index: ChangeLog
> from  Mark Kettenis  <kettenis@gnu.org>
> 
> 	* arm-linux-tdep.c (arm_linux_extract_return_value): Remove.
> 	(arm_linux_init_abi): Don't set deprecated_extract_return_value.

Tests out fine on arm-linux, both -marm and -mthumb.  Thanks.

-- 
Daniel Jacobowitz
CodeSourcery


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Get rid of arm_linux_extract_return_value
  2007-01-03 18:43 ` Daniel Jacobowitz
@ 2007-01-03 21:07   ` Mark Kettenis
  0 siblings, 0 replies; 3+ messages in thread
From: Mark Kettenis @ 2007-01-03 21:07 UTC (permalink / raw)
  To: drow; +Cc: gdb-patches

> Date: Wed, 3 Jan 2007 13:43:21 -0500
> From: Daniel Jacobowitz <drow@false.org>
> 
> On Mon, Jan 01, 2007 at 12:33:09PM +0100, Mark Kettenis wrote:
> > Can someone with access to a Linux ARM platform please test this?
> > 
> > I'm considering to just commit this in two weeks if nobody does.  I
> > mean, come on, there are at least a couple of commercial entities that
> > rely on this code, and nobody has body to clean it up anywhere in the
> > last four years.
> 
> If part of that was aimed my direction, we actually don't - this is
> strictly old ABI code, and we only work with the EABI nowadays.
> And in fact don't have handy test configurations for the old ABI,
> which is how I never got around to it.  This prompted me to set one
> up though.

Yes, Codesourcery was one of the entities I had in mind.  Thanks for
doing this!

> > Index: ChangeLog
> > from  Mark Kettenis  <kettenis@gnu.org>
> > 
> > 	* arm-linux-tdep.c (arm_linux_extract_return_value): Remove.
> > 	(arm_linux_init_abi): Don't set deprecated_extract_return_value.

Committed.

Mark


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-01-03 21:07 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-01 11:33 Get rid of arm_linux_extract_return_value Mark Kettenis
2007-01-03 18:43 ` Daniel Jacobowitz
2007-01-03 21:07   ` Mark Kettenis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox