Home | History | Annotate | Download | only in fpu

Lines Matching defs:x0

62  * Our task is to calculate the square root of a floating point number x0.
131 * a 1 bit in the first trip around the loop (since x0 < 2^NBITS). If the
137 * and the result q will then be sqrt(x0) * 2^floor(NBITS / 2).
139 * value, for which q is some power of two times its square root, x0.)
144 * q = y = 0; x = x0;
160 * If x0 is fixed point, rather than an integer, we can simply alter the
161 * scale factor between q and sqrt(x0). As it happens, we can easily arrange
162 * for the scale factor to be 2**0 or 1, so that sqrt(x0) == q.
164 * In our case, however, x0 (and therefore x, y, q, and t) are multiword
174 * intermediate calculations can overflow. We know that x0 is in [1..4)
197 u_int x0, x1, x2, x3;
245 FPU_ADDCS(x1, x1, x1); FPU_ADDC(x0, x0, x0); \
249 x0 = (x0 << 1) | (x1 >> 31); x1 = (x1 << 1) | (x2 >> 31); \
260 x0 = x->fp_mant[0];
294 x0 -= bit;
301 if (x0 >= t0) { /* if x >= t then */
302 x0 -= t0; /* x -= t */
320 FPU_SUBC(d0, x0, t0); /* d = x - t */
322 x0 = d0, x1 = d1; /* x -= t */
331 FPU_SUBC(d0, x0, t0);
333 x0 = d0, x1 = d1;
352 FPU_SUBC(d0, x0, t0);
354 x0 = d0, x1 = d1, x2 = d2;
364 FPU_SUBC(d0, x0, t0);
366 x0 = d0, x1 = d1, x2 = d2;
386 FPU_SUBC(d0, x0, t0);
388 x0 = d0, x1 = d1, x2 = d2; x3 = d3;
399 FPU_SUBC(d0, x0, t0);
401 x0 = d0, x1 = d1, x2 = d2; x3 = d3;
413 x->fp_sticky = x0 | x1 | x2 | x3;