This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: forcing tail/sibling call optimization
On 29-Nov-2000, Mark Mitchell <mark@codesourcery.com> wrote:
>
> I think we're going to have to agree to disagree here.
Yes.
> It's still
> my position that we shouldn't introduce an extension for the tail-call
> stuff, because I don't view the translation of functional languages
> into C as fundamentally the right way to go. It would be so much
> better to write a Scheme front-end for GCC -- and I would totally
> support, then, providing a bit on CALL_EXPRs to force tailcalls.
> Presumably, the Scheme front-end would set this bit.
Scheme would not be a good choice as a target language for source
languages like Mercury (or Haskell, ML, Clean, etc.,) since Scheme is
dynamically typed, whereas Mercury is statically typed.
C is certainly not ideal as a target language, but it does have some
big advantages, even in comparison to languages like C-- that were
explicitly designed as target languages. (I can elaborate here if you
want details.) So the use of C as a target language is not going to
go away anytime in the near future. I think this use will continue
to be sufficiently important that it is worth providing extensions
to GNU C to support it better.
But as you said, we'll have to agree to disagree.
> We'll see what happens from here.
I didn't spot anything on gcc.gnu.org saying what procedure is used to
resolve these kinds of disagreements. I guess eventually, if/when I
get around to implementing this, it will come down to a vote as to
whether or not the patch gets incorporated?
--
Fergus Henderson <fjh@cs.mu.oz.au> | "I have always known that the pursuit
| of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh> | -- the last words of T. S. Garp.