[GHC] #11518: Test TcCoercibleFail hangs with substitution sanity checks enabled

GHC ghc-devs at haskell.org
Wed Feb 3 12:47:50 UTC 2016


#11518: Test TcCoercibleFail hangs with substitution sanity checks enabled
-------------------------------------+-------------------------------------
        Reporter:  niteria           |                Owner:  niteria
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler (Type    |              Version:  8.1
  checker)                           |
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  Compile-time      |  Unknown/Multiple
  performance bug                    |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by simonpj):

 I don't know.  I still don't understand WHY this assert is causing
 exponential behaviour in this example and I'm reluctant to suppress it
 until we know.

 In `typecheck/should_fail/TcCoercibleFail` I see
 {{{
 newtype Fix f = Fix (f (Fix f))
 foo6 = coerce :: Fix (Either Int) -> Fix (Either Age)
 foo7 = coerce :: Fix (Either Int) -> ()
 }}}
 which is presumably the cause of the problem?  But that looks nothing like
 the example in comment:8.  Nor can I see where 100-level unwrappping would
 happen. So I'm lost.

 Fortunately it doesn't affect a normal stage-2 validate.

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


More information about the ghc-tickets mailing list