Legacy apps in Windows/OS X was Re: Old MS-DOS & Win Software

Eric J Korpela korpela at ssl.berkeley.edu
Mon Dec 12 16:31:53 CST 2005

On 12/10/05, Jim Leonard <trixter at oldskool.org> wrote:

> I was always a little disappointed that the 8087 didn't speed up integer
> math
> any (FDIV was at least 193 cycles, whereas DIV is never more than 162)...
> I
> could have really used that.

It speeds up 32 bit and 64 bit integer math.....

Even on newer processors it was floating point was useful for many non-FP
things.  Desipte intel's documentation to the contrary, the fastest block
transfer loop on the (pre-MMX) Pentium was done using FILDQ-FISTPQ.

// GCC w/ AT&T Assembly warning!!!
inline void copy64(int *p1,int *p2, int n)
    test $1,%2
    jz 0f
    dec %2
    movl (%0,%2,4),%%ebx
    movl %%ebx,(%1,%2,4)
    shrl %2
    dec %2
    jl 2f
    fildq (%0,%2,8)
    fistpq (%1,%2,8)
    dec %2
    jge 1b
    : "S" (p1), "D" (p2), "c" (n)
    : "ebx");

More information about the cctech mailing list