ommitting vtables

Harri Porten kde-optimize@mail.kde.org
Mon, 13 Jan 2003 11:49:45 +0100 (CET)


On Mon, 13 Jan 2003, Allan Sandfeld Jensen wrote:

> > Yes. The attribute only affects the base class. The vtable itself may
> > still be emitted but there'll be no initialization code in the class's
> > constructor. Also, the linker can drop the vtable w/o any reference.
> >
> Dont you think that happens if you make the class pure virtual?

I'm very confident that it doesn't happen. Others have already analyzed
the "wasted" space. The code is question is not 100% wasted as I guess it
gives us the nice feature of throwing the "pure virtual function called"
error message.

Harri.