x86_64 FPU: Set 64-bit precision for fadd/fsub/fsqrt etc.
authorJohn Marino <netbsd@marino.st>
Thu, 12 Jul 2012 11:15:12 +0000 (13:15 +0200)
committerJohn Marino <draco@marino.st>
Sat, 14 Jul 2012 08:57:10 +0000 (10:57 +0200)
commit4e1f876965f7f6ef75345e19a70d504d865cc27a
treea45cd556841090ecb56e81d29f15cf4ae1d1a311
parentb4ff333e9005d88cb2dde8fc6552780f730603f3
x86_64 FPU: Set 64-bit precision for fadd/fsub/fsqrt etc.

On AMD64, GCC and the ABI expects the x87 unit to be running in 80/64
mode rather than 64/53 mode seen on i386.  This corrects errors seen
in long double tests involving runtime calculations.  Previously, the
results of these runtime calculations would get rounded due to use
of 53-bit mantissas.
sys/platform/pc64/x86_64/machdep.c
sys/platform/pc64/x86_64/mp_machdep.c
sys/platform/pc64/x86_64/npx.c
sys/platform/vkernel64/x86_64/cpu_regs.c
sys/platform/vkernel64/x86_64/npx.c