gdbserver/linux-low: turn 'cannot_{fetch/store}_register' into methods
[deliverable/binutils-gdb.git] / gdbserver / linux-ia64-low.cc
index 169a567d67b5216ceef4a14787056e2f56650f68..471530a621bffff4c215811148c4d4eccae53bff 100644 (file)
@@ -29,6 +29,15 @@ class ia64_target : public linux_process_target
 {
 public:
 
+  const regs_info *get_regs_info () override;
+
+protected:
+
+  void low_arch_setup () override;
+
+  bool low_cannot_fetch_register (int regno) override;
+
+  bool low_cannot_store_register (int regno) override;
 };
 
 /* The singleton target ops object.  */
@@ -278,16 +287,16 @@ static int ia64_regmap[] =
     -1,
   };
 
-static int
-ia64_cannot_store_register (int regno)
+bool
+ia64_target::low_cannot_store_register (int regno)
 {
-  return 0;
+  return false;
 }
 
-static int
-ia64_cannot_fetch_register (int regno)
+bool
+ia64_target::low_cannot_fetch_register (int regno)
 {
-  return 0;
+  return false;
 }
 
 /* GDB register numbers.  */
@@ -338,30 +347,26 @@ static struct usrregs_info ia64_usrregs_info =
     ia64_regmap,
   };
 
-static struct regs_info regs_info =
+static struct regs_info myregs_info =
   {
     NULL, /* regset_bitmap */
     &ia64_usrregs_info
   };
 
-static const struct regs_info *
-ia64_regs_info (void)
+const regs_info *
+ia64_target::get_regs_info ()
 {
-  return &regs_info;
+  return &myregs_info;
 }
 
-static void
-ia64_arch_setup (void)
+void
+ia64_target::low_arch_setup ()
 {
   current_process ()->tdesc = tdesc_ia64;
 }
 
 
 struct linux_target_ops the_low_target = {
-  ia64_arch_setup,
-  ia64_regs_info,
-  ia64_cannot_fetch_register,
-  ia64_cannot_store_register,
   ia64_fetch_register,
 };
 
This page took 0.043411 seconds and 4 git commands to generate.