Re: Process record and replay checked in to main trunk

Eli Zaretskii
2009-05-05T19:01:44Z

> Date: Tue, 5 May 2009 21:39:50 +0800
> From: Hui Zhu <teawater@gmail.com>
> Cc: gdb-patches@sourceware.org
>
> On Mon, May 4, 2009 at 19:14, Eli Zaretskii <eliz@gnu.org> wrote:
> >> Date: Sun, 3 May 2009 21:54:19 +0800
> >> From: Hui Zhu <teawater@gmail.com>
> >> Cc: gdb-patches@sourceware.org
> >>
> > Right, but I was asking about another _x86_ target, not just any
> > target. Â Is there anything an i386 target needs to do to get process
> > record and replay work, except define suitable i386_intx80_record and
> > i386_sysenter_record functions?
>
> Yes, if they use sysenter or intx80 to be syscall. They need set
> these function pointers with themselves.
> If some os use another insn to be syscall. the prec in i386-tdep need
> update to support interface for it.

But if the i386_intx80_record and i386_sysenter_record are
Linux-specific interfaces, why they are visible in i386-tdep.c, which
is supposed to be common to all i386 targets?

Note that I don't mind so much the _names_, but you seem to say that
these names are somehow magical, and if, for example, syscalls on some
i386 target are entered through Int 31h (say), then there need to be a
separate member in the tdep structure called i386_intx31_record?

> Prec will not record the new value in forward execute because this
> value is in inferior.
> When reverse execute, prec wll record the new value and set old value
> to inferior.

Maybe I'm confused, but does this mean that if I need to replay a
portion of debugging session I need first to reverse-execute all the
recorded instructions until the point where I want to start replaying?