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: Simics & reverse execution


On 09/07/2009 09:24 AM, Jakob Engblom wrote:
going to be painful.  Time really becomes very pervasive once
you start using it in one place...

Intriguing. In what ways?


We currently have a somewhat baroque bunch of python that wraps up
gdb to enable our reverse debugging commands on users system where
they've an older version of gdb installed.  This includes some
commands to display the current time and jump to an arbitrary time
(where time is a scalar 64-bit integer).  The rest of gdb remains
blissfully unaware (obviously, since it's unpatched).

I can see how in general "teaching" the concept of time to gdb
would be a huge job.  But I don't think a command to jump around
arbitrarily and another to display the "current" time needs to
teach anything about time to the rest of gdb.

Think about the cross-product with thread handling. If you use time there, you need to determine how to handle times for threads. One timeline per thread? Or a global system time?

Oh right, yes, I was assuming global.


If time were per thread, then yes, I can see how that would quickly get
very complicated.


You also really like to have time breakpoints in the system, to allow you to do things like "run this system for 6.132 seconds and then stop" (typical operation we do when skipping a boot sequence or we have run a workload several times and know when itneresting things should start to happen).

I would argue that's a future feature. Time-based breakpoints would seem a very nice thing to have, but a system which had get/set time commands but no time breakpoints would be a lot more more useful than one with neither.


Also, how should this interact with non-stop debug? And how should you handle multiple active processor cores running parallel threads?

I must confess, I haven't given much thought at all to the interaction of non-stop debug with reverse debugging in general. I haven't been following too closely, but aren't they currently incompatible anyway? (something to do with displaced breakpoints not working well with reverse). But I don't see how it's any worse than the bookmarks case. In fact, I don't see how any of it differs from use with bookmarks. All we're really talking about is a different way to describe a point in history.

Again, you could go a lot further than I'm proposing right now.  But
that's not to say you need to for this stuff be useful.

Greg

--
Greg Law, Undo Software                       http://undo-software.com/


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