Virtual base class offsets in vtables

Jason Merrill jason at cygnus.com
Tue Jan 18 14:06:23 UTC 2000


>>>>> Mark Mitchell <mark at codesourcery.com> writes:

 >   o Furthermore, it's unclear whether or not offsets for indirect
 >     virtual bases should be stored.  The Category 3 description
 >     seems to indicate that only *direct* bases should be stored;
 >     otherwise left-to-right declaration order isn't really
 >     well-defined.  But, Category 4 clearly says direct or indirect 
 >     bases.

The idea is to promote vbase offsets, like virtual function entries, out of
virtual bases and not non-virtual bases.

 >   In the primary vtable, the vbase offsets are in the reverse order in
 >   which the virtual bases are encountered in a depth-first,
 >   left-to-right traversal of the inheritance graph.  In the secondary
 >   vtables for a given base B, offsets are only included for those
 >   virtual bases present in the primary vtable for B, and are present
 >   in the same order.

I'm not sure what you mean by "present in the primary vtable".

Jason




More information about the cxx-abi-dev mailing list