Re: type/main_type/field size [Re: [patch] static_kind -> bit0, bit1]

Tom Tromey
2008-10-08T23:56:10Z

>>>>> "Joel" == Joel Brobecker <brobecker@adacore.com> writes:

Joel> Once in a while, Tom will post some numbers with each of his size
Joel> improvements. He worked pretty hard at reducing the sizes by some
Joel> bytes, so I'd like to know what he thinks of the increase before
Joel> adding a pointer back (4-8 bytes).

Joel> (2MB seems like a small and reasonable increase to me)

The main_type shrinkage patch was here:

http://sourceware.org/ml/gdb-patches/2008-08/msg00464.html

According to the note this saved about 1% on "gdb -readnow cc1".
However, this is pretty artificial. -readnow is not something normal
users do.

So, offhand I would say that type and main_type are not extremely
size-sensitive.

I suppose it is a judgment call as to whether you would rather use
more memory and have the code be clearer, or whether you would rather
save memory and use a bit to indicate (IIUC) a special dwarf-specific
callback.

Tom