dwarf2read: Replace copy_string usages with savestring
[deliverable/binutils-gdb.git] / gdb / microblaze-tdep.c
index ea33ae7dfcb1b6fa79658893a52588e5986fef64..7547581c63a59e93392bd02e635da6def4392b56 100644 (file)
@@ -1,6 +1,6 @@
 /* Target-dependent code for Xilinx MicroBlaze.
 
-   Copyright (C) 2009-2016 Free Software Foundation, Inc.
+   Copyright (C) 2009-2017 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -134,9 +134,9 @@ microblaze_fetch_instruction (CORE_ADDR pc)
   return extract_unsigned_integer (buf, 4, byte_order);
 }
 \f
-static gdb_byte break_insn[] = MICROBLAZE_BREAKPOINT;
+constexpr gdb_byte microblaze_break_insn[] = MICROBLAZE_BREAKPOINT;
 
-GDBARCH_BREAKPOINT_MANIPULATION (microblaze, break_insn)
+typedef BP_MANIPULATION (microblaze_break_insn) microblaze_breakpoint;
 
 \f
 /* Allocate and initialize a frame cache.  */
@@ -703,7 +703,7 @@ microblaze_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
     }
 
   /* Allocate space for the new architecture.  */
-  tdep = XNEW (struct gdbarch_tdep);
+  tdep = XCNEW (struct gdbarch_tdep);
   gdbarch = gdbarch_alloc (&info, tdep);
 
   set_gdbarch_long_double_bit (gdbarch, 128);
@@ -731,12 +731,13 @@ microblaze_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   /* Stack grows downward.  */
   set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
 
-  SET_GDBARCH_BREAKPOINT_MANIPULATION (microblaze);
+  set_gdbarch_breakpoint_kind_from_pc (gdbarch,
+                                      microblaze_breakpoint::kind_from_pc);
+  set_gdbarch_sw_breakpoint_from_kind (gdbarch,
+                                      microblaze_breakpoint::bp_from_kind);
 
   set_gdbarch_frame_args_skip (gdbarch, 8);
 
-  set_gdbarch_print_insn (gdbarch, print_insn_microblaze);
-
   set_gdbarch_write_pc (gdbarch, microblaze_write_pc);
 
   set_gdbarch_unwind_pc (gdbarch, microblaze_unwind_pc);
@@ -758,9 +759,6 @@ microblaze_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   return gdbarch;
 }
 
-/* Provide a prototype to silence -Wmissing-prototypes.  */
-void _initialize_microblaze_tdep (void);
-
 void
 _initialize_microblaze_tdep (void)
 {
This page took 0.025525 seconds and 4 git commands to generate.