It seems that the fpu instructions fmul and fdiv and not computing the results to the full extended precision - a 64 bit mantissa. It seems to be getting answers correct to 19 digits for the sin and cos of 1, but there are problems with simple multiplication and division. What is the point of being able to calculating sin and costo 19 digits when mul and div only work to 16 digits? The following code exemplifies what I mean:

fld1

fsincos

OK - sin and cos are correct to the full extended precision

fld1

fld st0

fadd st0,st0

fadd st0,st1 ; st0 = 3.0 , st1 = 1.0

fdivp st1,st0 ; st0 = 0.333333333333333315

fld st0

fmulp st1,st0 ; st0 = 0.111111111111111105

After the division here, the result to correct only to double precision. The final result of 1/9 is also correct only to double precision.

Also, loading thevalue of 1/3 correct to extended precision twiceand then multiplying still only gives the result of 1/9 correct only to double precision.

What is going on here?