Changes to primops break libraries (was Re: 7.8 Feature window)

Jan Stolarek jan.stolarek at p.lodz.pl
Sun Aug 25 21:16:56 CEST 2013


> We really want people to use the new primops, not the wrappers
We do? Could you justify why we want to people to use primops? Wrappers are equivalent to previous 
implementation of primops: previously we had call to tagToEnum# generated implicitly by the code 
generator, whereas now we have an explicit call to tagToEnum# in the source code of the wrappers. 
I don't see a reason why we might want to break people's code, except for maybe making them aware 
that there was some change in primops implementation. I think that from the beginning new primops 
were meant to be used in branchless algorithms - most people don't need that. Also, Simon PJ has 
come up with an idea for some optimisations that would deal with tagToEnum# at the Core level, 
but I will almost certainly not have time to implement them during my internship.

> Is it too late to change this?
I think that before 7.8 is released we can change anything we want in these primops. We just need 
to decide what we want - I've spent last Friday on making primops change completely backwards 
compatible.

Janek




More information about the ghc-devs mailing list