]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blobdiff - gdb/arm-wince-tdep.c
Add R_AARCH64_P32_MOVW_PREL_* ELF32 relocs
[thirdparty/binutils-gdb.git] / gdb / arm-wince-tdep.c
index a2a53726d5dad39f51171f16a23d1fb0726ea359..6eae60e8a7fda8ea4438914967e8e03184b0dd72 100644 (file)
@@ -1,7 +1,7 @@
 /* Target-dependent code for Windows CE running on ARM processors,
    for GDB.
 
-   Copyright (C) 2007-2014 Free Software Foundation, Inc.
+   Copyright (C) 2007-2019 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -24,8 +24,7 @@
 #include "target.h"
 #include "frame.h"
 
-#include <string.h>
-
+#include "arch/arm.h"
 #include "arm-tdep.h"
 #include "windows-tdep.h"
 
@@ -47,9 +46,12 @@ arm_pe_skip_trampoline_code (struct frame_info *frame, CORE_ADDR pc)
   CORE_ADDR next_pc;
 
   /* The format of an ARM DLL trampoline is:
+
        ldr  ip, [pc]
        ldr  pc, [ip]
-       .dw __imp_<func>  */
+       .dw __imp_<func>
+
+  */
 
   if (pc == 0
       || read_memory_unsigned_integer (pc + 0, 4, byte_order) != 0xe59fc000
@@ -65,7 +67,7 @@ arm_pe_skip_trampoline_code (struct frame_info *frame, CORE_ADDR pc)
     return 0;
 
   symname = MSYMBOL_LINKAGE_NAME (indsym.minsym);
-  if (symname == NULL || strncmp (symname, "__imp_", 6) != 0)
+  if (symname == NULL || !startswith (symname, "__imp_"))
     return 0;
 
   next_pc = read_memory_unsigned_integer (indirect, 4, byte_order);
@@ -152,9 +154,6 @@ arm_wince_osabi_sniffer (bfd *abfd)
   return GDB_OSABI_UNKNOWN;
 }
 
-/* Provide a prototype to silence -Wmissing-prototypes.  */
-void _initialize_arm_wince_tdep (void);
-
 void
 _initialize_arm_wince_tdep (void)
 {