Benchmarking GHC

Donald Bruce Stewart dons at cse.unsw.edu.au
Thu Oct 19 03:27:00 EDT 2006


ketil+haskell:
> "Neil Mitchell" <ndmitchell at gmail.com> 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 slower, I
> tend to cross my fingers and hope the compiler uses sensible defaults
> on the current architecture.
> 
> 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.

All this and more on the under-publicised Performance wiki,
    http://haskell.org/haskellwiki/Performance

-- Don


More information about the Glasgow-haskell-users mailing list