* Prefix softfloat symbols which require external linkage with _arm32_ to

move them out of user namespace; declare those not requiring external linkage
static.
* In due course, disable those functions that require neither external nor
internal linkage.
Addresses PR port-arm32/7517.
This commit is contained in:
kleink 1999-05-06 13:56:28 +00:00
parent fc1b5041ac
commit c66e4d7122
7 changed files with 116 additions and 49 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: environment.h,v 1.4 1998/06/28 20:19:30 christos Exp $ */ /* $NetBSD: environment.h,v 1.5 1999/05/06 13:56:28 kleink Exp $ */
/* /*
=============================================================================== ===============================================================================
@ -45,3 +45,19 @@ a compiler does not support inlining, this macro should be defined to be
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
#define INLINE static __inline #define INLINE static __inline
/*
-------------------------------------------------------------------------------
Move private identifiers with external linkage into implementation namespace.
-- Klaus Klein <kleink@netbsd.org>, May 5, 1999
-------------------------------------------------------------------------------
*/
#define float_exception_flags _arm32_float_exception_flags
#define float_rounding_mode _arm32_float_rounding_mode
#define float32_eq _arm32_float32_eq
#define float32_le _arm32_float32_le
#define float32_lt _arm32_float32_lt
#define float64_eq _arm32_float64_eq
#define float64_le _arm32_float64_le
#define float64_lt _arm32_float64_lt
#define float_raise _arm32_float_raise

View File

