This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [commit] LynxOS: Resume the same thread when receiving a thread create/exit event.


On 12/17/2012 11:26 AM, Joel Brobecker wrote:
> Before this patch, the ptid passed to lynx_resume was completely
> ignored, and we used the current_inferior. This resulted in trying
> to resume the inferior execution using the wrong ptid after having
> received a thread create/exit event, because the inferior_ptid
> was still set to the ptid prior to receiving the signal.
> 
> gdb/gdbserver/ChangeLog:
> 
>         * lynx-low.c (lynx_resume): Use the resume_info parameter
>         to determine the ptid for the lynx_ptrace call, unless
>         it is equal to minus_one_ptid, in which case we use the
>         ptid of the current_inferior.
>         (lynx_wait_1): After having received a thread create/exit
>         event, resume the inferior's execution using the signaling
>         thread's ptid, rather than the old ptid.
> 
> Tested on ppc-lynx5.
> 
> I hesitated a little before self-approving.  But it seemed sufficiently
> straightforward and enough of an improvement (in lynx_resume) that
> I allowed myself to go ahead. I will handle comments right away,
> if any.

Looks fine to me.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]