RFA/types: Clean up use of field bitsize

Daniel Jacobowitz drow@mvista.com
Wed Nov 6 12:53:00 GMT 2002


On Wed, Nov 06, 2002 at 03:41:10PM -0500, Andrew Cagney wrote:
> >Does anyone have a comment on this patch?  If not, I'll commit it in a
> >couple of days, after I'm added to the global write list.
> >
> >(The type code has no specific maintainer, the debug reader and
> >language parts I consider obvious, and the patch is over a month old
> >now.)
> 
> I'm mainly wondering if we're that desperate for memory space.
> 
> I thought a data structure was added to GDB so that it could spot 
> duplicate type info and, hence, keep its memory size down.

If so, I don't see it.  The debug readers will create a new copy when
they hit a new definition.

Besides, wasting memory is still bad.  And that's not the reason I did
it, anyway:

> >>The goal is to allow more kinds of fields to be marked artificial -
> >>particularly data members.  After this patch I'll submit the followup to
> >>mark DW_AT_artificial members as artificial types.

... in other words, moving artificial out of loc without wasting an
additional 32 bits.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer



More information about the Gdb-patches mailing list