From 0e00e962c57138f0dd8c261cbd6918782deec3c4 Mon Sep 17 00:00:00 2001 From: Andreas Arnez Date: Fri, 16 Sep 2016 19:25:55 +0200 Subject: linux-nat: Add function lwp_is_stepping Add the function lwp_is_stepping which indicates whether the given LWP is currently single-stepping. This is a common interface, usable from native GDB as well as from gdbserver. gdb/gdbserver/ChangeLog: * linux-low.c (lwp_is_stepping): New function. gdb/ChangeLog: * nat/linux-nat.h (lwp_is_stepping): New declaration. * linux-nat.c (lwp_is_stepping): New function. --- gdb/nat/linux-nat.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'gdb/nat') diff --git a/gdb/nat/linux-nat.h b/gdb/nat/linux-nat.h index 2b485db..529cf26 100644 --- a/gdb/nat/linux-nat.h +++ b/gdb/nat/linux-nat.h @@ -85,4 +85,9 @@ extern enum target_stop_reason lwp_stop_reason (struct lwp_info *lwp); extern void linux_stop_lwp (struct lwp_info *lwp); +/* Return nonzero if we are single-stepping this LWP at the ptrace + level. */ + +extern int lwp_is_stepping (struct lwp_info *lwp); + #endif /* LINUX_NAT_H */ -- cgit v1.1