[GHC] #9125: int-to-float conversion broken on ARM
GHC
ghc-devs at haskell.org
Tue Jul 15 02:17:40 UTC 2014
#9125: int-to-float conversion broken on ARM
-------------------------------------+-------------------------------------
Reporter: Ansible | Owner:
Type: bug | Status: new
Priority: highest | Milestone: 7.8.4
Component: Compiler | Version: 7.8.3
Resolution: | Keywords:
Differential Revisions: | Operating System: Unknown/Multiple
Architecture: arm | Type of failure: Incorrect result
Difficulty: Unknown | at runtime
Blocked By: | Test Case:
Related Tickets: | Blocking:
-------------------------------------+-------------------------------------
Comment (by amurrayc):
So here's a thing:
On a hunch I switched the assignments of `r1` and `r2` in
`stg_decodeFloatzuIntzh` so that it now reads
{{{
r2 = W_[mp_tmp1];
r1 = W_[mp_tmp_w];
}}}
with everything else the same.
What do you know,
{{{
let (m,e) = decodeFloat (29.0 :: Float)
estr = printf "%#x" e
putStrLn $ "(" ++ show m ++ ", " ++ estr ++ ")"
}}}
gives
{{{
(-19, 0xe80000)
}}}
Does that give anyone any clues?
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9125#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list