[GHC] #5658: Strict bindings are wrongly floated out of case alternatives.

GHC cvs-ghc at haskell.org
Fri Jan 6 15:54:36 CET 2012


#5658: Strict bindings are wrongly floated out of case alternatives.
---------------------------------+------------------------------------------
    Reporter:  benl              |       Owner:  benl            
        Type:  bug               |      Status:  new             
    Priority:  normal            |   Milestone:  7.4.1           
   Component:  Compiler          |     Version:  7.2.1           
    Keywords:                    |          Os:  Unknown/Multiple
Architecture:  Unknown/Multiple  |     Failure:  Runtime crash   
  Difficulty:  Unknown           |    Testcase:                  
   Blockedby:                    |    Blocking:                  
     Related:                    |  
---------------------------------+------------------------------------------

Comment(by rl):

 Oh, I see, I thought that the patches also affected runtime costs. But can
 we agree that floating array accesses (or any primops, for that matter)
 out of conditionals is a bug even if those accesses aren't marked as
 `can_fail`? I really don't see how this can possibly be beneficial since
 the only thing it can achieve is doing unnecessary work. But if array
 accesses can't be floated out of conditionals then there is no reason to
 mark them as `can_fail` because they will never be floated past bounds
 checks anyway.

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



More information about the Glasgow-haskell-bugs mailing list