[GHC] #7866: floor (0/0) :: Int is different with -O0 and -O1

GHC cvs-ghc at haskell.org
Fri Apr 26 11:18:31 CEST 2013


#7866: floor (0/0) :: Int is different with -O0 and -O1
----------------------------------------+-----------------------------------
Reporter:  alang9                       |          Owner:                
    Type:  bug                          |         Status:  new           
Priority:  normal                       |      Component:  Compiler      
 Version:  7.6.2                        |       Keywords:                
      Os:  Linux                        |   Architecture:  x86_64 (amd64)
 Failure:  Incorrect result at runtime  |      Blockedby:                
Blocking:                               |        Related:                
----------------------------------------+-----------------------------------
 This program:
 {{{
 main = print (floor (0/0) :: Int)
 }}}

 prints a different result with -O0:
 {{{
 0
 }}}
 and -O1:
 {{{
 -9223372036854775808
 }}}

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



More information about the ghc-tickets mailing list