Skip to content

the GHC IEEE Float and NCG improvement project: remove x87 registers from x86/x86_64 native code gen.

Carter Schonwald requested to merge wip/carter/remove_x87Registers into master

https://ghc.haskell.org/trac/ghc/ticket/8949#comment:16 preliminary work to remove x87 registers from NCG

currently on x87, rounding of floating point subexpressions is essentially nondeterministic to haskell developers unless they look at the exact way we do register allocation/code gen for the FPU stack.

Also the x87 warts kinda creep into a lot of incidental complexity that I genuninely think impacts NCG contributors (when those rare souls appear)

the final nail in the coffin in my mind is that supporting / using x87 registers at all as part of improving FPU state tracking / resumption (which has been on my want to do list for a while), would entail adding a bunch more data multiple words of size to a TSO, and it'd be nice to keep any added weight to the size of a CInt on intel platforms (on most other platforms the lib C rep seems to be about a single word / C Int)

Edited by Carter Schonwald

Merge request reports