[GHC] #13370: exprIsBottom inconsistend with strictness analyser

GHC ghc-devs at haskell.org
Fri Mar 3 11:59:12 UTC 2017


#13370: exprIsBottom inconsistend with strictness analyser
-------------------------------------+-------------------------------------
        Reporter:  simonpj           |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  8.0.1
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by simonpj):

 PS: the inconsistency actually appears as lint warnings
 {{{
     No alternatives for a case scrutinee not known to diverge for sure:
 tcGetDefaultTys6
 }}}
 This happens because `FloatOut` hoist an expression like the RHS of `f`
 above to top level; and then uses `exprBotStrictness_maybe` to give it a
 cheap-and-cheerful strictness signature, one that says it diverges.  That
 sig enables GHC to discard case alternatives.  But then the final demand-
 analysis phase, just before CoreTidy, returns a more conservative verdict,
 after which the lint warnings appear.

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


More information about the ghc-tickets mailing list