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]
Other format: [Raw text]

Re: Using C++ in GCC is OK


On Tue, Jun 1, 2010 at 1:12 AM, Joel Sherrill <joel.sherrill@oarcorp.com> wrote:
> Another thing that has bothered me is the fear of
> getting slower. ?If using C++ makes GCC slower, then
> GCC C++ needs to get faster. ?This is eating our own
> dog food. :)

Indeed. If we can avoid the obvious problems (vtables, etc.) there is
no reason why using C++ should lead to a slower compiler. If we can
properly hide some things better, maybe we can even help our own
optimizers.  With some of the union tricks GCC plays now, GCC has to
make the worst-case assumptions when building itself. If we can solve
this with C++ we may actually get a faster compiler! (fingers
crossed...)

Things like bootstrapping with LTO (in whopr more, hopefully the
default for GCC 4.6?) may also help reduce the potential extra
overhead of using C++.

Ciao!
Steven


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