home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!usc!cs.utexas.edu!rutgers!cbmvax!jesup
- From: jesup@cbmvax.commodore.com (Randell Jesup)
- Newsgroups: comp.arch
- Subject: Re: No Last Call Optimization on Sparc and DECstation
- Message-ID: <38249@cbmvax.commodore.com>
- Date: 2 Jan 93 03:16:53 GMT
- References: <1992Dec30.094352.4243@cucs5.cs.cuhk.hk>
- Reply-To: jesup@cbmvax.commodore.com (Randell Jesup)
- Organization: Commodore, West Chester, PA
- Lines: 24
-
- bmtong@cs.cuhk.hk (Tong Bo-Ming) writes:
- >In the field of Logic Programming, we have a kind of optimization
- >technique called the Last Call Optimization. The idea is simple.
- ...
- >In the above procedure, we may discard the current stack frame (or reg
- >window in Sparc) before calling z. We then replace the call z
- >instruction by a jump instruction.
- ...
- >In the above kind of procedure where there is only one call, no stack
- >frame is necessary. It can be optimized as if it were a leaf procedure.
- >
- >It is a sad thing to notice that such a nice optimization is not
- >implemented in languages other than Prolog and on RISC architectures.
-
- I think you need to look at more compilers. The SAS/C 680x0
- compiler for the Amiga does both of these.
-
- --
- GNU Emacs is a LISP operating system disguised as a word processor.
- - Doug Mohney, in comp.arch
-
- Randell Jesup, Jack-of-quite-a-few-trades, Commodore Engineering.
- jesup@cbmvax.commodore.com BIX: rjesup
- Disclaimer: Nothing I say is anything other than my personal opinion.
-