question about reverse debugging

Ren Kimura rkx1209dev at
Tue Mar 14 10:24:25 UTC 2017

2017-03-14 18:23 GMT+09:00 Robert O'Callahan <robert at>:

> On Tue, Mar 14, 2017 at 9:37 PM, Ren Kimura <rkx1209dev at> wrote:
> > Thank you for replaying.
> >
> > OK. After restoring from a checkpoint, all operations between the
> checkpoint
> > and desired point should be emulated.
> > What function is doing that and how?
> At a high level, `ReplayTimeline::reverse_singlestep` and
> `ReplayTimeline::reverse_continue` work out where to go back to and
> then call`ReplayTimeline::replay_step_to_mark` to get there. But that
> relies on a series of calls to `ReplaySession::replay_step` which is
> where the core work to replay a session happens

So this means that Recorder has already recorded all events, like
reading/writing register, memory per operation
and Replayer replay these by replay_steps' to get desired point?

Recorder seems to use RecordTask::record_* and TraceWriter::write_* to
record each events.
But which function records above events?

For example, when Recorder see 'mov eax, 0x100' operation, which part of
RecordTask records execution log like 'writing 0x100 to eax register'?

> > I'm little confused about how actual operations are executed until
> desired
> > point without debugee process.
> If you're asking how replay works in general, there are some talks
> online that might be helpful. E.g.

Sorry for asking question many times.

Thank you.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the rr-dev mailing list