RE: The role of INLINE and INLINABLE on recursive functions

2011-06-09 Thread Simon Peyton-Jones
INLINE: - no effect for a recursive function - for a non-recursive function, always inline a call that (a) is applied to as many args as the LHS of the defn (b) has some interesting context. Ie (\y x- f x y) doesn't inline f INLINEABLE a) For type-class

Re: The role of INLINE and INLINABLE on recursive functions

2011-06-09 Thread Johan Tibell
On Thu, Jun 9, 2011 at 1:43 PM, Simon Peyton-Jones simo...@microsoft.com wrote: Does that help? Definitely. Thanks! Johan ___ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org

Using CPP in Cmm

2011-06-09 Thread Johan Tibell
Hi, I'm trying to write a test case to make sure memset gets unrolled correctly by the backend. Unrolling only happens when the alignment and size is statically known so writing a simple Cmm loop that calls memset won't work as the sizes won't be statically known. I want to test memset with a

RE: crash caused by generic visitor (?)

2011-06-09 Thread Simon Peyton-Jones
Great, thanks. I've added that link to the user-documentation page for the GHC API, here http://haskell.org/haskellwiki/GHC/As_a_library#Links Please do elaborate that page, which is a bit thin at the moment. It should be easier to find supporting info about the GHC API. Simon |

Re: The role of INLINE and INLINABLE on recursive functions

2011-06-09 Thread Simon Marlow
On 09/06/2011 12:43, Simon Peyton-Jones wrote: INLINE: - no effect for a recursive function - for a non-recursive function, always inline a call that (a) is applied to as many args as the LHS of the defn (b) has some interesting context. Ie (\y x- f x y) doesn't

Re: Using CPP in Cmm

2011-06-09 Thread Thorkil Naur
Hello, On Thu, Jun 09, 2011 at 03:44:43PM +0200, Johan Tibell wrote: ... I initially tried to use the CPP ## string concatenation operator to create unique names (tedious, but works) but GHC runs CPP in traditional mode so that doesn't work. One -traditional way that I have used to

Re: How to install GhC on a Mac without registering?

2011-06-09 Thread Manuel M T Chakravarty
[Ian, sorry for the duplicate — wrong sender email at first.] Ian Lynagh: On Mon, Jun 06, 2011 at 03:47:57PM +0100, Malcolm Wallace wrote: On 6 Jun 2011, at 13:49, Lyndon Maydwell wrote: I would be fantastic if XCode wasn't a dependency. ... Not to detract at all from the work of the