15 May 22:56
Re: Write Haskell as fast as C. [Was: Re: GHC predictability]
From: Don Stewart <dons <at> galois.com>
Subject: Re: Write Haskell as fast as C. [Was: Re: GHC predictability]
Newsgroups: gmane.comp.lang.haskell.cafe
Date: 2008-05-15 20:56:01 GMT
Subject: Re: Write Haskell as fast as C. [Was: Re: GHC predictability]
Newsgroups: gmane.comp.lang.haskell.cafe
Date: 2008-05-15 20:56:01 GMT
moonlite: > On Thu, 2008-05-15 at 11:31 -0700, Don Stewart wrote: > > I've written an extended post on how to understand and reliably optimise > > code like this, looking at it all the way down to the assembly. > > > > The result are some simple rules to follow for generated code as good > > as gcc -O2. > > > > Enjoy, > > > > http://cgi.cse.unsw.edu.au/~dons/blog/2008/05/16#fast > > A good read. > > Side point: Is the name "go" part of the idiom you mentioned? I > sometimes use the same practise but usually just calls the worker the > same as the real function with an added prime ('). I moved away from that idiom as it was too easy to call the wrapper by accident, by leaving off a prime. In large libraries, I sometimes add the wrapper name to the 'go', so I can find it in the core later, e.g. f x y = go_f 0 where go_f .. -- Don
RSS Feed