* configure.tgt: Mark v850 as multi-arched.
[deliverable/binutils-gdb.git] / gdb / arm-linux-tdep.c
index 145adbd708256563c25cd714df65801196b01951..29f11ae91bf88232e044fd8426756bae90a089d4 100644 (file)
@@ -30,7 +30,7 @@
 
 #include "arm-tdep.h"
 
-/* For arm_linux_skip_solib_resolver.  */
+/* For shared library handling.  */
 #include "symtab.h"
 #include "symfile.h"
 #include "objfiles.h"
@@ -60,14 +60,17 @@ LONGEST arm_linux_call_dummy_words[] =
 };
 
 /* Description of the longjmp buffer.  */
-#define JB_ELEMENT_SIZE                INT_REGISTER_RAW_SIZE
-#define JB_PC                  21
+#define ARM_LINUX_JB_ELEMENT_SIZE      INT_REGISTER_RAW_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.  */
-
-void
+/* 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,
                                char regbuf[REGISTER_BYTES],
                                char *valbuf)
@@ -101,7 +104,7 @@ arm_linux_extract_return_value (struct type *type,
 #define MAKE_THUMB_ADDR(addr)  ((addr) | 1)
 #define UNMAKE_THUMB_ADDR(addr) ((addr) & ~1)
          
-CORE_ADDR
+static CORE_ADDR
 arm_linux_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
                          int struct_return, CORE_ADDR struct_addr)
 {
@@ -360,7 +363,7 @@ find_minsym_and_objfile (char *name, struct objfile **objfile_p)
       ALL_OBJFILE_MSYMBOLS (objfile, msym)
        {
          if (SYMBOL_NAME (msym)
-             && STREQ (SYMBOL_NAME (msym), name))
+             && strcmp (SYMBOL_NAME (msym), name) == 0)
            {
              *objfile_p = objfile;
              return msym;
@@ -521,8 +524,20 @@ arm_linux_init_abi (struct gdbarch_info info,
   tdep->arm_breakpoint = arm_linux_arm_le_breakpoint;
   tdep->arm_breakpoint_size = sizeof (arm_linux_arm_le_breakpoint);
 
-  tdep->jb_pc = JB_PC;
-  tdep->jb_elt_size = JB_ELEMENT_SIZE;
+  tdep->jb_pc = ARM_LINUX_JB_PC;
+  tdep->jb_elt_size = ARM_LINUX_JB_ELEMENT_SIZE;
+
+  set_gdbarch_call_dummy_words (gdbarch, arm_linux_call_dummy_words);
+  set_gdbarch_sizeof_call_dummy_words (gdbarch,
+                                      sizeof (arm_linux_call_dummy_words));
+
+  /* The following two overrides shouldn't be needed.  */
+  set_gdbarch_extract_return_value (gdbarch, arm_linux_extract_return_value);
+  set_gdbarch_push_arguments (gdbarch, arm_linux_push_arguments);
+
+  /* Shared library handling.  */
+  set_gdbarch_in_solib_call_trampoline (gdbarch, in_plt_section);
+  set_gdbarch_skip_trampoline_code (gdbarch, find_solib_trampoline_target);
 }
 
 void
This page took 0.023745 seconds and 4 git commands to generate.