mirror of git://sourceware.org/git/glibc.git
m68k: use math_force_eval in nextafterl
This commit is contained in:
parent
e1c5c75ea2
commit
eca60f6ed3
|
@ -1,5 +1,8 @@
|
||||||
2013-12-10 Andreas Schwab <schwab@linux-m68k.org>
|
2013-12-10 Andreas Schwab <schwab@linux-m68k.org>
|
||||||
|
|
||||||
|
* sysdeps/m68k/m680x0/fpu/s_nextafterl.c (__nextafterl): Use
|
||||||
|
math_force_eval.
|
||||||
|
|
||||||
* sysdeps/unix/sysv/linux/m68k/nptl/lowlevellock.h
|
* sysdeps/unix/sysv/linux/m68k/nptl/lowlevellock.h
|
||||||
(FUTEX_WAIT_REQEUE_PI, FUTEX_CMP_REQEUE_PI)
|
(FUTEX_WAIT_REQEUE_PI, FUTEX_CMP_REQEUE_PI)
|
||||||
(lll_futex_wait_requeue_pi, lll_futex_timed_wait_requeue_pi)
|
(lll_futex_wait_requeue_pi, lll_futex_timed_wait_requeue_pi)
|
||||||
|
|
|
@ -46,7 +46,8 @@ long double __nextafterl(long double x, long double y)
|
||||||
if((ix|hx|lx)==0) { /* x == 0 */
|
if((ix|hx|lx)==0) { /* x == 0 */
|
||||||
SET_LDOUBLE_WORDS(x,esy&0x8000,0,1);/* return +-minsubnormal */
|
SET_LDOUBLE_WORDS(x,esy&0x8000,0,1);/* return +-minsubnormal */
|
||||||
y = x*x;
|
y = x*x;
|
||||||
if(y==x) return y; else return x; /* raise underflow flag */
|
math_force_eval (y); /* raise underflow flag */
|
||||||
|
return x;
|
||||||
}
|
}
|
||||||
if(esx>=0) { /* x > 0 */
|
if(esx>=0) { /* x > 0 */
|
||||||
if(esx>esy||((esx==esy) && (hx>hy||((hx==hy)&&(lx>ly))))) {
|
if(esx>esy||((esx==esy) && (hx>hy||((hx==hy)&&(lx>ly))))) {
|
||||||
|
@ -91,10 +92,7 @@ long double __nextafterl(long double x, long double y)
|
||||||
if(esy==0x7fff) return x+x; /* overflow */
|
if(esy==0x7fff) return x+x; /* overflow */
|
||||||
if(esy==0 && (hx & 0x80000000) == 0) { /* underflow */
|
if(esy==0 && (hx & 0x80000000) == 0) { /* underflow */
|
||||||
y = x*x;
|
y = x*x;
|
||||||
if(y!=x) { /* raise underflow flag */
|
math_force_eval (y); /* raise underflow flag */
|
||||||
SET_LDOUBLE_WORDS(y,esx,hx,lx);
|
|
||||||
return y;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
SET_LDOUBLE_WORDS(x,esx,hx,lx);
|
SET_LDOUBLE_WORDS(x,esx,hx,lx);
|
||||||
return x;
|
return x;
|
||||||
|
|
Loading…
Reference in New Issue