Rev. 1.50, 10/04, page 359 of 448
union {
long double x;
int l[4];
} tmpx;
if(FPSCR_PR == 0) {
tmpd.d = FR[n]; /* Single-precision to double-precision */
tmpd.d *= FR[m]; /* Precise creation */
tmpf.f *= FR[m]; /* Round to nearest */
if(tmpf.f != tmpd.d) set_I();
if((tmpf.f > tmpd.d) && (FPSCR_RM == 1)) {
tmpf.l -= 1; /* Round to zero */
}
check_single_exception(&FR[n],tmpf.f);
} else {
tmpx.x = DR[n>>1]; /* Single-precision to double-precision */
tmpx.x *= DR[m>>1]; /* Precise creation */
tmpd.d *= DR[m>>1]; /* Round to nearest */
if(tmpd.d != tmpx.x) set_I();
if(tmpd.d > tmpx.x) && (FPSCR_RM == 1)) {
tmpd.l[1] -= 1; /* Round to zero */
if(tmpd.l[1] == 0xffffffff) tmpd.l[0] -= 1;
}
check_double_exception(&DR[n>>1], tmpd.d);
}
}
void fipr(int m,n)
{
union {
double d;
int l[2];
} mlt[4];