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: b20: c++ bug or feature?


Mumit writes:
> Andres Heinloo  writes:
> > 
> > when compiling gtk-- example program 'OhharaDraw', I get the following
> > error:
> > 
> > OhharaDraw.h:130: sorry, not implemented: object size exceeds normal limit
> > for virtual function table implementation, recompile all source and use
> > -fhuge-objects
> 
> When building the vtable for ``OhharaDraw'', the compiler is running
> into the limitation that the offset is represented by a signed short,
> and cannot hold -45054 (the resulting offset for type info function
> in this case).
 
There must be something very wrong, somewhere.  Unless I am mistaken,
this implies vtables larger than 45Kbytes!  What kind of design results
in such humongous vtables?  This seems to imply literally thousands 
of virtual functions.

To Mumit's suggestions, I would add: re-architect the system so that 
classes have fewer (unused) virtual functions.

Nathan Myers
ncm@cantrip.org



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