Re: Benchmarking GHC

2006-10-19 Thread Ketil Malde
Neil Mitchell [EMAIL PROTECTED] writes: I want to benchmark GHC vs some other Haskell compilers, what flags should I use? [...] I guess the answer is -O2 -fvia-C? I tend to use -O2, but haven't really tested it against plain -O. From what I've seen -fvia-C is sometimes faster, sometimes

Re: Benchmarking GHC

2006-10-19 Thread Donald Bruce Stewart
ketil+haskell: Neil Mitchell [EMAIL PROTECTED] writes: I want to benchmark GHC vs some other Haskell compilers, what flags should I use? [...] I guess the answer is -O2 -fvia-C? I tend to use -O2, but haven't really tested it against plain -O. From what I've seen -fvia-C is

Re: Benchmarking GHC

2006-10-19 Thread Neil Mitchell
Hi One thing that IME makes a difference is -funbox-strict-fields. It's probably better to use pragmas for this, though. Another thing to consider is garbage collection RTS flags, those can sometimes make a big difference. I _don't_ want to speed up a particular program by modifying

pinned byte arrays

2006-10-19 Thread Bulat Ziganshin
Hello glasgow-haskell-users, i have program that holds in memory a lot of strings (filenames) and use my own packed-string library to represent these string. this library uses newByteArray# to allocate strings. in my benchmark run (with 300.000 filenames in memory) program prints the following

Re: [Haskell] Expecting more inlining for bit shifting

2006-10-19 Thread John Meacham
On Wed, Oct 18, 2006 at 07:00:18AM -0400, [EMAIL PROTECTED] wrote: I'm not sure this approach is best. In my case the ... needs to be the entire body of the shift code. It would be ridiculous to have two copies of the same code. What would be better is a hint pragma that says, ``inline

RE: Benchmarking GHC

2006-10-19 Thread Simon Peyton-Jones
These days -O2, which invokes the SpecConstr pass, can have a big effect, but only on some programs. Simon | -Original Message- | From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] | On Behalf Of Neil Mitchell | Sent: 19 October 2006 11:22 | To: Donald Bruce Stewart | Cc: GHC Users

recursive commentaries :)

2006-10-19 Thread Bulat Ziganshin
Hello glasgow-haskell-users, http://hackage.haskell.org/trac/ghc/wiki/Commentary contains a link 'The old GHC Commentary' which points to the http://www.cse.unsw.edu.au/~chak/haskell/ghc/comm/ page. guess what this page contains? :) it will be great to restore link to old commentaries -- Best

Re: Re[2]: Benchmarking GHC

2006-10-19 Thread Duncan Coutts
On Thu, 2006-10-19 at 21:10 +0400, Bulat Ziganshin wrote: btw, writing this message i thought that -fconvert-strings-to-ByteStrings option will give a significant boost to many programs without rewriting them :) This kind of data refinement has a side condition on the strictness of the

Re: pinned byte arrays

2006-10-19 Thread Duncan Coutts
Pinning the arrays gives the GC much less flexibility. Especially if your objects are small. It means that the GC can't move things to compact the heap and you'll end up with lots of holes in between heap objects of things that were collected but the space couldn't be re-used because other objects