-
Notifications
You must be signed in to change notification settings - Fork 641
Description
(Split out from #2877)
GDB has varying degrees of support for checkpoints and bookmarks:
- Checkpoints are currently specific to the
linux-nattarget and implemented usingfork(). The semantics are quite similar to rr checkpoints, being implemented in a similar way. A notable difference, however, is that an inferior exit from thelinux-nattarget will transparently revert the inferior state to the last checkpoint. - Bookmarks are part of GDB's target-generic reverse execution/debugging support. The target is expected to be able to provide an opaque byte buffer representing a particular point of execution that can be revisited at a later point. This seems fit
ReplayTimelinemarks quite neatly.
What combination of these makes sense for rr? Personally, I quite like keeping checkpoints more-or-less as they are and using lighter-weight rr proto-marks for GDB bookmarks, but I have trouble finding a compelling rationale for having both (beyond my desire to have an interface for proto-marks usable from GDB scripts); any meaning assigned to one relative to the other will probably be rather arbitrary.
Additionally, is fleshing out GDB's support for target-generic (and remote) checkpoints worth much to rr? The main benefits seem to be interface consistency and the potential to shed some hacks from rr, but bookmarks (in some form) may well be better for interface consistency and shedding hacks won't really be an option until there's almost no-one using rr with GDB <11/12/13/whenever.