This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: layout of the g++ virtual tables


>
>All you need do, is dispatch as you did before, just remove the this
>offset code, and change the vtable entry size from 8 to 4.


Oh, oh, implementation defined constants :-(

>and this happens before the call.  The first vtable entry is at 8
>(really 2 * sizeof (void (*)())) (magic number, sorry).

PLEASE, PLEASE use ptr_mode when describing (and coding !) such
implementations. One of the main obstacles in the gcc 2.7 to gcc 2.8 move
was to remove the focus on 32bit implementations, and it's still buggy.

For example, exception handling does not work on OpenVMS/Alpha and Windows
NT/Alpha just because Pmode does NOT equal ptr_mode on this targets but
almost everyone assumes 'Pmode == ptr_mode' !!

Klaus



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]