[GHC] #13750: GHC produces incorrect coercions in hairy code

GHC ghc-devs at haskell.org
Mon May 29 08:10:30 UTC 2017


#13750: GHC produces incorrect coercions in hairy code
-------------------------------------+-------------------------------------
        Reporter:  dfeuer            |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  highest           |            Milestone:  8.2.2
       Component:  Compiler          |              Version:  8.2.1-rc2
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  Runtime crash     |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:  #13429            |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by kosmikus):

 Simon, thanks for taking a look, and sorry for the "bad" test program.
 Yes, this very much originated in code littered with unsafeCoerce, which
 was an experiment, and I already spent several hours to condense it down
 to the size it currently has. The code compiles and behaves ok with older
 GHCs.

 Many further attempts at simplification just make it work (such as
 reducing to a single module, or simplifying seemingly unrelated
 functions).

 I'm fully aware that this is nowhere near a simple and easy to reproduce
 example. If it helps, I can invest more time to do so. On the other hand,
 if you have a reasonably clear idea what's going wrong, I'd prefer not to.

 In the meantime, I'll try the workaround you suggest. All this is in a
 codebase that's currently just an experiment. If it doesn't work reliably,
 I cannot move forward with the experiment, but it's not mission critical
 to me. My main worry is that it looks like it's a regression that might
 also affect arbitrary other things in subtle ways.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13750#comment:7>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list