From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by yquem.inria.fr (Postfix) with ESMTP id 5FB4EBC37 for ; Sun, 10 Jan 2010 19:29:46 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AloEAP6qSUsjCUucgWdsb2JhbACbXgEBFiSsLgEwhAWFLAaELw X-IronPort-AV: E=Sophos;i="4.49,251,1262559600"; d="scan'208";a="53601685" Received: from webmail-6.mail.msu.edu (HELO webmail-6.internal.mail.msu.edu) ([35.9.75.156]) by mail4-smtp-sop.national.inria.fr with ESMTP/TLS/DHE-RSA-AES256-SHA; 10 Jan 2010 19:29:45 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=msu.edu; s=mail; h=Message-ID:Date:From:To:Subject:MIME-Version: Content-Type:Content-Transfer-Encoding; bh=ox0KsdD83w6gyrJzdWXmc GIKvC2lQ/GFq60yrIxyVUw=; b=ZoWVEnvhwHgQwgwH3auhs8s4k6xjmjGNiA1W/ mTdvinhYbCDVE7DDF5KJ1jMAUnoFDzct6Zd4U79SUMcBlmeLwyNlH/YRkolTmDsd Il1rojf9IrWEUvLPtcfGa8hIMWyyeoCaGCSnbnBqpq1ZRzqpeTf0ETZd0k6Rubbt d4LhMM= Received: from localhost.msu.edu ([127.0.0.1] helo=msu.edu) by webmail-6.internal.mail.msu.edu with esmtp (Exim 4.69 #1) id 1NU2Xm-0002xh-V2 for caml-list@inria.fr; Sun, 10 Jan 2010 13:29:42 -0500 Received: from c-24-56-235-190.customer.broadstripe.net (c-24-56-235-190.customer.broadstripe.net [24.56.235.190]) by mail.msu.edu (Horde Framework) with HTTP; Sun, 10 Jan 2010 13:29:42 -0500 Message-ID: <20100110132942.1995706rwh00q1zq@mail.msu.edu> Date: Sun, 10 Jan 2010 13:29:42 -0500 From: shawjef3@msu.edu To: caml-list@inria.fr Subject: Re: HLVM ray tracer performance MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="=_6v5sqhke9dw6" Content-Transfer-Encoding: 7bit User-Agent: Internet Messaging Program (IMP) H3 (4.3.6) X-Virus: None found by Clam AV X-Spam: no; 0.00; haskell:01 --version:01 haskell:01 compilation:01 --version:01 ocamlopt:01 native-code:01 compiler:01 usr:01 lib:01 ocaml:01 ocaml:01 compilation:01 ocamlopt:01 native-code:01 This message is in MIME format. --=_6v5sqhke9dw6 Content-Type: text/plain; charset=ISO-8859-1 Content-Description: Plaintext Version of Message Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Jon, I=A0wanted to run the raytracing benchmark myself to see if Haskell really = was that slow. I'm using ghc 6.10 because that's what ubuntu comes with. I= =A0don't know if ghc 6.12 generates slower executables than 6.10 or what el= se might be going on. I=A0ran each several times and the numbers I=A0pasted= are typical (+/- 0.2 seconds, say). jeff@ubuntu:~/Desktop$ ghc --version The Glorious Glasgow Haskell Compilation System, version 6.10.4 jeff@ubuntu:~/Desktop$ g++ --version g++ (Ubuntu 4.4.1-4ubuntu8) 4.4.1 Copyright (C) 2009 Free Software Foundation, Inc. This is free software; see the source for copying conditions.=A0 There is N= O warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. jeff@ubuntu:~/Desktop$ ocamlopt -v The Objective Caml native-code compiler, version 3.11.1 Standard library directory: /usr/lib/ocaml I=A0compiled the raytracers for c++, haskell and ocaml from http://www.ffconsultancy.com/languages/ray_tracer/code/5 and used the compile instructions at http://www.ffconsultancy.com/languages/ray_tracer/benchmark.html though I=A0had to change the haskell one to use just ghc instead of specify= ing a version. I=A0also ran the ocaml and haskell code in the 1/ directory,= and they completed within 0.1 seconds of each other. c++ jeff@ubuntu:~/Desktop$ time ./ray 9 512 > /dev/null real=A0=A0=A0 0m3.515s user=A0=A0=A0 0m3.440s sys=A0=A0=A0 0m0.016s haskell jeff@ubuntu:~/Desktop$ time ./ray 9 512 > /dev/null real=A0=A0=A0 0m5.811s user=A0=A0=A0 0m5.752s sys=A0=A0=A0 0m0.032s ocaml jeff@ubuntu:~/Desktop$ time ./ray 9 512 > /dev/null real=A0=A0=A0 0m6.572s user=A0=A0=A0 0m6.544s sys=A0=A0=A0 0m0.016s Jeff --=_6v5sqhke9dw6 Content-Type: text/html; charset=ISO-8859-1 Content-Description: HTML Version of Message Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Jon,
I=A0wanted to run the raytracing benchmark myself to see if Haskell really = was that slow. I'm using ghc 6.10 because that's what ubuntu comes with. I= =A0don't know if ghc 6.12 generates slower executables than 6.10 or what el= se might be going on. I=A0ran each several times and the numbers I=A0pasted= are typical (+/- 0.2 seconds, say).

jeff@ubuntu:~/Desktop$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 6.10.4
jeff@ubuntu:~/Desktop$ g++ --version
g++ (Ubuntu 4.4.1-4ubuntu8) 4.4.1
Copyright (C) 2009 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.=A0 There is N= O
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.=

jeff@ubuntu:~/Desktop$ ocamlopt -v
The Objective Caml native-code compiler, version 3.11.1
Standard library directory: /usr/lib/ocaml

I=A0compiled the raytracers for c++, haskell and ocaml from

http://www.ffconsultancy.com/languages/ray_tracer/code/5

and used the compile instructions at

http://www.ffconsultancy.com/languages/ray_tracer/benchmark.html

though I=A0had to change the haskell one to use just ghc instead of specify= ing a version. I=A0also ran the ocaml and haskell code in the 1/ directory,= and they completed within 0.1 seconds of each other.

c++
jeff@ubuntu:~/Desktop$ time ./ray 9 512 > /dev/null

real=A0=A0=A0 0m3.515s
user=A0=A0=A0 0m3.440s
sys=A0=A0=A0 0m0.016s

haskell
jeff@ubuntu:~/Desktop$ time ./ray 9 512 > /dev/null

real=A0=A0=A0 0m5.811s
user=A0=A0=A0 0m5.752s
sys=A0=A0=A0 0m0.032s

ocaml
jeff@ubuntu:~/Desktop$ time ./ray 9 512 > /dev/null

real=A0=A0=A0 0m6.572s
user=A0=A0=A0 0m6.544s
sys=A0=A0=A0 0m0.016s

Jeff
--=_6v5sqhke9dw6--