* sysdeps/i386/fpu/s_nextafterl.c (__nextafterl): Hopefully fix
the handling of denormalized numbers.
* math/test-misc.c (main): Test for fpclassify and pseudo denormal
numbers on x86.
* sysdeps/i386/fpu/fpclassifyl.c: New file.
2000-12-03 Ulrich Drepper <drepper@redhat.com>
- * math/test-misc.c (main): Test for pseudo denormal numbers on x86.
- * sysdeps/i386/fpu/fpclassify.c: New file.
+ * sysdeps/i386/fpu/s_nextafterl.c (__nextafterl): Hopefully fix
+ the handling of denormalized numbers.
+
+ * math/test-misc.c (main): Test for fpclassify and pseudo denormal
+ numbers on x86.
+ * sysdeps/i386/fpu/fpclassifyl.c: New file.
* sysdeps/i386/ldbl2mpn.c (__mpn_extract_long_double): Handle the
pseudo denormal representation of LDBL_MIN.
if(ix>iy||((ix==iy) && (hx>hy||((hx==hy)&&(lx>ly))))) {
/* x > y, x -= ulp */
if(lx==0) {
- if (hx==0) esx -= 1;
- hx -= 1;
+ if (hx <= 0x80000000) {
+ if (esx == 0)
+ hx = 0;
+ else {
+ esx -= 1;
+ hx = hx - 1;
+ if (esx > 0)
+ hx |= 0x80000000;
+ }
+ } else
+ hx -= 1;
}
lx -= 1;
} else { /* x < y, x += ulp */
if(esy>=0||(ix>iy||((ix==iy)&&(hx>hy||((hx==hy)&&(lx>ly)))))){
/* x < y, x -= ulp */
if(lx==0) {
- if (hx==0) esx -= 1;
- hx -= 1;
+ if (hx <= 0x80000000) {
+ if (esx == 0)
+ hx = 0;
+ else {
+ esx -= 1;
+ hx = hx - 1;
+ if (esx > 0)
+ hx |= 0x80000000;
+ }
+ } else
+ hx -= 1;
}
lx -= 1;
} else { /* x > y, x += ulp */