Newsgroups: comp.lang.smalltalk
Path: cantaloupe.srv.cs.cmu.edu!rochester!cornellcs!newsstand.cit.cornell.edu!news.kei.com!nntp.coast.net!torn!nott!cunews!dbuck
From: dbuck@superior.carleton.ca (Dave Buck)
Subject: Re: The Future of Smalltalk Performance?
X-Nntp-Posting-Host: superior.carleton.ca
Message-ID: <DLHLvM.BDq@cunews.carleton.ca>
Sender: news@cunews.carleton.ca (News Administrator)
Organization: Carleton University, Ottawa, Canada
References: <4crvvl$jd5@news.jf.intel.com> <4die9l$2tk@rex.sfe.com.au> <DLD2yo.850@cunews.carleton.ca> <4dn5c0$aq8@rex.sfe.com.au>
Date: Sat, 20 Jan 1996 16:02:10 GMT
Lines: 74

In article <4dn5c0$aq8@rex.sfe.com.au>, Paul Hatchman <paul@sfe.com.au> wrote:
>I dont think this belongs in a Smalltalk newsgroup anymore

I agree.  I've clipped out all the stuff that relates to C++
performance vs. encapsulation, etc.

> but I just can not 
>accept your claim that a C++ program will execute at the same speed as an 
>Smalltalk program that is identical in functionality. I have seen the claim
>stated many times in this newsgroup and maybe it is a case of if you repeat
>it often enough people will believe it.

I'd be interested to know what's so hard about accepting my claim.  I
certainly can't expect anyone to accept a claim like mine without
performing the tests themselves, but I keep seeing people rejecting it
out of hand.  I suspect that the logic goes:

  a) Smalltalk is an interpreted language
  b) C++ is a compiled language
  c) Compiled languages are faster than interpreted languages
therefore
  d) C++ is faster than Smalltalk

I hope your rejection of my claim isn't based on the above
mis-conceptions.  I don't think it is.

>C++ performance using OO features in my experience is many times faster than 
>that of an equivalent Smalltalk program.
> I unfortunately can not offer you any
>metrics.

I don't really ask for metrics.  If you've got them, it helps a lot.
From the benchmarks I've run, (he he, I get to say it again), the C++
code wasn't significantly better than Smalltalk code.  

> I will see if I can find anything I have written where I can quantify 
>the speed difference for similar programs.
>
>Speed to develop an application is a different matter and I can easily be
>persuaded that Smalltalk has the advantage here for now.

To me the speed of development is very clearly in Smalltalk's favor.
there's no sense debating that one.

>I suggest that any further comparisons between C / C++ and Smalltalk involve
>measured timings of real life programs, where the source code can be made
>availible for inspection.

I can agree with the bit about "measured timings" and "source code
available for inspection".  My only problem is with "real life
programs".  In my experience, real life programs range from thousands
to hundreds of thousands of lines of code.  The effort in developing
such a program in two languages then comparing the two is well beyond
what I'm willing to engage in at this point (which is very little -
I'm quite busy these days).  Besides, with this kind of program, if
there was some huge difference between Smalltalk and C++, you'd have
to do a lot of digging to see why and you'd end up with arguments
about whether some technique is fair or not.

To be honest, I really haven't much time these days for long debates
like this and for doing many benchmarks.  If you want the code and
results for the benchmarks I performed, I can send them along.  If you
have any results of your own, I'd love to hear about them.  I just
don't want to spend a lot of effort on it right now.

David Buck
dbuck@ccs.carleton.ca

_________________________________
| David K. Buck                 |
| dbuck@ccs.carleton.ca         |
| The Object People             |
|_______________________________|