@ -1,4 +1,4 @@
/* $NetBSD: fplib_glue.S,v 1.1 1997/10/12 21:18:08 mark Exp $ */ /* $NetBSD: fplib_glue.S,v 1.2 1999/05/06 13:56:28 kleink Exp $ */
/*- /*-
* Copyright (c) 1997 The NetBSD Foundation, Inc. * Copyright (c) 1997 The NetBSD Foundation, Inc.
@ -48,13 +48,13 @@
*/ */
ENTRY(__eqsf2) ENTRY(__eqsf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float32_eq bl _C_LABEL(_arm32_float32_eq)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}
ENTRY(__eqdf2) ENTRY(__eqdf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float64_eq bl _C_LABEL(_arm32_float64_eq)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}
@ -66,13 +66,13 @@ ENTRY(__eqdf2)
*/ */
ENTRY(__nesf2) ENTRY(__nesf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float32_eq bl _C_LABEL(_arm32_float32_eq)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}
ENTRY(__nedf2) ENTRY(__nedf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float64_eq bl _C_LABEL(_arm32_float64_eq)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}
@ -85,13 +85,13 @@ ENTRY(__nedf2)
*/ */
ENTRY(__gtsf2) ENTRY(__gtsf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float32_le bl _C_LABEL(_arm32_float32_le)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}
ENTRY(__gtdf2) ENTRY(__gtdf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float64_le bl _C_LABEL(_arm32_float64_le)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}
@ -101,7 +101,7 @@ ENTRY(__gtdf2)
*/ */
ENTRY(__gesf2) ENTRY(__gesf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float32_lt bl _C_LABEL(_arm32_float32_lt)
eor r0, r0, #1 eor r0, r0, #1
cmp r0, #0 cmp r0, #0
mvneq r0, #0 mvneq r0, #0
@ -109,7 +109,7 @@ ENTRY(__gesf2)
ENTRY(__gedf2) ENTRY(__gedf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float64_lt bl _C_LABEL(_arm32_float64_lt)
eor r0, r0, #1 eor r0, r0, #1
cmp r0, #0 cmp r0, #0
mvneq r0, #0 mvneq r0, #0
@ -120,14 +120,14 @@ ENTRY(__gedf2)
*/ */
ENTRY(__ltsf2) ENTRY(__ltsf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float32_lt bl _C_LABEL(_arm32_float32_lt)
cmp r0, #1 cmp r0, #1
mvneq r0, #0 mvneq r0, #0
ldmfd sp!, {pc} ldmfd sp!, {pc}
ENTRY(__ltdf2) ENTRY(__ltdf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float64_lt bl _C_LABEL(_arm32_float64_lt)
cmp r0, #1 cmp r0, #1
mvneq r0, #0 mvneq r0, #0
ldmfd sp!, {pc} ldmfd sp!, {pc}
@ -137,13 +137,13 @@ ENTRY(__ltdf2)
*/ */
ENTRY(__lesf2) ENTRY(__lesf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float32_le bl _C_LABEL(_arm32_float32_le)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}
ENTRY(__ledf2) ENTRY(__ledf2)
stmfd sp!, {lr} stmfd sp!, {lr}
bl _float64_le bl _C_LABEL(_arm32_float64_le)
eor r0, r0, #1 eor r0, r0, #1
ldmfd sp!, {pc} ldmfd sp!, {pc}

View File

@ -1,4 +1,4 @@
/* $NetBSD: fplib_libc.c,v 1.2 1997/10/13 21:28:53 mark Exp $ */ /* $NetBSD: fplib_libc.c,v 1.3 1999/05/06 13:56:28 kleink Exp $ */
/*- /*-
* Copyright (c) 1997 The NetBSD Foundation, Inc. * Copyright (c) 1997 The NetBSD Foundation, Inc.
@ -37,6 +37,7 @@
*/ */
#include <sys/types.h> #include <sys/types.h>
#include "environment.h"
#include "softfloat.h" #include "softfloat.h"
void sfp_setround __P((int rnd_dir)); void sfp_setround __P((int rnd_dir));

View File

@ -1,4 +1,4 @@
/* $NetBSD: softfloat-macros.h,v 1.4 1998/04/24 18:46:53 cgd Exp $ */ /* $NetBSD: softfloat-macros.h,v 1.5 1999/05/06 13:56:28 kleink Exp $ */
/* /*
=============================================================================== ===============================================================================
@ -115,7 +115,9 @@ INLINE void mul64To128(
static bits32 estimateDiv64To32( bits32 a0, bits32 a1, bits32 b ); static bits32 estimateDiv64To32( bits32 a0, bits32 a1, bits32 b );
#if 0 /* unused */
static bits32 estimateSqrt32( int16 aExp, bits32 a ); static bits32 estimateSqrt32( int16 aExp, bits32 a );
#endif
static int8 countLeadingZeros( bits32 a ); static int8 countLeadingZeros( bits32 a );
@ -608,6 +610,7 @@ static bits32 estimateDiv64To32( bits32 a0, bits32 a1, bits32 b )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns an approximation to the square root of the 32-bit significand given Returns an approximation to the square root of the 32-bit significand given
@ -647,6 +650,7 @@ static bits32 estimateSqrt32( int16 aExp, bits32 a )
return ( ( estimateDiv64To32( a, 0, z ) )>>1 ) + ( z>>1 ); return ( ( estimateDiv64To32( a, 0, z ) )>>1 ) + ( z>>1 );
} }
#endif /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------

View File

@ -1,4 +1,4 @@
/* $NetBSD: softfloat-specialize.h,v 1.3 1998/01/06 00:06:12 perry Exp $ */ /* $NetBSD: softfloat-specialize.h,v 1.4 1999/05/06 13:56:28 kleink Exp $ */
/* /*
=============================================================================== ===============================================================================
@ -30,15 +30,15 @@ this code that are retained.
=============================================================================== ===============================================================================
*/ */
flag float32_is_signaling_nan( float32 a ); static flag float32_is_signaling_nan( float32 a );
flag float64_is_signaling_nan( float64 a ); static flag float64_is_signaling_nan( float64 a );
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Underflow tininess-detection mode. (Statically initialized to default.) Underflow tininess-detection mode. (Statically initialized to default.)
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float_detect_tininess = float_tininess_after_rounding; static flag float_detect_tininess = float_tininess_after_rounding;
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
@ -81,7 +81,7 @@ Returns true if the single-precision floating-point value `a' is a signaling
NaN; otherwise returns false. NaN; otherwise returns false.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float32_is_signaling_nan( float32 a ) static flag float32_is_signaling_nan( float32 a )
{ {
return ( ( a & 0x7FC00000 ) == 0x7F800000 ) && ( a & 0x003FFFFF ); return ( ( a & 0x7FC00000 ) == 0x7F800000 ) && ( a & 0x003FFFFF );
@ -94,7 +94,7 @@ Returns true if the double-precision floating-point value `a' is a signaling
NaN; otherwise returns false. NaN; otherwise returns false.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float64_is_signaling_nan( float64 a ) static flag float64_is_signaling_nan( float64 a )
{ {
return return

View File

@ -1,4 +1,4 @@
/* $NetBSD: softfloat.c,v 1.3 1998/01/06 00:06:12 perry Exp $ */ /* $NetBSD: softfloat.c,v 1.4 1999/05/06 13:56:28 kleink Exp $ */
/* /*
=============================================================================== ===============================================================================
@ -564,6 +564,7 @@ float64 int32_to_float64( int32 a )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns the result of converting the single-precision floating-point value Returns the result of converting the single-precision floating-point value
@ -575,7 +576,7 @@ positive integer is returned. If the conversion overflows, the largest
integer with the same sign as `a' is returned. integer with the same sign as `a' is returned.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
int32 float32_to_int32( float32 a ) static int32 float32_to_int32( float32 a )
{ {
flag aSign; flag aSign;
int16 aExp, shiftCount; int16 aExp, shiftCount;
@ -631,6 +632,7 @@ int32 float32_to_int32( float32 a )
return z; return z;
} }
#endif /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
@ -705,6 +707,7 @@ float64 float32_to_float64( float32 a )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns the result of converting the double-precision floating-point value Returns the result of converting the double-precision floating-point value
@ -716,7 +719,8 @@ positive integer is returned. If the conversion overflows, the largest
integer with the same sign as `a' is returned. integer with the same sign as `a' is returned.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
int32 float64_to_int32( float64 a )
static int32 float64_to_int32( float64 a )
{ {
flag aSign; flag aSign;
int16 aExp, shiftCount; int16 aExp, shiftCount;
@ -778,6 +782,7 @@ int32 float64_to_int32( float64 a )
return z; return z;
} }
#endif /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
@ -864,6 +869,7 @@ float32 float64_to_float32( float64 a )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Rounds the single-precision floating-point value `a' to an integer, and Rounds the single-precision floating-point value `a' to an integer, and
@ -872,7 +878,7 @@ operation is performed according to the IEC/IEEE Standard for Binary
Floating-point Arithmetic. Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float32 float32_round_to_int( float32 a ) static float32 float32_round_to_int( float32 a )
{ {
flag aSign; flag aSign;
int16 aExp; int16 aExp;
@ -924,6 +930,7 @@ float32 float32_round_to_int( float32 a )
return z; return z;
} }
#endif /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
@ -1249,6 +1256,7 @@ float32 float32_div( float32 a, float32 b )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns the remainder of the single-precision floating-point value `a' Returns the remainder of the single-precision floating-point value `a'
@ -1256,7 +1264,7 @@ with respect to the corresponding value `b'. The operation is performed
according to the IEC/IEEE Standard for Binary Floating-point Arithmetic. according to the IEC/IEEE Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float32 float32_rem( float32 a, float32 b ) static float32 float32_rem( float32 a, float32 b )
{ {
flag aSign, bSign, zSign; flag aSign, bSign, zSign;
int16 aExp, bExp, expDiff; int16 aExp, bExp, expDiff;
@ -1337,7 +1345,9 @@ float32 float32_rem( float32 a, float32 b )
return normalizeRoundAndPackFloat32( aSign ^ zSign, bExp, aSig ); return normalizeRoundAndPackFloat32( aSign ^ zSign, bExp, aSig );
} }
#endif /* unused */
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns the square root of the single-precision floating-point value `a'. Returns the square root of the single-precision floating-point value `a'.
@ -1345,7 +1355,7 @@ The operation is performed according to the IEC/IEEE Standard for Binary
Floating-point Arithmetic. Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float32 float32_sqrt( float32 a ) static float32 float32_sqrt( float32 a )
{ {
flag aSign; flag aSign;
int16 aExp, zExp; int16 aExp, zExp;
@ -1391,6 +1401,7 @@ float32 float32_sqrt( float32 a )
return roundAndPackFloat32( 0, zExp, zSig ); return roundAndPackFloat32( 0, zExp, zSig );
} }
#endif /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
@ -1465,6 +1476,7 @@ flag float32_lt( float32 a, float32 b )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns true if the single-precision floating-point value `a' is equal to Returns true if the single-precision floating-point value `a' is equal to
@ -1473,7 +1485,8 @@ raised if either operand is a NaN. The comparison is performed according to
the IEC/IEEE Standard for Binary Floating-point Arithmetic. the IEC/IEEE Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float32_eq_signaling( float32 a, float32 b )
static flag float32_eq_signaling( float32 a, float32 b )
{ {
if ( ( ( extractFloat32Exp( a ) == 0xFF ) && extractFloat32Frac( a ) ) if ( ( ( extractFloat32Exp( a ) == 0xFF ) && extractFloat32Frac( a ) )
@ -1485,7 +1498,9 @@ flag float32_eq_signaling( float32 a, float32 b )
return ( a == b ) || bothZeroFloat32( a, b ); return ( a == b ) || bothZeroFloat32( a, b );
} }
#endif /* unused */
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns true if the single-precision floating-point value `a' is less than Returns true if the single-precision floating-point value `a' is less than
@ -1494,7 +1509,7 @@ do not cause an exception. The comparison is performed according to the
IEC/IEEE Standard for Binary Floating-point Arithmetic. IEC/IEEE Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float32_le_quiet( float32 a, float32 b ) static flag float32_le_quiet( float32 a, float32 b )
{ {
flag aSign, bSign; flag aSign, bSign;
/* int16 aExp, bExp;*/ /* int16 aExp, bExp;*/
@ -1513,7 +1528,9 @@ flag float32_le_quiet( float32 a, float32 b )
return ( a == b ) || ( aSign ^ ( a < b ) ); return ( a == b ) || ( aSign ^ ( a < b ) );
} }
#endif /* unused */
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns true if the single-precision floating-point value `a' is less than Returns true if the single-precision floating-point value `a' is less than
@ -1522,7 +1539,7 @@ an exception. The comparison is performed according to the IEC/IEEE
Standard for Binary Floating-point Arithmetic. Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float32_lt_quiet( float32 a, float32 b ) static flag float32_lt_quiet( float32 a, float32 b )
{ {
flag aSign, bSign; flag aSign, bSign;
@ -1540,7 +1557,9 @@ flag float32_lt_quiet( float32 a, float32 b )
return ( a != b ) && ( aSign ^ ( a < b ) ); return ( a != b ) && ( aSign ^ ( a < b ) );
} }
#endif /* unused */
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Rounds the double-precision floating-point value `a' to an integer, and Rounds the double-precision floating-point value `a' to an integer, and
@ -1549,7 +1568,7 @@ operation is performed according to the IEC/IEEE Standard for Binary
Floating-point Arithmetic. Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float64 float64_round_to_int( float64 a ) static float64 float64_round_to_int( float64 a )
{ {
flag aSign; flag aSign;
int16 aExp; int16 aExp;
@ -1641,6 +1660,7 @@ float64 float64_round_to_int( float64 a )
return z; return z;
} }
#endif /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
@ -2000,6 +2020,7 @@ float64 float64_div( float64 a, float64 b )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns the remainder of the double-precision floating-point value `a' Returns the remainder of the double-precision floating-point value `a'
@ -2007,7 +2028,7 @@ with respect to the corresponding value `b'. The operation is performed
according to the IEC/IEEE Standard for Binary Floating-point Arithmetic. according to the IEC/IEEE Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float64 float64_rem( float64 a, float64 b ) static float64 float64_rem( float64 a, float64 b )
{ {
flag aSign, bSign, zSign; flag aSign, bSign, zSign;
int16 aExp, bExp, expDiff; int16 aExp, bExp, expDiff;
@ -2105,7 +2126,9 @@ float64 float64_rem( float64 a, float64 b )
normalizeRoundAndPackFloat64( aSign ^ zSign, bExp - 4, aSig0, aSig1 ); normalizeRoundAndPackFloat64( aSign ^ zSign, bExp - 4, aSig0, aSig1 );
} }
#endif /* unused */
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns the square root of the double-precision floating-point value `a'. Returns the square root of the double-precision floating-point value `a'.
@ -2113,7 +2136,7 @@ The operation is performed according to the IEC/IEEE Standard for Binary
Floating-point Arithmetic. Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float64 float64_sqrt( float64 a ) static float64 float64_sqrt( float64 a )
{ {
flag aSign; flag aSign;
int16 aExp, zExp; int16 aExp, zExp;
@ -2179,6 +2202,7 @@ float64 float64_sqrt( float64 a )
return roundAndPackFloat64( 0, zExp, zSig0, zSig1, zSig2 ); return roundAndPackFloat64( 0, zExp, zSig0, zSig1, zSig2 );
} }
#endif /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
@ -2271,6 +2295,7 @@ flag float64_lt( float64 a, float64 b )
} }
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns true if the double-precision floating-point value `a' is equal to Returns true if the double-precision floating-point value `a' is equal to
@ -2279,7 +2304,7 @@ raised if either operand is a NaN. The comparison is performed according to
the IEC/IEEE Standard for Binary Floating-point Arithmetic. the IEC/IEEE Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float64_eq_signaling( float64 a, float64 b ) static flag float64_eq_signaling( float64 a, float64 b )
{ {
if ( ( ( extractFloat64Exp( a ) == 0x7FF ) if ( ( ( extractFloat64Exp( a ) == 0x7FF )
@ -2295,7 +2320,9 @@ flag float64_eq_signaling( float64 a, float64 b )
&& ( ( a.high == b.high ) || bothZeroFloat64( a, b ) ); && ( ( a.high == b.high ) || bothZeroFloat64( a, b ) );
} }
#endif /* unused */
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns true if the double-precision floating-point value `a' is less than Returns true if the double-precision floating-point value `a' is less than
@ -2304,7 +2331,7 @@ do not cause an exception. The comparison is performed according to the
IEC/IEEE Standard for Binary Floating-point Arithmetic. IEC/IEEE Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float64_le_quiet( float64 a, float64 b ) static flag float64_le_quiet( float64 a, float64 b )
{ {
bits32 a0, a1, b0, b1; bits32 a0, a1, b0, b1;
flag aSign, bSign; flag aSign, bSign;
@ -2329,7 +2356,9 @@ flag float64_le_quiet( float64 a, float64 b )
return aSign ? le64( b0, b1, a0, a1 ) : le64( a0, a1, b0, b1 ); return aSign ? le64( b0, b1, a0, a1 ) : le64( a0, a1, b0, b1 );
} }
#endif /* unused */
#if 0 /* unused */
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Returns true if the double-precision floating-point value `a' is less than Returns true if the double-precision floating-point value `a' is less than
@ -2338,7 +2367,7 @@ an exception. The comparison is performed according to the IEC/IEEE
Standard for Binary Floating-point Arithmetic. Standard for Binary Floating-point Arithmetic.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
flag float64_lt_quiet( float64 a, float64 b ) static flag float64_lt_quiet( float64 a, float64 b )
{ {
bits32 a0, a1, b0, b1; bits32 a0, a1, b0, b1;
flag aSign, bSign; flag aSign, bSign;
@ -2363,6 +2392,7 @@ flag float64_lt_quiet( float64 a, float64 b )
return aSign ? lt64( b0, b1, a0, a1 ) : lt64( a0, a1, b0, b1 ); return aSign ? lt64( b0, b1, a0, a1 ) : lt64( a0, a1, b0, b1 );
} }
#endif /* unused */
/* /*

View File

@ -1,4 +1,4 @@
/* $NetBSD: softfloat.h,v 1.3 1998/01/06 00:06:13 perry Exp $ */ /* $NetBSD: softfloat.h,v 1.4 1999/05/06 13:56:28 kleink Exp $ */
/* /*
=============================================================================== ===============================================================================
@ -102,10 +102,14 @@ Software IEC/IEEE floating-point conversion routines.
*/ */
float32 int32_to_float32( int ); float32 int32_to_float32( int );
float64 int32_to_float64( int ); float64 int32_to_float64( int );
int float32_to_int32( float32 ); #if 0 /* unused */
static int float32_to_int32( float32 );
#endif
int float32_to_int32_round_to_zero( float32 ); int float32_to_int32_round_to_zero( float32 );
float64 float32_to_float64( float32 ); float64 float32_to_float64( float32 );
int float64_to_int32( float64 ); #if 0 /* unused */
static int float64_to_int32( float64 );
#endif
int float64_to_int32_round_to_zero( float64 ); int float64_to_int32_round_to_zero( float64 );
float32 float64_to_float32( float64 ); float32 float64_to_float32( float64 );
unsigned int float64_to_uint32_round_to_zero( float64 a ); unsigned int float64_to_uint32_round_to_zero( float64 a );
@ -116,35 +120,47 @@ unsigned int float32_to_uint32_round_to_zero( float32 a );
Software IEC/IEEE single-precision operations. Software IEC/IEEE single-precision operations.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float32 float32_round_to_int( float32 ); #if 0 /* unused */
static float32 float32_round_to_int( float32 );
#endif
float32 float32_add( float32, float32 ); float32 float32_add( float32, float32 );
float32 float32_sub( float32, float32 ); float32 float32_sub( float32, float32 );
float32 float32_mul( float32, float32 ); float32 float32_mul( float32, float32 );
float32 float32_div( float32, float32 ); float32 float32_div( float32, float32 );
float32 float32_rem( float32, float32 ); #if 0 /* unused */
float32 float32_sqrt( float32 ); static float32 float32_rem( float32, float32 );
static float32 float32_sqrt( float32 );
#endif
char float32_eq( float32, float32 ); char float32_eq( float32, float32 );
char float32_le( float32, float32 ); char float32_le( float32, float32 );
char float32_lt( float32, float32 ); char float32_lt( float32, float32 );
char float32_eq_signaling( float32, float32 ); #if 0 /* unused */
char float32_le_quiet( float32, float32 ); static char float32_eq_signaling( float32, float32 );
char float32_lt_quiet( float32, float32 ); static char float32_le_quiet( float32, float32 );
static char float32_lt_quiet( float32, float32 );
#endif
/* /*
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
Software IEC/IEEE double-precision operations. Software IEC/IEEE double-precision operations.
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
*/ */
float64 float64_round_to_int( float64 ); #if 0 /* unused */
static float64 float64_round_to_int( float64 );
#endif
float64 float64_add( float64, float64 ); float64 float64_add( float64, float64 );
float64 float64_sub( float64, float64 ); float64 float64_sub( float64, float64 );
float64 float64_mul( float64, float64 ); float64 float64_mul( float64, float64 );
float64 float64_div( float64, float64 ); float64 float64_div( float64, float64 );
float64 float64_rem( float64, float64 ); #if 0 /* unused */
float64 float64_sqrt( float64 ); static float64 float64_rem( float64, float64 );
static float64 float64_sqrt( float64 );
#endif
char float64_eq( float64, float64 ); char float64_eq( float64, float64 );
char float64_le( float64, float64 ); char float64_le( float64, float64 );
char float64_lt( float64, float64 ); char float64_lt( float64, float64 );
#if 0 /* unused */
char float64_eq_signaling( float64, float64 ); char float64_eq_signaling( float64, float64 );
#endif
char float64_le_quiet( float64, float64 ); char float64_le_quiet( float64, float64 );
char float64_lt_quiet( float64, float64 ); char float64_lt_quiet( float64, float64 );