This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Link-time optimzation
- From: Nathan Sidwell <nathan at codesourcery dot com>
- To: Kenneth dot Zadeck at NaturalBridge dot com
- Cc: Richard Henderson <rth at redhat dot com>, Mark Mitchell <mark at codesourcery dot com>,gcc mailing list <gcc at gcc dot gnu dot org>
- Date: Fri, 18 Nov 2005 17:24:21 +0000
- Subject: Re: Link-time optimzation
- References: <20051117011900.GA17847@redhat.com> <20051117155340.0B0D674646@zadeck.dynalias.net>
Kenneth Zadeck wrote:
The stack machine that we have in mind will be as stripped down as
possible. The idea is just to get the trees in and get them back out.
When I first read the proposal, I too wondered if a register machine would be
better here. I've come to the conclusion that it wouldn't be, and that a stack
machine is a fine choice.
*) Unlike JVM, we're not producing something that is supposed to be immediately
executable. Making hardware stack machines go fast is very hard -- TOS acts as
a huge atomic operator.
*) I can well imagine more complicated gimple nodes than simple 3 address forms.
A stack machine makes this kind of thing easy to extend. As Kenny says, a
stack machine is an ideal way to serialize a tree.
*) The stack machine decouples the getting and putting of operands from the
actual operations. Although this could lead to excessive size, that does depend
on the actual encoding chosen -- something that affects both stack and register
machines.
nathan
--
Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
nathan@codesourcery.com :: http://www.planetfall.pwp.blueyonder.co.uk