Newsgroups: alt.lang.design,comp.lang.c++,comp.lang.lisp
Path: cantaloupe.srv.cs.cmu.edu!fs7.ece.cmu.edu!kinky.eng.gtefsd.com!europa.eng.gtefsd.com!howland.reston.ans.net!pipex!uknet!festival!edcogsci!jeff
From: jeff@aiai.ed.ac.uk (Jeff Dalton)
Subject: Re: Interpreters (Re: Comparing productivity: LisP against C++ (was  Re: Reference Counting))
Message-ID: <D2xAAC.Bu6@cogsci.ed.ac.uk>
Sender: usenet@cogsci.ed.ac.uk (C News Software)
Nntp-Posting-Host: bute.aiai.ed.ac.uk
Organization: AIAI, University of Edinburgh, Scotland
References: <MATT.95Jan21135219@physics7.berkeley.edu> <LOU.95Jan22135154@athos.rut <MATT.95Jan22120400@physics7.berkeley.edu>
Date: Tue, 24 Jan 1995 18:34:59 GMT
Lines: 40
Xref: glinda.oz.cs.cmu.edu comp.lang.c++:109088 comp.lang.lisp:16483

In article <MATT.95Jan22120400@physics7.berkeley.edu> matt@physics.berkeley.edu writes:
>In article <LOU.95Jan22135154@athos.rutgers.edu> lou@athos.rutgers.edu (Lou Steinberg) writes:
>
>> In article <MATT.95Jan21135219@physics7.berkeley.edu> matt@physics7.berkeley.edu (Matt Austern) writes:
>> 
>>    That's one reason why compiled lisp code is a bit unusual
>> 
>> This is completely wrong - compiled lisp code is not at all unusual.
>> I cannot think of any large program I have seen or heard of in LISP
>> for at least the last 15 years that has not been compiled once it was
>> debugged.
>
>Sorry, my wording was unclear.  I certainly didn't mean that lisp
>compilers were rare (all but three of the lisp implementations I've
>used included compilers), or that it was rare for lisp programs to be
>compiled.  I've used too many lisp implementations, and worked on too
>many lisp projects, to have that sort of misconception.
>
>What I meant was simply that the nature of "object" code, and of the
>run-time environment for executable lisp programs, is rather different
>than it is for most compiled languages.  That's largely because of
>eval, but there are other reasons too.

Such as?

And what do you think is different about the compiled code, especially
due to eval?

The main difference in compiled code is that function calls often
go through one level of indirection (e.g calling the value of a
variable rather than direct to the first instruction of the function),
that different sorts of operations might be compiled in-line
(e.g. w/o declarations addition is probably a procedure call;
OTOH, a call to mapcar is probably compiled in-line), and that
there'll be instructions in compiled Lisp code to handle tags
(in tagged pointers) or other run-time type information.

None of this is due to eval.

-- jd
