haskell / primitive

This package provides various primitive memory-related operations.
Other
114 stars 58 forks source link

Adapt to recent GHC changes in runRW# compilation #334

Open treeowl opened 2 years ago

treeowl commented 2 years ago

GHC now tries to push a few things (I'm not sure what exactly) into runRW# blocks. I guess this is sometimes good? But when inlining doesn't happen, it's rather bad, because our trick of pulling constructors out of those blocks is now being defeated. Ugh! I'm not sure exactly what to do about this, aside from complaining to GHC HQ.

simonpj commented 2 years ago

Please complain! But please do so by saying "Here is a short bit code that compiles much better with GHC 8.10 than with HEAD". Concrete evidence is vastly more motivating, and actionable, than unsupported assertions.

chessai commented 2 years ago

I wasn't aware of a change of this nature being made, so a code example would be appreciated