This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: GCC IMA & general future proposal
- From: Joe Buck <Joe dot Buck at synopsys dot COM>
- To: Jeffrey A Law <law at redhat dot com>
- Cc: Jan Hubicka <jh at suse dot cz>,"Joel Sherrill <joel at OARcorp dot com>" <joel dot sherrill at OARcorp dot com>,Giovanni Bajo <giovannibajo at libero dot it>,Geoff Keating <geoffk at geoffk dot org>, Steven Bosscher <stevenb at suse dot de>,Daniel Berlin <dberlin at dberlin dot org>,Kenneth Zadeck <zadeck at naturalbridge dot com>, ctice at apple dot com,dalej at apple dot com, gcc at gcc dot gnu dot org
- Date: Wed, 27 Oct 2004 14:04:24 -0700
- Subject: Re: GCC IMA & general future proposal
- References: <7D87A70E-27F5-11D9-8458-000A95B1F520@geoffk.org> <Pine.LNX.4.61.0410271336110.16557@digraph.polyomino.org.uk> <20041027134128.GV21413@kam.mff.cuni.cz> <042d01c4bc44$c5ae50b0$46b92997@bagio> <20041027172924.GZ21413@kam.mff.cuni.cz> <417FDF08.9020306@OARcorp.com> <20041027174957.GR32125@kam.mff.cuni.cz> <1098899750.5943.24.camel@localhost.localdomain>
On Wed, Oct 27, 2004 at 11:55:49AM -0600, Jeffrey A Law wrote:
> On Wed, 2004-10-27 at 19:49 +0200, Jan Hubicka wrote:
> > >
> > > This may be a stupid suggestion and is probably not as general
> > > as what EDG is doing but couldn't the template instantiations be
> > > put into special sections and then let ld eliminate the duplicates
> > > as it merges the object files into the executable?
> >
> > This is what GCC does currently, but it results in very many
> > instantiations being compiled just to be thrown away that consumes time
> > and disc space.
> Right. And I get customers who complain about this on a pretty
> consistent basis. This scheme slows down compilation time, link time
> and eats a ton of disk space.
But the alternative of repeatedly recompiling until no more templates
are instantiated can also be wasteful and slow. I haven't yet seen a
scheme that really wins over what GCC is doing now, if you consider the
effect of corrupt repository databases, library closure issues and the
like.