> I don't understand this at all.
> 
> I thought you were saying that these are static functions, and that gcc
> gathers them all together into a single global constructor.  Are there
> cases where gcc does not gather them together?  Why would that be?

At the moment we don't gather when there is only one constructor of given 
priority
and target has ctors/dtors support.  This is prettier WRT user defined 
constructors
and also to avoid need to do inlining (that does not happen at -O0).

I guess gathering the ctors/dtors always is also an option.  Other option that 
just came
to my mind is to recognize the specially named ctors/dtors and always inline 
them only.
Those should be all compiler produced and thus inlinable.

Honza

Reply via email to