void low_set_pc (regcache *regcache, CORE_ADDR newpc) override;
bool low_breakpoint_at (CORE_ADDR pc) override;
+
+ int low_insert_point (raw_bkpt_type type, CORE_ADDR addr,
+ int size, raw_breakpoint *bp) override;
+
+ int low_remove_point (raw_bkpt_type type, CORE_ADDR addr,
+ int size, raw_breakpoint *bp) override;
+
+ bool low_stopped_by_watchpoint () override;
+
+ CORE_ADDR low_stopped_data_address () override;
+
+ bool low_siginfo_fixup (siginfo_t *native, gdb_byte *inf,
+ int direction) override;
+
+ arch_process_info *low_new_process () override;
+
+ void low_delete_process (arch_process_info *info) override;
+
+ void low_new_thread (lwp_info *) override;
+
+ void low_delete_thread (arch_lwp_info *) override;
+
+ void low_new_fork (process_info *parent, process_info *child) override;
+
+ void low_prepare_to_resume (lwp_info *lwp) override;
};
/* The singleton target ops object. */
"is not implemented by the target");
}
+void
+aarch64_target::low_prepare_to_resume (lwp_info *lwp)
+{
+ aarch64_linux_prepare_to_resume (lwp);
+}
+
/* Per-process arch-specific data we want to keep. */
struct arch_process_info
}
}
-/* Implementation of linux_target_ops method "insert_point".
+/* Implementation of linux target ops method "low_insert_point".
It actually only records the info of the to-be-inserted bp/wp;
the actual insertion will happen when threads are resumed. */
-static int
-aarch64_insert_point (enum raw_bkpt_type type, CORE_ADDR addr,
- int len, struct raw_breakpoint *bp)
+int
+aarch64_target::low_insert_point (raw_bkpt_type type, CORE_ADDR addr,
+ int len, raw_breakpoint *bp)
{
int ret;
enum target_hw_bp_type targ_type;
return ret;
}
-/* Implementation of linux_target_ops method "remove_point".
+/* Implementation of linux target ops method "low_remove_point".
It actually only records the info of the to-be-removed bp/wp,
the actual removal will be done when threads are resumed. */
-static int
-aarch64_remove_point (enum raw_bkpt_type type, CORE_ADDR addr,
- int len, struct raw_breakpoint *bp)
+int
+aarch64_target::low_remove_point (raw_bkpt_type type, CORE_ADDR addr,
+ int len, raw_breakpoint *bp)
{
int ret;
enum target_hw_bp_type targ_type;
return ret;
}
-/* Implementation of linux_target_ops method "stopped_data_address". */
+/* Implementation of linux target ops method "low_stopped_data_address". */
-static CORE_ADDR
-aarch64_stopped_data_address (void)
+CORE_ADDR
+aarch64_target::low_stopped_data_address ()
{
siginfo_t siginfo;
int pid, i;
return (CORE_ADDR) 0;
}
-/* Implementation of linux_target_ops method "stopped_by_watchpoint". */
+/* Implementation of linux target ops method "low_stopped_by_watchpoint". */
-static int
-aarch64_stopped_by_watchpoint (void)
+bool
+aarch64_target::low_stopped_by_watchpoint ()
{
- if (aarch64_stopped_data_address () != 0)
- return 1;
- else
- return 0;
+ return (low_stopped_data_address () != 0);
}
/* Fetch the thread-local storage pointer for libthread_db. */
is_64bit_tdesc ());
}
-/* Implementation of linux_target_ops method "siginfo_fixup". */
+/* Implementation of linux target ops method "low_siginfo_fixup". */
-static int
-aarch64_linux_siginfo_fixup (siginfo_t *native, gdb_byte *inf, int direction)
+bool
+aarch64_target::low_siginfo_fixup (siginfo_t *native, gdb_byte *inf,
+ int direction)
{
/* Is the inferior 32-bit? If so, then fixup the siginfo object. */
if (!is_64bit_tdesc ())
aarch64_siginfo_from_compat_siginfo (native,
(struct compat_siginfo *) inf);
- return 1;
+ return true;
}
- return 0;
+ return false;
}
-/* Implementation of linux_target_ops method "new_process". */
+/* Implementation of linux target ops method "low_new_process". */
-static struct arch_process_info *
-aarch64_linux_new_process (void)
+arch_process_info *
+aarch64_target::low_new_process ()
{
struct arch_process_info *info = XCNEW (struct arch_process_info);
return info;
}
-/* Implementation of linux_target_ops method "delete_process". */
+/* Implementation of linux target ops method "low_delete_process". */
-static void
-aarch64_linux_delete_process (struct arch_process_info *info)
+void
+aarch64_target::low_delete_process (arch_process_info *info)
{
xfree (info);
}
-/* Implementation of linux_target_ops method "linux_new_fork". */
+void
+aarch64_target::low_new_thread (lwp_info *lwp)
+{
+ aarch64_linux_new_thread (lwp);
+}
-static void
-aarch64_linux_new_fork (struct process_info *parent,
- struct process_info *child)
+void
+aarch64_target::low_delete_thread (arch_lwp_info *arch_lwp)
+{
+ aarch64_linux_delete_thread (arch_lwp);
+}
+
+/* Implementation of linux target ops method "low_new_fork". */
+
+void
+aarch64_target::low_new_fork (process_info *parent,
+ process_info *child)
{
/* These are allocated by linux_add_process. */
gdb_assert (parent->priv != NULL
struct linux_target_ops the_low_target =
{
- aarch64_insert_point,
- aarch64_remove_point,
- aarch64_stopped_by_watchpoint,
- aarch64_stopped_data_address,
- NULL, /* collect_ptrace_register */
- NULL, /* supply_ptrace_register */
- aarch64_linux_siginfo_fixup,
- aarch64_linux_new_process,
- aarch64_linux_delete_process,
- aarch64_linux_new_thread,
- aarch64_linux_delete_thread,
- aarch64_linux_new_fork,
- aarch64_linux_prepare_to_resume,
- NULL, /* process_qsupported */
aarch64_supports_tracepoints,
aarch64_get_thread_area,
aarch64_install_fast_tracepoint_jump_pad,