Razik said:
>
> On Wed, 30 Apr 2008 08:00:38 -0700 (PDT), Isaac Gouy
> <igouy2@[EMAIL PROTECTED]
> wrote:
>
>>Why don't you go through all...
>
> Let's continue. Next we deal with sum-file...
>
>
http://shootout.alioth.debian.org/gp4/benchmark.php?test=sumcol&lang=all#about
>
> "Programs should use built-in line-oriented I/O functions rather than
> custom-code. No line will exceed 128 characters, including newline.
> Reading one line at a time, the programs should run in constant
> space."
>
> According to Haskel people,
>
> "Those guys tell us these benchmarks don't favor C and then impose a
> limit on line length? What's the purpose of that if not to allow the
> use of C's getline() primitive?"
C doesn't have a getline() primitive.
> That's a valid point that you need to address. Why 128 characters
> limit
No idea.
> if not to help C and C++ guys?
That ain't the reason.
>
> In any case,
> C++
>
http://shootout.alioth.debian.org/debian/benchmark.php?test=sumcol&lang=gpp&id=2
>
> Java
>
http://shootout.alioth.debian.org/debian/benchmark.php?test=sumcol&lang=java&id=2
>
> and 14 MB custom file used to test..
>
> 1.291s (g++)
> 0.742s (java -server)
> 0.706s (jet java net compiler)
>
> Huh? Shame on c++ and g++.
No, just shame on whoever wrote the C++ version. They might want to learn
C++ before writing benchmark programs.
> Why is still slower despite custom help
> provided by Isaac Gouy who imposed artificial 128 char line limit?
> Disappointed in C++, once again.
Why? The fault, dear Razik, lies not in our languages, but in our authors.
On my system, neither the C++ version nor the Java version would compile.
--
Richard Heathfield <http://www.cpax.org.uk>
Email: -http://www.
+rjh@[EMAIL PROTECTED]
users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999


|