🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.java
Article #150

Re: Will Java kill C++?

#150
From: Paul G. Schaaf, Jr.
Date: Mon, 08 Apr 1996 20:06
54 lines
3437 bytes
Mark VanTassel wrote:
> 
> "Alan L. Lovejoy" <alovejoy@concentric.net> wrote:
> 
> >Bzzzt!  Not according to the benchmarks I've done.  Go benchmark the 
> >factorial or fibonacci functions (implemented recursively) in both C and a 
> >good Smalltalk.  You are in for a big surprise.
> 
> You're not seriously suggesting that a fibonacci series be programmed
> recursively, are you??? 

   Read again what he said.  He is suggesting an experiment to test the speed 
of recursion; not declaring viable implementation for Fibonacci.  But perhaps 
you are correct in attempting to make this explicit for other readers:  DO 
NOT USE RECURSION TO IMPLEMENT FIBONNACCI for anything other than 
experimental purposes.  

> Have you looked at the number of operations involved in calculating, say, the 1000th term as vs a standard looping approach?

   That's exactly why he was using this as an example.  It is easy to program, 
contains many iterations, and illustrates his point:  recursion is very fast 
in Smalltalk.  
 
> I don't think this is a valid benchmark... (and I too fail to see how
> Smalltalk can be faster than C++ except perhaps in bizarre special
> cases)
> 
> - /\/\ark \/anTassel (mvantassel@teambca.com)

   Try his experiment and you will see a set of problems for which the speed of 
Smalltalk compares to that of c/c++.  You may dismiss this set of problems as 
"bizarre", but as the size of that set increases, so does its importance.  

  Many (note that I am not saying all) c/c++ programmers claim that "Smalltalk 
is slow," and therefore dismiss it.  This is wrong for two reasons: 
      1. If speed were the only measure of value we'd all 
         be programming in Assembler (or tuning c compiler-
         generated Assembler).  
      2. Smalltalk is much faster than many people think.  

The fact is that Smalltalk can do a few things faster than c/c++, and some 
things as fast.  I would also argue that most of the remaining things in 
Smalltalk are not "significantly slower" than c/c++.  This point is debatable 
as it depends upon the requirement of your domain.  

It would be nice if we all had the resources to evaluate each of these 
languages fairly.  Smalltalk is shortchanged if the programmer writes only 
c/c++-style code, just as c++ is shortchanged if the programmer writes only 
c-style code.  

---------------------------------+---------------------------------------------
Paul Schaaf  http://www.amd.com  |"I was thrown out of college for cheating on
AMD, Sunnyvale CA                | the metaphysics exam; I looked into the soul
I don't speak for my company.    | of the boy next to me." -- Woody Allen
Technical Details
Message-ID: <316971B0.FEF@amd.com>
Path: arc1-ca.pugleaf.net!amd.com!usenet
References: <3134D499.653E@ix.netcom.com> <313613B2.136E@ksopk.sprint.com> <4i7qhl$ik6@cronkite.seas.gwu.edu> <4iuhi7$fmf@sundog.tiac.net> <4iumap$mn5@hustle.rahul.net> <31582A45.3742@vmark.com> <3163C031.4FB1@esec.ch> <3164888D.2B01@concentric.net> <4kbfn8$1bu@news1.is.net>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!amd.com!usenet
From: "Paul G. Schaaf, Jr." <paul.schaaf@amd.com>
Newsgroups: comp.lang.java,comp.lang.c++,comp.lang.smalltalk
Subject: Re: Will Java kill C++?
Date: Mon, 08 Apr 1996 13:06:08 -0700
Organization: Advanced Micro Devices
Message-ID: <316971B0.FEF@amd.com>
References: <3134D499.653E@ix.netcom.com> <313613B2.136E@ksopk.sprint.com> <4i7qhl$ik6@cronkite.seas.gwu.edu> <4iuhi7$fmf@sundog.tiac.net> <4iumap$mn5@hustle.rahul.net> <31582A45.3742@vmark.com> <3163C031.4FB1@esec.ch> <3164888D.2B01@concentric.net> <4kbfn8$1bu@news1.is.net>
NNTP-Posting-Host: hqsp86.amd.com
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Mailer: Mozilla 2.0 (WinNT; I)