
Hi Ben, Thanks for the reply
Incidentally, the collapse of LiftedRep and UnliftedRep will happen in GHC 9.2 (turning into `BoxedRep :: Levity -> RuntimeRep`).
Yes I believe this change was accidentally merged a few months ago then reverted? I will keep that in mind.
Can you provide a program that your patch rejects, as well as the full error that is produced?
My error is in stage 1 in the building of the ghc-bignum library. I have
attached the full error as well as the patch itself.
Thanks,
Shant
On Mon, Apr 5, 2021 at 7:41 PM Ben Gamari
Shant Hairapetian
writes: Hello,
I’m a master’s student working on implementing the changes outlined in “Kinds are Calling Conventions“ ( https://www.microsoft.com/en-us/research/uploads/prod/2020/03/kacc.pdf). I have been working directly with Paul Downen but have hit some roadblocks.
To sum up the changes to the kind system, I am attempting to modify the “TYPE” type constructor to accept, rather than just a RuntimeRep, a record type (called RuntimeInfo) comprised of a RuntimeRep and a CallingConv (calling convention). The calling convention has an “Eval” constructor which accepts a levity (effectively moving the levity information from the representation to the calling convention. LiftedRep and UnliftedRep would also be collapsed into a single PtrRep constructor) and a “Call” constructor (denoting the arity of primitive, extensional functions, see: Making a Faster Curry with Extensional Types < https://www.microsoft.com/en-us/research/uploads/prod/2019/07/arity-haskell-... ) which accepts a list of RuntimeRep’s. I have created and wired-in the new RuntimeInfo and CallingConv types in GHC.Builtin.Types, as well as the corresponding primitive types in GHC.Builtin.Types.Prim and have modified the “TYPE” constructor to accept a RuntimeInfo rather than a RuntimeRep.
Hi Shant,
It would be helpful to have a bit more information on the nature of your failure. Can you provide a program that your patch rejects, as well as the full error that is produced?
Incidentally, the collapse of LiftedRep and UnliftedRep will happen in GHC 9.2 (turning into `BoxedRep :: Levity -> RuntimeRep`).
Cheers,
- Ben
-- Shant Hairapetian