This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: [discuss] Support for reverse-execution
- From: "Eli Zaretskii" <eliz at gnu dot org>
- To: "Michael Snyder" <msnyder at redhat dot com>
- Cc: gdb at sources dot redhat dot com
- Date: Fri, 13 May 2005 09:19:17 +0300
- Subject: Re: [discuss] Support for reverse-execution
- References: <00c601c55747$860a3e80$aaa56b80@msnyder8600>
- Reply-to: Eli Zaretskii <eliz at gnu dot org>
> From: "Michael Snyder" <msnyder@redhat.com>
> Date: Thu, 12 May 2005 16:08:34 -0700
>
> I'd like to start adding some commands to gdb to support targets
> that can perform reverse execution (eg. stepping backwards).
> This concept has been around for a number of years now, and I
> have access to a target (the Simics simulator from Virtutech)
> that does it quite handily.
Sounds like a great idea.
> I propose we add something like the following commands
> (names open to discussion):
>
> reverse-continue -- start executing backwards until something
> interesting happens (most likely hitting a breakpoint).
>
> reverse-stepi -- "un-execute" the previous instruction.
>
> reverse-step -- "un-execute" the previous source line.
>
> reverse-finish or "un-call" -- proceed backward until
> the current function is about to be called by its caller.
>
> reverse-until... etc.
Not "reverse", "backwards" or "back". "Reverse" will become ambiguous
once we have two possible directions.
> Along with these commands, we would need at least two new
> remote-protocol messages: "rc" for reverse-continue, and "rs"
> for reverse-stepi. I think all of the above user commands could
> be implemented on these primatives. Obviously if the remote
> target doesn't understand these primatives, the user command
> would error.
>
> Finally, we'd need a new entry for the target vector --
> something like "to_resume_backwards". If the target vector
> doesn't export this method, the user command would error.
Please don't forget the manual changes for these features.