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: [RFA] Reverse Debugging, 1/5


Joel Brobecker wrote:
Just, well, then target_set_execdir does not actually
set the exec direction -- instead it sort of tells you
if it's *ok* to set the exec direction -- which is what
I would think of as target_can_reverse.

I think that the overloading of the word target is making it very hard to understand each other.

Well, *something* is, that's for sure. Might just be early senility on my part... ;-)

Again, target_set_exec_dir would tell the inferior that, from now on,
the exec direction for all future resumes will be (forward|reverse).

But... Oh, I get it. You're right. It is the overloading of "target".


Joel, the inferior (in the sense of eg. gdbserver) doesn't have any
memory of the exec direction.  It's stateless.  Each message (eg.
'c' or 'bc') is unaffected by the previous one.

So if we remove the memory of the exec state from the target_ops
layer and transfer it to the infrun layer, then target_set_execdir
will have no semantics at all except "does this work".

If the target method is unset, then we know the feature is unsupported.
If it is set, and it fails, then refuse the change of direction -
feature not supported either.  Otherwise, update the infrun direction
with the new direction.

--
Joel


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