John Bethell writes: "UndoDB, the smart debugger for Linux gets smarter — Reversible debugger for Linux gets support for threads and signals FOR IMMEDIATE RELEASE Cambridge, UK — March 12, 2007. Jacob Rideout is a developer on the prestigious KDE project. After struggling for over a week with a particularly nasty bug, he turned to UndoDB: the reversible debugger for Linux applications. He says of the experience: "I found the idea of [the] product amazing and a boon to my productivity
... I already have been able to fix a deadlock that was driving me crazy for a week in only 10 minutes".
UndoDB is different to most other debuggers because it is able to step a program back in time, showing the programmer exactly what their program has done, and so making even the most difficult bug trivial to uncover.
Bugs are the bane of software developers' lives, and those of their managers. Yet until recently, the tools that are used to resolve them had hardly evolved in decades. Greg Law, co-founder and CEO of Undo Software (http://undo-software.com/) found the general lack of interest in debugging in the computer science community perplexing:
Bugs are by far software's single biggest issue. It's always been so, and it's been getting steadily worse as software has become ever more complicated. Debugging may not be glamorous, but it totally dominates software development costs, schedule delays, and product quality. Even now a very small proportion of computer scientists are directly working on this problem. But things are beginning to change — Undo Software is one of a small but growing number of players in the industry who are giving this huge problem the attention it deserves.
The US government estimate that bugs cost $60bn per year to the US economy alone . This huge sum is partly due to productivity (the same report estimates programmers spend 80% of their time debugging), and also due to the cost of in-the-field bugs.
Law goes on to say
We have been truly delighted with the feedback and very positive response we received with the release of version 1 of UndoDB last year and we look forward to helping many more in the Linux community with the release of UndoDB v2 which is able to operate on programs that use threads and asynchronous signals.
Traditional debuggers have been in widespread use for decades, allowing the developer to stop his program and peer inside. The program can then be started again, and may be inched forwards an instruction or more at a time. These tools have their uses, but they are unable to tell the programmer what their program has done previously. A new breed of debugger, reversible debuggers, allow the programmer to pause a running program and inspect its state not just at that moment, but at any point in the past. The program can be stepped back a single instruction, or a larger amount of time, giving the developer much more information to help diagnose the cause of the bug.
A reversible debugger effectively records everything that the debuggee program does, down to the finest detail: every memory access, every computation, every call to the operating system and every input it receives. This colossal amount of data is then presented to the programmer using a very powerful metaphor: the ability to travel backwards in time (and forwards again) and inspect the program state. UndoDB does not need to store this huge amount of data though: its snapshot and replay technique allows it to store only non-deterministic inputs, making the space required for the log much smaller than would otherwise be the case.
Reversible debugging is so useful because it gives the user control over time. To debug a program is to reason backwards from the point of failure to determine the cause of that failure. On the first page of their book, The Practice of Programming, Brian Kernighan and Rob Pike (two of the pioneers of modern computer programming) give the following advice to programmers when debugging:
Reason back from the state of the crashed program to determine what could have caused this. Debugging involves backwards reasoning, like solving murder mysteries. Something impossible occurred, and the only solid information is that it really did occur. So we must think backwards from the result to discover the reasons.
With this analogy, a programmer using a reversible debugger is like the detective finding detailed CCTV footage of a murder and everything leading up to it.
UndoDB uniquely enables reversible debugging of arbitrary Linux binary programs, including those written in C or C++. UndoDB requires no recompilation or other modifications to the program being debugged, nor does it require any specialized hardware, kernel patches, or kernel modules.
UndoDB uses the ubiquitous gdb as its front-end, so Linux developers will feel right at home, and be productive the moment they get started. gdb has been complemented with a few new commands which work just like gdb's existing commands, only they step the program backwards in time, rather than forwards. For example, whereas gdb's step command steps the program forwards one source line, UndoDB's bstep command steps the program back one source line. UndoDB also compliments gdb's next, until, finish, stepi and nexti commands with their respective counterparts: bnext, buntil, bfinish, bstepi and bnexti. UndoDB also adds some new commands which have no parallel in gdb, such as the bgoto and bgoton commands, which jump to an arbitrary point in the program's history. When the program is paused at any point in its history, the programmer can inspect the full state of their program using the usual gdb commands (e.g. print, backtrace and display).
Although UndoDB is not open source, developers who don't get paid for their work can use UndoDB for free. For professional use, UndoDB costs between $195 and $495 per seat. There is also a free 30-day evaluation version. UndoDB is available now, from http://undo-software.com/.
 NIST — Software Errors Cost U.S. Economy $59.5 Billion Annually http://www.nist.gov/public_affairs/releases/n02-1 0 .htm.
 Dr. Dobb's Journal, May 09, 2005 — Omniscient Debugging (RetroVue at Work) http://www.ddj.com/dept/debug/184406101?pgno=5.
Notes to Editors
Undo Ltd is a privately held software company based in Cambridge, UK. It was founded by Greg Law and Julian Smith in 2005. Both hold a Ph.D. and have worked in the computer industry for many years. The company was formed out of the founders' frustration with existing debugging tools. UndoDB is Undo Software's first product.
Email firstname.lastname@example.org, visit http://undo-software.com/ or call Greg Law on +44 7712 588 091 for more"