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.
This commit is contained in:
Andreas Arnez
2016-09-16 19:25:55 +02:00
parent 169fe0df15
commit 0e00e962c5
5 changed files with 30 additions and 0 deletions

View File

@@ -355,6 +355,14 @@ lwp_stop_reason (struct lwp_info *lwp)
return lwp->stop_reason;
}
/* See nat/linux-nat.h. */
int
lwp_is_stepping (struct lwp_info *lwp)
{
return lwp->step;
}
/* Trivial list manipulation functions to keep track of a list of
new stopped processes. */