[Q] Class instance layout details

Ian Lance Taylor ian@airs.com
Fri Jul 15 21:02:00 GMT 2005


Bharadwaj Yadavalli <bharadwaj.yadavalli@hp.com> writes:

> Can someone please point me to a place where I can get information
> about how gcc (2.96 and later) lays out class instances? In other
> words if I examine the contents of an object pointer, is there a
> document that specifies how the contents of the memory with relation
> to the pointer correspond to the members, the vtable etc.

Newer versions of C++ more or less follow the Itanium C++ ABI:
    http://www.codesourcery.com/cxx-abi/abi.html

That started somewhere in gcc 3.x, though I don't know exactly when.
I don't know if there any documentation on object layout in 2.96.

Ian



More information about the Gcc mailing list