From: Andrew Cagney Date: Thu, 28 Jun 2001 21:48:41 +0000 (+0000) Subject: From Fernando Nasser: X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=100a02e1deec2f037a15cdf232f026dc79763bf8;p=binutils-gdb.git From Fernando Nasser: * infrun.c (handle_inferior_event): Handle "nexti" inside function prologues. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 22de49948db..06468ba7b08 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2001-06-28 Andrew Cagney + + From Fernando Nasser: + * infrun.c (handle_inferior_event): Handle "nexti" inside function + prologues. + 2001-06-28 Michael Snyder * infrun.c (handle_inferior_event): Replace prev_pc test in all diff --git a/gdb/infrun.c b/gdb/infrun.c index 972b0930a74..e3556229473 100644 --- a/gdb/infrun.c +++ b/gdb/infrun.c @@ -2755,11 +2755,16 @@ handle_inferior_event (struct execution_control_state *ecs) { /* It's a subroutine call. */ - if (step_over_calls == STEP_OVER_NONE) + if ((step_over_calls == STEP_OVER_NONE) + || ((step_range_end == 1) + && in_prologue (prev_pc, ecs->stop_func_start))) { /* I presume that step_over_calls is only 0 when we're supposed to be stepping at the assembly language level ("stepi"). Just stop. */ + /* Also, maybe we just did a "nexti" inside a prolog, + so we thought it was a subroutine call but it was not. + Stop as well. FENN */ stop_step = 1; print_stop_reason (END_STEPPING_RANGE, 0); stop_stepping (ecs);