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: Question: Virtual call ellimination with GCC.


>     Here is a simple test file, compiled by GCC Cygwin-b20 and Watcom 11
> C/C++.
> The resulting files show the Watcom generated code is faster than Gcc, in
> this case.
> I think, the reasons behind the difference is in the difference of virtual
> function handling. ( In other cases, code generated by GCC is better.)
> Does GCC have some option for virtual call optimization?

Not at the moment. If somebody is interested in speeding-up
g++-generated code, virtual-call-elimination would certainly be the
most important item to start with.

Unfortunately, it is not that simple: Once the optimizer starts, all
information about language-level concepts is lost. So all you could
build on is constant propagation. This needs to improve dramatically,
indeed.

Regards,
Martin


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