On Mon, Aug 10, 2015 at 03:56:02PM +0200, Markus Trippelsdorf wrote:
> On 2015.08.10 at 08:05 -0400, tbsaunde+...@tbsaunde.org wrote:
> > 
> > In many places gcc puts classes in the anon namespace so the compiler can 
> > tell
> > they do not get inheritted from to enable better devirtualization.  However
> > debugging code in the anon namespace can be a pain, and the same thing can 
> > be
> > accomplished more directly by marking the classes as final.  When 
> > bootstrapping
> > stage 3 should always be built in C++14 mode now, and of course will always 
> > be
> > newer than gcc 4.7, so these classes will always be marked as final there.
> > AIUI cross compilers are supposed to be built with recent gcc, which I would
> > tend to think implies newer than 4.7, so they should also be built with 
> > these
> > classes marked as final.  I believe that means in all important cases this 
> > works just as well as the anon namespace.
> > 
> > bootstrapped + regtested on x86_64-linux-gnu, ok?
> 
> Are you sure that you don't unintentionally introduce new ODR
> violations? 

yeah, I just looked at a list of all the class names, and they are all
different.  So since all the new symbols involve a class name they are
all unique.

Trev

> An LTO bootstrap, where you look for new -Wodr warnings, should give the
> answer.
> 
> -- 
> Markus

Reply via email to