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: [RFC] Add support of software single step to process record


Hi Hui,

> 3.  Ping got some gdb_assert in sometime.  And I am not close to his
> board.  So I didn't know what happen.  So I add following:
> @@ -1534,7 +1535,8 @@ a command like `return' or `jump' to con
>        /* If STEP is set, it's a request to use hardware stepping
>  	 facilities.  But in that case, we should never
>  	 use singlestep breakpoint.  */
> -      gdb_assert (!(singlestep_breakpoints_inserted_p && step));
> +      gdb_assert (!(execution_direction == EXEC_FORWARD
> +                    && singlestep_breakpoints_inserted_p && step));
> 
> The lost one still need be test.

I'm felling a bit dense, and I don't see what is that actually
catching.  If going backwards, the assertion always ends up
evaled as true, nomatter if sofware single-steps are inserted
or not, or whether `step' is set.  Did you mean to assert
that when going backwards, there shouldn't ever be software
single-step breakpoints inserted?

This patch is okay otherwise.  Thanks.

-- 
Pedro Alves


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