the cmm pages on the wiki seem out of date

Hey all, I've been staring at the cmm primop code in ghc over the past week to understand a number of things, and I was just today looking at the current cmm documentation on the ghc wiki. specifically i've been looking at https://github.com/ghc/ghc/blob/master/compiler/cmm/Cmm.hs https://github.com/ghc/ghc/blob/master/compiler/cmm/CmmParse.y and https://github.com/ghc/ghc/blob/master/rts/PrimOps.cmm versus the wiki docs http://hackage.haskell.org/trac/ghc/wiki/Commentary/Compiler/CmmType it looks like CMM supports a nicer function definition convention than the wiki implies. (and presumably that also would hold for the ffi for calling user written cmm code too?) If the wiki is out of date, i'm happy to make a first pass at trying to add this info somewhere, thanks -Carter

Yes, there were some pretty recent (as in, not present in 7.6) improvements to C-- syntax. Updates would be much appreciated; you can probably figure out what the changes are by snooping the changelogs for compiler/cmm. Edward Excerpts from Carter Schonwald's message of Fri Apr 05 20:37:23 -0700 2013:
Hey all, I've been staring at the cmm primop code in ghc over the past week to understand a number of things, and I was just today looking at the current cmm documentation on the ghc wiki.
specifically i've been looking at https://github.com/ghc/ghc/blob/master/compiler/cmm/Cmm.hs https://github.com/ghc/ghc/blob/master/compiler/cmm/CmmParse.y and https://github.com/ghc/ghc/blob/master/rts/PrimOps.cmm
versus the wiki docs http://hackage.haskell.org/trac/ghc/wiki/Commentary/Compiler/CmmType
it looks like CMM supports a nicer function definition convention than the wiki implies. (and presumably that also would hold for the ffi for calling user written cmm code too?)
If the wiki is out of date, i'm happy to make a first pass at trying to add this info somewhere,
thanks -Carter

Simon Marlow is the man who will really know. He's in the middle of getting to grips with Facebook but I'm sure he'll pop up soon. In general, yes please do update the wiki; thank you. Simon | -----Original Message----- | From: ghc-devs-bounces@haskell.org [mailto:ghc-devs-bounces@haskell.org] On | Behalf Of Edward Z. Yang | Sent: 06 April 2013 09:12 | To: Carter Schonwald | Cc: ghc-devs@haskell.org | Subject: Re: the cmm pages on the wiki seem out of date | | Yes, there were some pretty recent (as in, not present in 7.6) improvements | to C-- syntax. Updates would be much appreciated; you can probably figure out | what the changes are by snooping the changelogs for compiler/cmm. | | Edward | | Excerpts from Carter Schonwald's message of Fri Apr 05 20:37:23 -0700 2013: | > Hey all, I've been staring at the cmm primop code in ghc over the past week | > to understand a number of things, and I was just today looking at the | > current cmm documentation on the ghc wiki. | > | > specifically i've been looking at | > https://github.com/ghc/ghc/blob/master/compiler/cmm/Cmm.hs | > https://github.com/ghc/ghc/blob/master/compiler/cmm/CmmParse.y | > and | > https://github.com/ghc/ghc/blob/master/rts/PrimOps.cmm | > | > versus the wiki docs | > http://hackage.haskell.org/trac/ghc/wiki/Commentary/Compiler/CmmType | > | > it looks like CMM supports a nicer function definition convention than the | > wiki implies. | > (and presumably that also would hold for the ffi for calling user written | > cmm code too?) | > | > | > If the wiki is out of date, i'm happy to make a first pass at trying to add | > this info somewhere, | > | > thanks | > -Carter | | _______________________________________________ | ghc-devs mailing list | ghc-devs@haskell.org | http://www.haskell.org/mailman/listinfo/ghc-devs

A quick answer is that I put some documentation at the top of compiler/cmm/CmmParse.y that explains the new syntax. That should help you get to grips with the changes. Cheers, Simon On 06/04/13 13:48, Simon Peyton-Jones wrote:
Simon Marlow is the man who will really know. He's in the middle of getting to grips with Facebook but I'm sure he'll pop up soon.
In general, yes please do update the wiki; thank you.
Simon
| -----Original Message----- | From: ghc-devs-bounces@haskell.org [mailto:ghc-devs-bounces@haskell.org] On | Behalf Of Edward Z. Yang | Sent: 06 April 2013 09:12 | To: Carter Schonwald | Cc: ghc-devs@haskell.org | Subject: Re: the cmm pages on the wiki seem out of date | | Yes, there were some pretty recent (as in, not present in 7.6) improvements | to C-- syntax. Updates would be much appreciated; you can probably figure out | what the changes are by snooping the changelogs for compiler/cmm. | | Edward | | Excerpts from Carter Schonwald's message of Fri Apr 05 20:37:23 -0700 2013: | > Hey all, I've been staring at the cmm primop code in ghc over the past week | > to understand a number of things, and I was just today looking at the | > current cmm documentation on the ghc wiki. | > | > specifically i've been looking at | > https://github.com/ghc/ghc/blob/master/compiler/cmm/Cmm.hs | > https://github.com/ghc/ghc/blob/master/compiler/cmm/CmmParse.y | > and | > https://github.com/ghc/ghc/blob/master/rts/PrimOps.cmm | > | > versus the wiki docs | > http://hackage.haskell.org/trac/ghc/wiki/Commentary/Compiler/CmmType | > | > it looks like CMM supports a nicer function definition convention than the | > wiki implies. | > (and presumably that also would hold for the ffi for calling user written | > cmm code too?) | > | > | > If the wiki is out of date, i'm happy to make a first pass at trying to add | > this info somewhere, | > | > thanks | > -Carter | | _______________________________________________ | ghc-devs mailing list | ghc-devs@haskell.org | http://www.haskell.org/mailman/listinfo/ghc-devs
participants (4)
-
Carter Schonwald
-
Edward Z. Yang
-
Simon Marlow
-
Simon Peyton-Jones