8000 minix/lib/libc/gdtoa/strtodg.c at v3.2.0 · devinblood/minix · GitHub
[go: up one dir, main page]

Skip to content

Latest commit

 

History

History
1069 lines (1032 loc) · 20.9 KB

strtodg.c

File metadata and controls

1069 lines (1032 loc) · 20.9 KB
k = rvb0->wds - 1;
if (denorm)
/* do nothing */;
else if (rvb->wds <= k
|| hi0bits( rvb->x[k]) >
hi0bits(rvb0->x[k])) {
/* unlikely; can only have lost 1 high bit */
if (rve1 == emin) {
--rvbits;
denorm = 1;
}
else {
rvb = lshift(rvb, 1);
if (rvb == NULL)
return STRTOG_NoMemory;
--rve;
--rve1;
L = finished = 0;
}
}
}
else {
rvb = sum(rvb, ab);
if (rvb == NULL)
return STRTOG_NoMemory;
k = rvb->wds - 1;
if (k >= rvb0->wds
|| hi0bits(rvb->x[k]) < hi0bits(rvb0->x[k])) {
if (denorm) {
if (++rvbits == nbits)
denorm = 0;
}
else {
rshift(rvb, 1);
rve++;
rve1++;
L = 0;
}
}
}
Bfree(ab);
Bfree(rvb0);
if (finished)
break;
z = rve + rvbits;
0