[Metakit] Performance comparison Q

Stanislav Karchebny berkus at gmail.com
Tue May 10 11:19:20 CEST 2005


On Monday 09 May 2005 18:49, Jean-Claude Wippler wrote:

> The C code is pretty obvious:
>
>      int sum = 0; for (i = 0; i < 50000; ++i) sum += data[i];
>
> This one in tcl 8.4.6 runs at quite a bit under 1% of that speed:
>
>      set sum 0; foreach x $data { incr sum $x }
>

btw, ruby/lib/1.8/benchmark.rb is a good place to look for several ways to 
perform this test.

-- 
Best regards,
Stanislav Karchebny

Skype name: berkus
Get skype for free from www.skype.com

Information in this email is confidential and proprietary.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://www.equi4.com/pipermail/metakit/attachments/20050510/4472f9dd/attachment.bin


More information about the Metakit mailing list