This is the mail archive of the gcc-patches@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: [PATCH] C++ space optimization: de-cloning con/de/structors


On Wednesday, August 7, 2002, at 03:36 PM, Jason Merrill wrote:
Sorry, I should've just asked this myself. My question wasn't about static
inlines, but about extern inlines (the default).

The problem, of course, is that we might have an inline (or template)
constructor in multiple translation units; we're required to only have
a single copy after we do the link. Would this conflict in any way with
giving constructor bodies internal linkage?
It would mean trying to inline the thunk which calls the unified
constructor would be rather complicated. I would think you just wouldn't
de-clone inline *tors.

Templates shouldn't be a problem; they still have the usual entry points.
Hm, I don't think I follow that.  Templates use vague linkage.  If
vague linkage depends on external linkage, then I think that means
that we can't change a decloned template constructor to have internal
(or no) linkage.

I think I must be missing your point.

			--Matt


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