#2156: compilation math/truncate bug with optimization enabled
----------------------+-----------------------------------------------------
 Reporter:  trevorm   |          Owner:         
     Type:  bug       |         Status:  closed 
 Priority:  normal    |      Milestone:         
Component:  Compiler  |        Version:  6.8.2  
 Severity:  critical  |     Resolution:  wontfix
 Keywords:            |     Difficulty:  Unknown
 Testcase:            |   Architecture:  x86    
       Os:  Linux     |  
----------------------+-----------------------------------------------------
Changes (by simonmar):

  * status:  new => closed
  * difficulty:  => Unknown
  * resolution:  => wontfix

Comment:

 So I take it this is an instance of the unpredictability in floating-point
 that we get on x86 due to the floating point registers being wider than a
 Double?

 When compiling via C we use gcc's `-ffloat-store` which forces the
 precision to be 64 bits everywhere (albeit expensively).  The native code
 generator does not do this, although #594 will fix it eventually.

 See also #1916, where the previously buggy truncate implementation was
 fixed in the x86 native code gen in 6.8.2.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2156#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to