Virtual table contents
Eugene Kuznetsov
divx@euro.ru
Mon Dec 18 12:23:00 GMT 2000
Hello.
I've got a question regarding inner structure of virtual
tables generated by different versions of g++.
I did some testing with egcs 2.91.66. After a couple of
tests I found out that its virtual tables are arrays of
pointers, where actual pointers to functions begin from
3rd position - first two seem to be reserved for other
purposes such as RTTI or multiple inheritance. I played
with compile options -fno-rtti and -fvtable-thunks, but
it didn't change anything.
Here's the question.
Is there an universal way ( i.e. the way that would
be acceptable for all compilers since egcs 2.91 and
higher ) to tell compiler NOT to use these two positions
and to start function pointers immediately from 1st
position? Or such a way only for some specific versions
of compilers?
--
Thank you,
Eugene
More information about the Gcc
mailing list