patch applied (ghc): Desugaring for "foreign import prim"

Ian Lynagh igloo at earth.li
Mon Jun 22 16:25:58 EDT 2009


Tue Jun  9 03:59:45 PDT 2009  Duncan Coutts <duncan at well-typed.com>
  * Desugaring for "foreign import prim"
  Unlike normal foreign imports which desugar into a separate worker and
  wrapper, we use just a single wrapper decleration. The representation
  in Core of the call is currently as a foreign call. This means the
  args are all treated as fully strict. This is ok at the moment because
  we restrict the types for foreign import prim to be of unboxed types,
  however in future we may want to make prim imports be the normal cmm
  calling convention for Haskell functions, in which case we would not
  be able to assume all args are strict. At that point it may make more
  sense to represent cmm/prim calls distinct from foreign calls, and
  more like the we the existing PrimOp calls are handled.

    M ./compiler/deSugar/DsForeign.lhs -1 +36

View patch online:
http://darcs.haskell.org/ghc/_darcs/patches/20090609105945-b0bbe-130391871f1c21de0e5f4b865af5ffb6a7c8dace.gz



More information about the Cvs-ghc mailing list