A Retargetable Debugger (Abstract)

Norman Ramsey and David R. Hanson.

We are developing techniques for building retargetable debuggers. Our prototype, ldb, debugs C programs compiled for the MIPS R3000, Motorola 68020, SPARC, and VAX architectures. It can use a network to connect to faulty processes and can do cross-architecture debugging. ldb's total code size is about 16,000 lines, but it needs only 250-550 lines of machine-dependent code for each target.

ldb owes its retargetability to three techniques: getting help from the compiler, using a machine-independent embedded interpreter, and choosing abstractions that minimize and isolate machine-dependent code. ldb reuses existing compiler function by having the compiler emit PostScript code that ldb later interprets; PostScript works well in this unusual context.

The full paper is available in PostScript form (179K) or you can read the scanned original in DjVu form (869K).