Enqueue signal even when resuming threads
authorYao Qi <yao.qi@linaro.org>
Thu, 21 Jul 2016 11:12:18 +0000 (12:12 +0100)
committerYao Qi <yao.qi@linaro.org>
Thu, 21 Jul 2016 11:12:18 +0000 (12:12 +0100)
commit0e9a339ec8ffab80fdbe97adaf888fe03b73fe22
treeec98676c0811dbdb1e1c3fd78ad975b80a36f76d
parent4281b351bfa3b646ab531cf73c56e49366fef108
Enqueue signal even when resuming threads

Nowadays, we only enqueue signal when we leave thread pending in
linux_resume_one_thread.  If lwp->resume->sig isn't zero (GDB wants
to resume with signal), we pass lwp->resume->sig to
linux_resume_one_lwp.

In order to reduce the difference between resuming thread with signal
and proceeding thread with signal, when we resume thread, we can
enqueue signal too, and proceed thread.  The signal will be consumed in
linux_resume_one_lwp_throw from lwp->pending_signals.

gdb/gdbserver:

2016-07-21  Yao Qi  <yao.qi@linaro.org>

* linux-low.c (proceed_one_lwp): Declare.
(linux_resume_one_thread): Remove local variable 'step'.
Lift code enqueue signal.  Call proceed_one_lwp instead of
linux_resume_one_lwp.
gdb/gdbserver/ChangeLog
gdb/gdbserver/linux-low.c