Chris Quenelle is a tools developer at Oracle Corp. He's worked on performance and debugging tools at Sun and Oracle for over 15 years. He reads comic books and science fiction, and has more tivos than he can keep track of.

 

September 2010
S M T W T F S
« Jun    
 1234
567891011
12131415161718
19202122232425
2627282930  

Debugger Design

I’ve spent a number of years in the dbx group at Sun, and over time you collect a lot of coulda-woulda-shoulda stories.  You know what I mean, “This code should really have been designed to do XYZ.”  Or “This module shouldn’t have to talk to that module.”  I figured I’d try to record some of the [...]

Goodbye Solaris 9 (for Sun Studio)

We’re making the internal transition to building Sun Studio on Solaris 10 (instead of Solaris 9). This is a big deal because the product bits immediately become useless on any Solaris 9 system. There’s a new libm.so.2 library that became available on Solaris 10, and if you depend on it, you can’t run on [...]

Using dbx and libumem to find memory problems

Update: There is a new version of umem.dbx here (Solaris 9 support) Download it here.

I implemented a spiffy little dbx module to give basic access to libumem debugging features a while back, but I haven’t gotten much feedback on it.  Think of this blog entry like a Dunk Tank at the carnival. Throw a [...]

Latest Sun dwarf extensions

I’ve been working with the Sun lawyers and the Dwarf Standards Committee recently to change the overly zealous license on the Sun Dwarf Extensions document.  I think we’ve finally gotten it down to something reasonable.  Anyway, we’ve added a few twists for C++ and Fortran 90.  As an example, there are some new structures for identifying [...]

dbx .ldynsym support – stack traces for stripped programs

Stack traces for stripped programs should get easier to read on Solaris.  Solaris Nevada added a new strip-proof symbol table that inherits part of the symbols that normally get stripped out by the strip command. Basically static functions. Static functions have always been the number one cause of unreadable stack traces in stripped programs, but not [...]

Stopping right before your crash

I just got this question from Steve down the hall.  It’s so mind-bogglingly useful, that everyone who uses dbx needs to know how to do it.  The scenario goes like this. Your program crashes in strcpy sometime in the middle of the run, after about a zillion calls to strcpy.  But you want to stop on [...]

Dwarf and XML

I’ve been having a hard time sifting through huge dwarf dump files in the last year or so, especially some of the huge dumps from the C++ standard template library. (Blech) So I’ve been working on a side project to let me do more powerful queries on dwarf information.  The part of the dwarf information that [...]

Importing debug information into dbx

I’m sure I wrote this up somewhere before, but now I can’t find it. Just in case you guys (my two faithful readers) haven’t seen this trick yet. If you are stuck with a core file that doesn’t have debug information, you can “import” debugging information using the “loadobject -load” command. It’s especially useful for C++ [...]

The story of lazy stabs

There’s a dbx feature called “lazy stabs” that is clever, but a little confusing sometimes. I figured I’d talk about it a little to give an overview of what’s happening. There are really two parts to the idea of “lazy stabs”, one part is something we do all the time (demand loading most information [...]

MAP_NORESERVE and dbx

So your program has Obj * p; in it, and you stop in dbx and say print *p Dbx comes back and says the memory is illegal or unmapped. But then you continue your program, and your program reads from *p just fine. What’s going on?

This gotcha showed up again on a [...]