[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[commits] r8805 - in /libdfp/trunk: ieee754r/frexpd32.c ieee754r/ldexpd32.c sysdeps/soft-dfp/dpd/numdigits.h



Author: ryanarn
Date: Wed Aug 12 11:26:04 2009
New Revision: 8805

Log:
2009-08-11  Andreas Krebbel  <krebbel@xxxxxxxxxxxxxxxxxx>

	* ieee754r/ldexpd32.c (ldexpd32): Use FUNC_D wrapper around getexp.
	* ieee754r/frexpd32.c (frexpd32): Use FUNC_D wrapper around numdigits
	and getexp.
	* sysdeps/soft-dfp/dpd/numdigits.h (numdigits getexp): Use FUNC_D
	wrapper.


Modified:
    libdfp/trunk/ieee754r/frexpd32.c
    libdfp/trunk/ieee754r/ldexpd32.c
    libdfp/trunk/sysdeps/soft-dfp/dpd/numdigits.h

Modified: libdfp/trunk/ieee754r/frexpd32.c
==============================================================================
--- libdfp/trunk/ieee754r/frexpd32.c (original)
+++ libdfp/trunk/ieee754r/frexpd32.c Wed Aug 12 11:26:04 2009
@@ -50,8 +50,8 @@
   if (isinf(x) || isnan(x))
     return x+x;
 
-  digits = numdigits(x);
-  exponent = getexp(x);
+  digits = FUNC_D (numdigits) (x);
+  exponent = FUNC_D (getexp) (x);
   *y = digits + exponent;
 
   /* I think this was an error.  */

Modified: libdfp/trunk/ieee754r/ldexpd32.c
==============================================================================
--- libdfp/trunk/ieee754r/ldexpd32.c (original)
+++ libdfp/trunk/ieee754r/ldexpd32.c Wed Aug 12 11:26:04 2009
@@ -46,7 +46,7 @@
   long newexp;
 
 #if NUMDIGITS_SUPPORT==1
-  newexp = getexp(x) + y + 1;
+  newexp = FUNC_D (getexp) (x) + y + 1;
   if (newexp > PASTE(DECIMAL,PASTE(_DECIMAL_SIZE,_Emax)))
     {
     result = DFP_HUGE_VAL;

Modified: libdfp/trunk/sysdeps/soft-dfp/dpd/numdigits.h
==============================================================================
--- libdfp/trunk/sysdeps/soft-dfp/dpd/numdigits.h (original)
+++ libdfp/trunk/sysdeps/soft-dfp/dpd/numdigits.h Wed Aug 12 11:26:04 2009
@@ -51,7 +51,7 @@
 #endif
 
 static inline int
-getexp (DEC_TYPE x)
+FUNC_D (getexp) (DEC_TYPE x)
 {
   int exp;
   struct ieee754r_c_field c_f;
@@ -184,7 +184,7 @@
 }
 
 static inline int
-numdigits (DEC_TYPE x)
+FUNC_D (numdigits) (DEC_TYPE x)
 {
   int firstdigit = 0;
 #if _DECIMAL_SIZE == 32
@@ -223,7 +223,7 @@
       /* pad the significant digits with enough trailing zeroes */
       memset(digits + firstdigit + len, '0', firstdigit);
       x = setdigits(x, digits + firstdigit);
-      x = FUNC_D(setexp) (x, getexp(x) - firstdigit);
+      x = FUNC_D(setexp) (x, FUNC_D (getexp(x)) - firstdigit);
     }
 
   return x;