This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] stepi/nexti: skip signal handler if "handle nostop" signal arrives
- From: Pedro Alves <palves at redhat dot com>
- To: Yao Qi <yao at codesourcery dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Wed, 15 Oct 2014 14:44:49 +0100
- Subject: Re: [PATCH] stepi/nexti: skip signal handler if "handle nostop" signal arrives
- Authentication-results: sourceware.org; auth=none
- References: <1413308910-30423-1-git-send-email-palves at redhat dot com> <87oatdmvzd dot fsf at codesourcery dot com>
On 10/15/2014 12:08 PM, Yao Qi wrote:
> Pedro Alves <palves@redhat.com> writes:
>
>> I think that having to explain that "stepi" steps into handlers, (and
>> that "nexti" wouldn't according to my reasoning above), while "step"
>> does, is a sign of an awkward interface.
>>
>
> I suspect you meant "step" does NOT, right?
Gah. Indeed.
>
>> diff --git a/gdb/infrun.c b/gdb/infrun.c
>> index d61cc12..3682765 100644
>> --- a/gdb/infrun.c
>> +++ b/gdb/infrun.c
>> @@ -4455,7 +4455,8 @@ handle_signal_stop (struct execution_control_state *ecs)
>>
>> if (ecs->event_thread->control.step_range_end != 0
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> Is it still needed?
>
Hmm, yeah, looks like it never was.
>> && ecs->event_thread->suspend.stop_signal != GDB_SIGNAL_0
>> - && pc_in_thread_step_range (stop_pc, ecs->event_thread)
>> + && (pc_in_thread_step_range (stop_pc, ecs->event_thread)
>> + || ecs->event_thread->control.step_range_end == 1)
>> && frame_id_eq (get_stack_frame_id (frame),
>> ecs->event_thread->control.step_stack_frame_id)
>> && ecs->event_thread->control.step_resume_breakpoint == NULL)
Thanks,
Pedro Alves