Re: Shoot out
On Thu, 17 May 2001, Matthew Byng-Maddick wrote: On Thu, May 17, 2001 at 03:20:08PM +0100, Dominic Mitchell wrote: I still remember an article about C++ templating being a turing complete language in it's own right or something weird. This isn't it, but is entertaining anyway: http://www.annexia.org/freeware/cpptemplates/ And if you don't want to do things in C++: http://www.apache.org/~fanf/list.h :) The guy is a nutcase. Oh well, he's only won one IOCCC. :) I might just be sharing a house with that nutcase in a few months ;-) L.
Shoot out
Hi, Have you seen http://www.bagley.org/~doug/shootout/ ? My pike loving friend was amused to see Perl and Python trounced. But the testing rig was written in Perl at least. Cheers -- Merijn Broeren | Everything in excess! To enjoy the flavour of life, Software Geek | take big bites. Moderation is for monks. |
Re: Shoot out
On Thu, May 17, 2001 at 01:19:27PM +0200, Merijn Broeren wrote: Have you seen http://www.bagley.org/~doug/shootout/ ? My pike loving friend was amused to see Perl and Python trounced. But the testing rig was written in Perl at least. His perl isn't necessarily the fastest in all cases. I sped some of his scripts up quite significantly - enough to move it back up above Python anyway ;) It's all quite interesting. Tony -- -- Tony Bowden | [EMAIL PROTECTED] | http://www.tmtm.com/ make me laugh make me cry enrage me don't try to disengage me -- PGP signature
Re: Shoot out
Quoting Tony Bowden ([EMAIL PROTECTED]): His perl isn't necessarily the fastest in all cases. I sped some of his scripts up quite significantly - enough to move it back up above Python anyway ;) I was looking at the attributions page and saw only your name. I was kind of expecting the rabid hordes of london.pm speedfreaks would like to have a go, but you were already there, I should have known you were a lnpm'er ;-) It's all quite interesting. Indeed. I thought the functional languages would do much better when weighing the mathematical stuff higher, but there was almost no change. Cheers, -- Merijn Broeren | Everything in excess! To enjoy the flavour of life, Software Geek | take big bites. Moderation is for monks. |
Re: Shoot out
On Thu, May 17, 2001 at 01:19:27PM +0200, Merijn Broeren wrote: My pike loving friend was amused to see Perl and Python trounced. But the testing rig was written in Perl at least. I was astounded by the performance of Ocaml. Being forced by an insane lecturer to debug an obfuscated Ocaml program when I was a student rather put me off the language. (And _boy_ can you write obfuscated Ocaml programs if you try! User-definable infix operators are an especially nice touch in that regard) Why isn't Ocaml more popular? Is there a good reason? .robin. -- Sometimes I sit in front of my washing machine and contemplate the worthlessness of life. My washing machine isn't even plugged in. --alex
Re: Shoot out
On Thu, May 17, 2001 at 03:04:47PM +0100, Robin Houston wrote: Statement: (And _boy_ can you write obfuscated Ocaml programs if you try! User-definable infix operators are an especially nice touch in that regard) Answer: Why isn't Ocaml more popular? Is there a good reason? -Dom
Re: Shoot out
On Thu, May 17, 2001 at 03:06:45PM +0100, Dominic Mitchell wrote: On Thu, May 17, 2001 at 03:04:47PM +0100, Robin Houston wrote: Statement: (And _boy_ can you write obfuscated Ocaml programs if you try! User-definable infix operators are an especially nice touch in that regard) Answer: Why isn't Ocaml more popular? Is there a good reason? :-) I don't find that enormously convincing as a reason, though. You may have noticed that it's possible to write obfuscated Perl programs ;) C++ is also pretty bad in that respect (I still don't *quite* believe that overloadable typecasting isn't a joke...), and is pretty popular... I suppose one reason is that in order to be popular, a language has to syntactically resemble C to make it easier for existing programmers to learn. .robin. -- It really depends on the architraves. --Harl
Re: Shoot out
* Robin Houston ([EMAIL PROTECTED]) wrote: On Thu, May 17, 2001 at 01:19:27PM +0200, Merijn Broeren wrote: My pike loving friend was amused to see Perl and Python trounced. But the testing rig was written in Perl at least. I was astounded by the performance of Ocaml. But the question is, are they generating C code from Ocaml code and compiling it, this would explain the performance. -- Greg McCarroll http://www.mccarroll.uklinux.net
Re: Shoot out
On Thu, May 17, 2001 at 03:12:58PM +0100, Robin Houston wrote: I don't find that enormously convincing as a reason, though. You may have noticed that it's possible to write obfuscated Perl programs ;) No, I've only over seen pleasant, readable perl code posted to this list. C++ is also pretty bad in that respect (I still don't *quite* believe that overloadable typecasting isn't a joke...), and is pretty popular... I didn't realise that you could overload typecasting. Wow. I still remember an article about C++ templating being a turing complete language in it's own right or something weird. This isn't it, but is entertaining anyway: http://www.annexia.org/freeware/cpptemplates/ I suppose one reason is that in order to be popular, a language has to syntactically resemble C to make it easier for existing programmers to learn. Well, look what that did for Java. And look what it will do for C#. It's a lot easier to tempt people away when it takes less effort for them. To use the canonical counter-example, take lisp. How many people have been scared off it by how much it *doesn't* look like anything you already knew? -Dom (elisp's my limit, I'm afraid)
Re: Shoot out
On Thu, May 17, 2001 at 03:20:08PM +0100, Dominic Mitchell wrote: I still remember an article about C++ templating being a turing complete language in it's own right or something weird. This isn't it, but is entertaining anyway: http://www.annexia.org/freeware/cpptemplates/ And if you don't want to do things in C++: http://www.apache.org/~fanf/list.h :) The guy is a nutcase. Oh well, he's only won one IOCCC. :) MBM
Re: Shoot out
On Thu, 17 May 2001, Merijn Broeren wrote: Quoting Tony Bowden ([EMAIL PROTECTED]): His perl isn't necessarily the fastest in all cases. I sped some of his scripts up quite significantly - enough to move it back up above Python anyway ;) I was looking at the attributions page and saw only your name. I was kind of expecting the rabid hordes of london.pm speedfreaks would like to have a go, but you were already there, I should have known you were a lnpm'er ;-) heh! ..I just took 30% off his object_instantiation .. thats quite heavily weighted in the results and inherited into other tests so that should move perl up a bit. weirdly .. one thing I tried 'hmm no explicit DESTROY sub,... hmm I wonder if it spends time searching for one .. I'll make a sub DESTROY { } and see if it speeds it up ..' nope 40% slower overall ... -- Robin Szemeti Redpoint Consulting Limited Real Solutions For A Virtual World
Re: Shoot out
On Thu, May 17, 2001 at 03:28:13PM +0100, Greg McCarroll wrote: But the question is, are they generating C code from Ocaml code and compiling it, I don't think so. I think the Ocaml compiler compiles directly to machine code. But what difference does it make, ultimately? this would explain the performance. It might help to explain why it's faster than interpreted languages. But C++ is a compiled language too, and Ocaml seemed to be consistently faster than C++ in those benchmarks. I don't think the picture is so simple any more, anyway. Optimising JITs seem to be catching up... .robin. -- Satan, oscillate my metallic sonatas!