Source-Changes-HG archive

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

[src/trunk]: src/lib/libc Revert previous change -- turned out I'd got my bui...



details:   https://anonhg.NetBSD.org/src/rev/72e427595d40
branches:  trunk
changeset: 494833:72e427595d40
user:      bjh21 <bjh21%NetBSD.org@localhost>
date:      Sat Jul 15 15:07:34 2000 +0000

description:
Revert previous change -- turned out I'd got my build environment in a twist.

diffstat:

 lib/libc/arch/arm26/softfloat/softfloat.h |    6 -
 lib/libc/arch/sh3/softfloat/softfloat.h   |    8 +-
 lib/libc/softfloat/softfloat-for-gcc.h    |    6 +-
 lib/libc/softfloat/softfloat.c            |  109 +-----------------------------
 4 files changed, 4 insertions(+), 125 deletions(-)

diffs (196 lines):

diff -r c4dc3c187f13 -r 72e427595d40 lib/libc/arch/arm26/softfloat/softfloat.h
--- a/lib/libc/arch/arm26/softfloat/softfloat.h Sat Jul 15 14:26:39 2000 +0000
+++ b/lib/libc/arch/arm26/softfloat/softfloat.h Sat Jul 15 15:07:34 2000 +0000
@@ -135,9 +135,6 @@
 */
 int float32_to_int32( float32 );
 int float32_to_int32_round_to_zero( float32 );
-#if defined(SOFTFLOAT_FOR_GCC) && !__GNUC_PREREQ__(2,95)
-unsigned int float32_to_uint32_round_to_zero( float32 );
-#endif
 long long float32_to_int64( float32 );
 long long float32_to_int64_round_to_zero( float32 );
 float64 float32_to_float64( float32 );
@@ -177,9 +174,6 @@
 */
 int float64_to_int32( float64 );
 int float64_to_int32_round_to_zero( float64 );
-#if defined(SOFTFLOAT_FOR_GCC) && !__GNUC_PREREQ__(2,95)
-unsigned int float64_to_uint32_round_to_zero( float64 );
-#endif
 long long float64_to_int64( float64 );
 long long float64_to_int64_round_to_zero( float64 );
 float32 float64_to_float32( float64 );
diff -r c4dc3c187f13 -r 72e427595d40 lib/libc/arch/sh3/softfloat/softfloat.h
--- a/lib/libc/arch/sh3/softfloat/softfloat.h   Sat Jul 15 14:26:39 2000 +0000
+++ b/lib/libc/arch/sh3/softfloat/softfloat.h   Sat Jul 15 15:07:34 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: softfloat.h,v 1.2 2000/07/15 13:26:51 bjh21 Exp $      */
+/*     $NetBSD: softfloat.h,v 1.3 2000/07/15 15:07:35 bjh21 Exp $      */
 
 /*
 ===============================================================================
@@ -138,9 +138,6 @@
 */
 int float32_to_int32( float32 );
 int float32_to_int32_round_to_zero( float32 );
-#if defined(SOFTFLOAT_FOR_GCC) && !__GNUC_PREREQ__(2,95)
-unsigned int float32_to_uint32_round_to_zero( float32 );
-#endif
 long long float32_to_int64( float32 );
 long long float32_to_int64_round_to_zero( float32 );
 float64 float32_to_float64( float32 );
@@ -180,9 +177,6 @@
 */
 int float64_to_int32( float64 );
 int float64_to_int32_round_to_zero( float64 );
-#if defined(SOFTFLOAT_FOR_GCC) && !__GNUC_PREREQ__(2,95)
-unsigned int float64_to_uint32_round_to_zero( float64 );
-#endif
 long long float64_to_int64( float64 );
 long long float64_to_int64_round_to_zero( float64 );
 float32 float64_to_float32( float64 );
diff -r c4dc3c187f13 -r 72e427595d40 lib/libc/softfloat/softfloat-for-gcc.h
--- a/lib/libc/softfloat/softfloat-for-gcc.h    Sat Jul 15 14:26:39 2000 +0000
+++ b/lib/libc/softfloat/softfloat-for-gcc.h    Sat Jul 15 15:07:34 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: softfloat-for-gcc.h,v 1.2 2000/07/15 13:26:51 bjh21 Exp $ */
+/* $NetBSD: softfloat-for-gcc.h,v 1.3 2000/07/15 15:07:35 bjh21 Exp $ */
 
 /*
  * Move private identifiers with external linkage into implementation
@@ -39,7 +39,3 @@
 /* #define float64_to_uint32_round_to_zero     __fixunsdfsi */
 #define float32_to_float64             __extendsfdf2
 #define float64_to_float32             __truncdfsf2
