80bit x87 FPU

Written by

in

, ,

Once again, I got surprised by the 80 bit x87 FPU stuff.

First time was around a decade ago. Back then, it was something along the lines of a sort function like:

With some values, first and would be smaller than second, and second smaller than first. All depending on which one got truncated to 64 bit, and which one came directly from the 80bit fpu.

This time, the 80 bit version when cast to integers was 1 smaller than the 64 bit version.

Oh. The joys of x86 CPU’s.

Comments

One response to “80bit x87 FPU”

  1. mirabilos Avatar
    mirabilos

    m68k also has an 80 bit mode…