X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=gdbserver%2Flinux-aarch64-low.cc;h=08208ae4f4524a579b5f1bd7ea5afd2c103c9e24;hb=e54e59297a747bb4f396345aa090d43f155b5576;hp=37fe93c89591799748a20a0ec6b29198f6d9e2b8;hpb=809a0c354b97bbbcacbd99808f0e328b39614a8f;p=deliverable%2Fbinutils-gdb.git diff --git a/gdbserver/linux-aarch64-low.cc b/gdbserver/linux-aarch64-low.cc index 37fe93c895..08208ae4f4 100644 --- a/gdbserver/linux-aarch64-low.cc +++ b/gdbserver/linux-aarch64-low.cc @@ -79,6 +79,8 @@ public: int get_min_fast_tracepoint_insn_len () override; + struct emit_ops *emit_ops () override; + protected: void low_arch_setup () override; @@ -121,6 +123,12 @@ protected: void low_prepare_to_resume (lwp_info *lwp) override; int low_get_thread_area (int lwpid, CORE_ADDR *addrp) override; + + bool low_supports_range_stepping () override; + + bool low_supports_catch_syscall () override; + + void low_get_syscall_trapinfo (regcache *regcache, int *sysno) override; }; /* The singleton target ops object. */ @@ -764,10 +772,16 @@ aarch64_target::low_get_thread_area (int lwpid, CORE_ADDR *addrp) return 0; } -/* Implementation of linux_target_ops method "get_syscall_trapinfo". */ +bool +aarch64_target::low_supports_catch_syscall () +{ + return true; +} -static void -aarch64_get_syscall_trapinfo (struct regcache *regcache, int *sysno) +/* Implementation of linux target ops method "low_get_syscall_trapinfo". */ + +void +aarch64_target::low_get_syscall_trapinfo (regcache *regcache, int *sysno) { int use_64bit = register_size (regcache->tdesc, 0) == 8; @@ -3091,10 +3105,10 @@ static struct emit_ops aarch64_emit_ops_impl = aarch64_emit_ge_got, }; -/* Implementation of linux_target_ops method "emit_ops". */ +/* Implementation of target ops method "emit_ops". */ -static struct emit_ops * -aarch64_emit_ops (void) +emit_ops * +aarch64_target::emit_ops () { return &aarch64_emit_ops_impl; } @@ -3108,12 +3122,12 @@ aarch64_target::get_min_fast_tracepoint_insn_len () return 4; } -/* Implementation of linux_target_ops method "supports_range_stepping". */ +/* Implementation of linux target ops method "low_supports_range_stepping". */ -static int -aarch64_supports_range_stepping (void) +bool +aarch64_target::low_supports_range_stepping () { - return 1; + return true; } /* Implementation of target ops method "sw_breakpoint_from_kind". */ @@ -3153,22 +3167,6 @@ aarch64_target::breakpoint_kind_from_current_state (CORE_ADDR *pcptr) return arm_breakpoint_kind_from_current_state (pcptr); } -/* Support for hardware single step. */ - -static int -aarch64_supports_hardware_single_step (void) -{ - return 1; -} - -struct linux_target_ops the_low_target = -{ - aarch64_emit_ops, - aarch64_supports_range_stepping, - aarch64_supports_hardware_single_step, - aarch64_get_syscall_trapinfo, -}; - /* The linux target ops object. */ linux_process_target *the_linux_target = &the_aarch64_target;