-#if !__GNUC_PREREQ__(2,95)
-#define float32_to_uint32_round_to_zero        __fixunssfsi
-#define float64_to_uint32_round_to_zero        __fixunsdfsi
-#endif
diff -r c4dc3c187f13 -r 72e427595d40 lib/libc/softfloat/softfloat.c
--- a/lib/libc/softfloat/softfloat.c    Sat Jul 15 14:26:39 2000 +0000
+++ b/lib/libc/softfloat/softfloat.c    Sat Jul 15 15:07:34 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: softfloat.c,v 1.2 2000/07/15 13:26:51 bjh21 Exp $ */
+/* $NetBSD: softfloat.c,v 1.3 2000/07/15 15:07:35 bjh21 Exp $ */
 
 /*
  * This version hacked for use with gcc -msoft-float by bjh21.
@@ -46,7 +46,7 @@
 
 #include <sys/cdefs.h>
 #if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: softfloat.c,v 1.2 2000/07/15 13:26:51 bjh21 Exp $");
+__RCSID("$NetBSD: softfloat.c,v 1.3 2000/07/15 15:07:35 bjh21 Exp $");
 #endif /* LIBC_SCCS and not lint */
 
 #ifdef SOFTFLOAT_FOR_GCC
@@ -5391,108 +5391,3 @@
 
 #endif
 
-/* Since about GCC 2.95, these functions have been in libgcc2.c */
-
-#if defined(SOFTFLOAT_FOR_GCC) && !__GNUC_PREREQ__(2,95)
-
-/*
- * These two routines are not part of the original softfloat distribution.
- *
- * They are based on the corresponding conversions to integer but return
- * unsigned numbers instead since these functions are required by GCC.
- *
- * Added by Mark Brinicombe <mark%netbsd.org@localhost>        27/09/97
- *
- * float64 version overhauled for SoftFloat 2a [bjh21 2000-07-15]
- */
-
-/*
--------------------------------------------------------------------------------
-Returns the result of converting the double-precision floating-point value
-`a' to the 32-bit unsigned integer format.  The conversion is
-performed according to the IEC/IEEE Standard for Binary Floating-point
-Arithmetic, except that the conversion is always rounded toward zero.  If
-`a' is a NaN, the largest positive integer is returned.  If the conversion
-overflows, the largest integer positive is returned.
--------------------------------------------------------------------------------
-*/
-uint32 float64_to_uint32_round_to_zero( float64 a )
-{
-    flag aSign;
-    int16 aExp, shiftCount;
-    bits64 aSig, savedASig;
-    uint32 z;
-
-    aSig = extractFloat64Frac( a );
-    aExp = extractFloat64Exp( a );
-    aSign = extractFloat64Sign( a );
-
-    if (aSign) {
-        float_raise( float_flag_invalid );
-       return(0);
-    }
-
-    if ( 0x41E < aExp ) {
-        float_raise( float_flag_invalid );
-        return 0xffffffff;
-    }
-    else if ( aExp < 0x3FF ) {
-        if ( aExp || aSig ) float_exception_flags |= float_flag_inexact;
-        return 0;
-    }
-    aSig |= LIT64( 0x0010000000000000 );
-    shiftCount = 0x433 - aExp;
-    savedASig = aSig;
-    aSig >>= shiftCount;
-    z = aSig;
-    if ( ( aSig<<shiftCount ) != savedASig ) {
-        float_exception_flags |= float_flag_inexact;
-    }
-    return z;
-
-}
-
-/*
--------------------------------------------------------------------------------
-Returns the result of converting the single-precision floating-point value
-`a' to the 32-bit unsigned integer format.  The conversion is
-performed according to the IEC/IEEE Standard for Binary Floating-point
-Arithmetic, except that the conversion is always rounded toward zero.  If
-`a' is a NaN, the largest positive integer is returned.  If the conversion
-overflows, the largest positive integer is returned.
--------------------------------------------------------------------------------
-*/
-uint32 float32_to_uint32_round_to_zero( float32 a )
-{
-    flag aSign;
-    int16 aExp, shiftCount;
-    bits32 aSig;
-    uint32 z;
-
-    aSig = extractFloat32Frac( a );
-    aExp = extractFloat32Exp( a );
-    aSign = extractFloat32Sign( a );
-    shiftCount = aExp - 0x9E;
-
-    if (aSign) {
-        float_raise( float_flag_invalid );
-       return(0);
-    }
-    if ( 0 < shiftCount ) {
-        float_raise( float_flag_invalid );
-        return 0xFFFFFFFF;
-    }
-    else if ( aExp <= 0x7E ) {
-        if ( aExp | aSig ) float_exception_flags |= float_flag_inexact;
-        return 0;
-    }
-    aSig = ( aSig | 0x800000 )<<8;
-    z = aSig>>( - shiftCount );
-    if ( aSig<<( shiftCount & 31 ) ) {
-        float_exception_flags |= float_flag_inexact;
-    }
-    return z;
-
-}
-
-#endif



Home | Main Index | Thread Index | Old Index