Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Jeff Shaw <shawjef3@msu.edu>
To: Jon Harrop <jon@ffconsultancy.com>
Cc: caml-list@yquem.inria.fr
Subject: Re: [Caml-list] Re: HLVM ray tracer performance
Date: Sun, 10 Jan 2010 19:47:26 -0500	[thread overview]
Message-ID: <4B4A751E.1050905@msu.edu> (raw)
In-Reply-To: <201001102014.29726.jon@ffconsultancy.com>


> Are you running x64 or on Intel hardware? What results do you get for 12, 13
> or 14 instead of 9?
>
>    
I am running an AMD Phenom 9950, but the Ubuntu I'm using is just 
32-bit. I tried 5/ray.hs with level=12 instead of 9 but it ran into a 
stack overflow problem. When I increased the stack size it completed but 
it also took more time than 1/ray.hs, which required no stack size 
increase. I made sure that the other arguments I fed it were the same. I 
think there is some problem that needs to be worked out in the 5/ray.hs. 
Maybe the problem is in ghc, I'm not sure. Below, ./ray5 is 5/ray.hs, 
and ./ray is 1/ray.hs

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

real    0m21.479s
user    0m21.093s
sys    0m0.180s
jeff@ubuntu:~/Desktop$ time ./ray5 12 512 +RTS -K2000000000 > /dev/null

real    0m28.366s
user    0m25.674s
sys    0m2.608s
jeff@ubuntu:~/Desktop$ time ./ray 14 512 > /dev/null

real    0m23.544s
user    0m23.021s
sys    0m0.500s

I tried level=14 but I ran out of memory for 5/ray.ml and 5/ray.hs.

I considered that maybe I had saved the files from your website wrong, 
or mixed them up during compilation. So I ran the timer again with 
level=9 and level=12 and got all the same results. That is, level=9 is 
faster on 5/ray.hs but level=12 is faster with 1/ray.hs. So I don't 
think I'm making a simple manual labor error.

It seems that 5/ray.ml and 5/ray.hs aren't quite equivalent in some 
important way since 1/ray.ml is faster than 5/ray.ml for both level=9 
and level=12. Whether it's a code problem or compiler problem, I cannot say.

The stack size problem does not go away when I remove all the extra 
optimization arguments to ghc.

--Jeff


  parent reply	other threads:[~2010-01-11  0:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-10 18:29 shawjef3
2010-01-10 20:14 ` [Caml-list] " Jon Harrop
2010-01-10 20:37   ` Richard Jones
2010-01-11 11:03     ` Jon Harrop
2010-01-11  0:47   ` Jeff Shaw [this message]
2010-01-11 10:48     ` Jon Harrop

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B4A751E.1050905@msu.edu \
    --to=shawjef3@msu.edu \
    --cc=caml-list@yquem.inria.fr \
    --cc=jon@ffconsultancy.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox