X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdbserver%2Flinux-arm-low.cc;h=fb5b761a833aea343563b3c45770969658b95083;hb=eea9e35758138f83e8c44e0e5a5e47e351f8f31a;hp=383f217277add4953ae31e5b28af96ccac6d9c14;hpb=47f70aa7685c0a7fad4ca76964a4199a5b5edd1c;p=deliverable%2Fbinutils-gdb.git diff --git a/gdbserver/linux-arm-low.cc b/gdbserver/linux-arm-low.cc index 383f217277..fb5b761a83 100644 --- a/gdbserver/linux-arm-low.cc +++ b/gdbserver/linux-arm-low.cc @@ -72,6 +72,8 @@ public: bool supports_z_point_type (char z_type) override; + bool supports_hardware_single_step () override; + protected: void low_arch_setup () override; @@ -111,6 +113,10 @@ protected: void low_new_fork (process_info *parent, process_info *child) override; void low_prepare_to_resume (lwp_info *lwp) override; + + bool low_supports_catch_syscall () override; + + void low_get_syscall_trapinfo (regcache *regcache, int *sysno) override; }; /* The singleton target ops object. */ @@ -1030,16 +1036,22 @@ arm_target::low_get_next_pcs (regcache *regcache) /* Support for hardware single step. */ -static int -arm_supports_hardware_single_step (void) +bool +arm_target::supports_hardware_single_step () +{ + return false; +} + +bool +arm_target::low_supports_catch_syscall () { - return 0; + return true; } -/* Implementation of linux_target_ops method "get_syscall_trapinfo". */ +/* Implementation of linux target ops method "low_get_syscall_trapinfo". */ -static void -arm_get_syscall_trapinfo (struct regcache *regcache, int *sysno) +void +arm_target::low_get_syscall_trapinfo (regcache *regcache, int *sysno) { if (arm_is_thumb_mode ()) collect_register_by_name (regcache, "r7", sysno); @@ -1050,7 +1062,7 @@ arm_get_syscall_trapinfo (struct regcache *regcache, int *sysno) collect_register_by_name (regcache, "pc", &pc); - if (the_target->read_memory (pc - 4, (unsigned char *) &insn, 4)) + if (read_memory (pc - 4, (unsigned char *) &insn, 4)) *sysno = UNKNOWN_SYSCALL; else { @@ -1116,16 +1128,6 @@ arm_target::get_regs_info () return ®s_info_arm; } -struct linux_target_ops the_low_target = { - NULL, /* get_thread_area */ - NULL, /* install_fast_tracepoint_jump_pad */ - NULL, /* emit_ops */ - NULL, /* get_min_fast_tracepoint_insn_len */ - NULL, /* supports_range_stepping */ - arm_supports_hardware_single_step, - arm_get_syscall_trapinfo, -}; - /* The linux target ops object. */ linux_process_target *the_linux_target = &the_arm_target;