about summary refs log tree commit diff
path: root/sysdeps/m68k
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/m68k')
-rw-r--r--sysdeps/m68k/fpu/__math.h4
-rw-r--r--sysdeps/m68k/fpu/s_llrint.c (renamed from sysdeps/m68k/fpu/s_rinttoll.c)4
-rw-r--r--sysdeps/m68k/fpu/s_lrint.c (renamed from sysdeps/m68k/fpu/s_rinttol.c)6
-rw-r--r--sysdeps/m68k/fpu/s_remquo.c9
4 files changed, 7 insertions, 16 deletions
diff --git a/sysdeps/m68k/fpu/__math.h b/sysdeps/m68k/fpu/__math.h
index fd90a2de1b..bdeaa9efb0 100644
--- a/sysdeps/m68k/fpu/__math.h
+++ b/sysdeps/m68k/fpu/__math.h
@@ -309,7 +309,7 @@ __inline_functions (float,f)
 __inline_functions (long double,l)
 #undef __inline_functions
 
-__m81_defun (long int, __rinttol, (long double __x))
+__m81_defun (long int, __lrint, (long double __x))
 {
   long int __result;
   __asm ("fmove%.l %1, %0" : "=dm" (__result) : "f" (__x));
@@ -391,7 +391,7 @@ __inline_forward_c(int,ilogbl, (long double __value), (__value))
 #endif
 #ifdef __USE_ISOC9X
 __inline_forward_c(long double,nearbyintl, (long double __value), (__value))
-__inline_forward_c(long int,rinttol, (long double __value), (__value))
+__inline_forward_c(long int,lrint, (long double __value), (__value))
 #endif
 #ifdef __USE_GNU
 __inline_forward(void,sincosl,
diff --git a/sysdeps/m68k/fpu/s_rinttoll.c b/sysdeps/m68k/fpu/s_llrint.c
index bad8082bd1..f5d0d51122 100644
--- a/sysdeps/m68k/fpu/s_rinttoll.c
+++ b/sysdeps/m68k/fpu/s_llrint.c
@@ -24,7 +24,7 @@
 #include "math_private.h"
 
 long long int
-__rinttoll (long double x)
+__llrint (long double x)
 {
   int32_t se, sx;
   u_int32_t h, l;
@@ -59,4 +59,4 @@ __rinttoll (long double x)
   return result;
 }
 
-weak_alias (__rinttoll, rinttoll)
+weak_alias (__llrint, llrint)
diff --git a/sysdeps/m68k/fpu/s_rinttol.c b/sysdeps/m68k/fpu/s_lrint.c
index 7476d785a6..a7044113af 100644
--- a/sysdeps/m68k/fpu/s_rinttol.c
+++ b/sysdeps/m68k/fpu/s_lrint.c
@@ -23,9 +23,9 @@
 #include <math.h>
 
 long int
-__rinttol (long double x)
+__lrint (long double x)
 {
-  return __m81_u(__rinttol) (x);
+  return __m81_u(__lrint) (x);
 }
 
-weak_alias (__rinttol, rinttol)
+weak_alias (__lrint, lrint)
diff --git a/sysdeps/m68k/fpu/s_remquo.c b/sysdeps/m68k/fpu/s_remquo.c
index 3682ba7896..0332eccfd0 100644
--- a/sysdeps/m68k/fpu/s_remquo.c
+++ b/sysdeps/m68k/fpu/s_remquo.c
@@ -37,18 +37,9 @@ s(__remquo) (float_type x, float_type y, int *quo)
   float_type result;
   int cquo, fpsr;
 
-  /* FIXME: Which of frem and fmod is correct?  */
-#if 1
   __asm ("frem%.x %2,%0\n\tfmove%.l %/fpsr,%1"
 	 : "=f" (result), "=dm" (fpsr) : "f" (y), "0" (x));
   cquo = (fpsr >> 16) & 0x7f;
-  if ((result > 0) != (x > 0))
-    cquo--;
-#else
-  __asm ("fmod%.x %2,%0\n\tfmove%.l %/fpsr,%1"
-	 : "=f" (result), "=dm" (fpsr) : "f" (y), "0" (x));
-  cquo = (fpsr >> 16) & 0x7f;
-#endif
   if (fpsr & (1 << 23))
     cquo = -cquo;
   *quo = cquo;