Why isn't GDB designed and implemented by using Object-Oriented methodology?

Stan Shebs stan@codesourcery.com
Wed Jun 16 17:10:00 GMT 2010


xingxing pan wrote:
> When meeting so many structs and function pointer in the source codes,
> dose anyone have the thought to redesign and implement GDB using
> Object-Oriented  methodology?
>   

Well, the target vector abstraction dates from 1990, so that means we've 
been redesigning GDB to use object-oriented methodology for the past 
twenty years or so.

In practice, the hard part for us is deciding what the objects *should* 
be.  If someone posted a mega-patch tomorrow that converted GDB to C++ 
written in good style, that wouldn't do a thing to help me figure out 
how to support changing properties of tracepoints while a trace is 
running, or how to speed up symbol reading for really large executables, 
or how to reliably install software breakpoints with the inferior 
running in a non-stop mode.

So yes, more OOM "would be nice" and we encourage the submission of 
patches going in that direction, but it's not the magic bullet that will 
magically make GDB easy to work on.

Stan



More information about the Gdb mailing list