This is the mail archive of the gdb@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: [discuss] semantics, "replay debugging" vs. "reverse debugging"


> > One could have reverse without record/replay if,
> > for instance, one had a machine architecture where
> > all instructions were reversable, ie. the machine
> > itself could reverse-execute an instruction.
> 
> I think maybe some instruction can do it.
> Such as add instruction. When it forward execute, it add some number
> to a value of register. When it reverse, it can sub this number from
> the value of register. It can reverse without record.
> 
> In P record, I make a interface to use it in record_t need_dasm. But I
> still not use it. Maybe I can use it in the future.

When thinking about overflow semantics, etc., it is clear that this can never
work in general.  

The easiest way to create a reversible system is to 

1. Impose determinisim

2. Make sure you can get back to a previous state

And then you simply jump back and reexecute until some chosen point in time.
Works like a charm, and is very general.

/jakob


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