applies clang-format changes
This commit is contained in:
@ -37,9 +37,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
#ifndef primitives_h
|
||||
#define primitives_h 1
|
||||
|
||||
#include "primitiveTypes.h"
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
#include "primitiveTypes.h"
|
||||
|
||||
#ifndef softfloat_shortShiftRightJam64
|
||||
/*----------------------------------------------------------------------------
|
||||
@ -50,10 +50,9 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
uint64_t softfloat_shortShiftRightJam64( uint64_t a, uint_fast8_t dist )
|
||||
{ return a>>dist | ((a & (((uint_fast64_t) 1<<dist) - 1)) != 0); }
|
||||
uint64_t softfloat_shortShiftRightJam64(uint64_t a, uint_fast8_t dist) { return a >> dist | ((a & (((uint_fast64_t)1 << dist) - 1)) != 0); }
|
||||
#else
|
||||
uint64_t softfloat_shortShiftRightJam64( uint64_t a, uint_fast8_t dist );
|
||||
uint64_t softfloat_shortShiftRightJam64(uint64_t a, uint_fast8_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -68,13 +67,11 @@ uint64_t softfloat_shortShiftRightJam64( uint64_t a, uint_fast8_t dist );
|
||||
| is zero or nonzero.
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE uint32_t softfloat_shiftRightJam32( uint32_t a, uint_fast16_t dist )
|
||||
{
|
||||
return
|
||||
(dist < 31) ? a>>dist | ((uint32_t) (a<<(-dist & 31)) != 0) : (a != 0);
|
||||
INLINE uint32_t softfloat_shiftRightJam32(uint32_t a, uint_fast16_t dist) {
|
||||
return (dist < 31) ? a >> dist | ((uint32_t)(a << (-dist & 31)) != 0) : (a != 0);
|
||||
}
|
||||
#else
|
||||
uint32_t softfloat_shiftRightJam32( uint32_t a, uint_fast16_t dist );
|
||||
uint32_t softfloat_shiftRightJam32(uint32_t a, uint_fast16_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -89,13 +86,11 @@ uint32_t softfloat_shiftRightJam32( uint32_t a, uint_fast16_t dist );
|
||||
| is zero or nonzero.
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (3 <= INLINE_LEVEL)
|
||||
INLINE uint64_t softfloat_shiftRightJam64( uint64_t a, uint_fast32_t dist )
|
||||
{
|
||||
return
|
||||
(dist < 63) ? a>>dist | ((uint64_t) (a<<(-dist & 63)) != 0) : (a != 0);
|
||||
INLINE uint64_t softfloat_shiftRightJam64(uint64_t a, uint_fast32_t dist) {
|
||||
return (dist < 63) ? a >> dist | ((uint64_t)(a << (-dist & 63)) != 0) : (a != 0);
|
||||
}
|
||||
#else
|
||||
uint64_t softfloat_shiftRightJam64( uint64_t a, uint_fast32_t dist );
|
||||
uint64_t softfloat_shiftRightJam64(uint64_t a, uint_fast32_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -112,10 +107,9 @@ extern const uint_least8_t softfloat_countLeadingZeros8[256];
|
||||
| 'a'. If 'a' is zero, 16 is returned.
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE uint_fast8_t softfloat_countLeadingZeros16( uint16_t a )
|
||||
{
|
||||
INLINE uint_fast8_t softfloat_countLeadingZeros16(uint16_t a) {
|
||||
uint_fast8_t count = 8;
|
||||
if ( 0x100 <= a ) {
|
||||
if(0x100 <= a) {
|
||||
count = 0;
|
||||
a >>= 8;
|
||||
}
|
||||
@ -123,7 +117,7 @@ INLINE uint_fast8_t softfloat_countLeadingZeros16( uint16_t a )
|
||||
return count;
|
||||
}
|
||||
#else
|
||||
uint_fast8_t softfloat_countLeadingZeros16( uint16_t a );
|
||||
uint_fast8_t softfloat_countLeadingZeros16(uint16_t a);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -133,22 +127,21 @@ uint_fast8_t softfloat_countLeadingZeros16( uint16_t a );
|
||||
| 'a'. If 'a' is zero, 32 is returned.
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (3 <= INLINE_LEVEL)
|
||||
INLINE uint_fast8_t softfloat_countLeadingZeros32( uint32_t a )
|
||||
{
|
||||
INLINE uint_fast8_t softfloat_countLeadingZeros32(uint32_t a) {
|
||||
uint_fast8_t count = 0;
|
||||
if ( a < 0x10000 ) {
|
||||
if(a < 0x10000) {
|
||||
count = 16;
|
||||
a <<= 16;
|
||||
}
|
||||
if ( a < 0x1000000 ) {
|
||||
if(a < 0x1000000) {
|
||||
count += 8;
|
||||
a <<= 8;
|
||||
}
|
||||
count += softfloat_countLeadingZeros8[a>>24];
|
||||
count += softfloat_countLeadingZeros8[a >> 24];
|
||||
return count;
|
||||
}
|
||||
#else
|
||||
uint_fast8_t softfloat_countLeadingZeros32( uint32_t a );
|
||||
uint_fast8_t softfloat_countLeadingZeros32(uint32_t a);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -157,7 +150,7 @@ uint_fast8_t softfloat_countLeadingZeros32( uint32_t a );
|
||||
| Returns the number of leading 0 bits before the most-significant 1 bit of
|
||||
| 'a'. If 'a' is zero, 64 is returned.
|
||||
*----------------------------------------------------------------------------*/
|
||||
uint_fast8_t softfloat_countLeadingZeros64( uint64_t a );
|
||||
uint_fast8_t softfloat_countLeadingZeros64(uint64_t a);
|
||||
#endif
|
||||
|
||||
extern const uint16_t softfloat_approxRecip_1k0s[16];
|
||||
@ -176,9 +169,9 @@ extern const uint16_t softfloat_approxRecip_1k1s[16];
|
||||
| (units in the last place).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#ifdef SOFTFLOAT_FAST_DIV64TO32
|
||||
#define softfloat_approxRecip32_1( a ) ((uint32_t) (UINT64_C( 0x7FFFFFFFFFFFFFFF ) / (uint32_t) (a)))
|
||||
#define softfloat_approxRecip32_1(a) ((uint32_t)(UINT64_C(0x7FFFFFFFFFFFFFFF) / (uint32_t)(a)))
|
||||
#else
|
||||
uint32_t softfloat_approxRecip32_1( uint32_t a );
|
||||
uint32_t softfloat_approxRecip32_1(uint32_t a);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -204,7 +197,7 @@ extern const uint16_t softfloat_approxRecipSqrt_1k1s[16];
|
||||
| returned is also always within the range 0.5 to 1; thus, the most-
|
||||
| significant bit of the result is always set.
|
||||
*----------------------------------------------------------------------------*/
|
||||
uint32_t softfloat_approxRecipSqrt32_1( unsigned int oddExpA, uint32_t a );
|
||||
uint32_t softfloat_approxRecipSqrt32_1(unsigned int oddExpA, uint32_t a);
|
||||
#endif
|
||||
|
||||
#ifdef SOFTFLOAT_FAST_INT64
|
||||
@ -222,10 +215,9 @@ uint32_t softfloat_approxRecipSqrt32_1( unsigned int oddExpA, uint32_t a );
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (1 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
bool softfloat_eq128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
|
||||
{ return (a64 == b64) && (a0 == b0); }
|
||||
bool softfloat_eq128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0) { return (a64 == b64) && (a0 == b0); }
|
||||
#else
|
||||
bool softfloat_eq128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
bool softfloat_eq128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -237,10 +229,9 @@ bool softfloat_eq128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
bool softfloat_le128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
|
||||
{ return (a64 < b64) || ((a64 == b64) && (a0 <= b0)); }
|
||||
bool softfloat_le128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0) { return (a64 < b64) || ((a64 == b64) && (a0 <= b0)); }
|
||||
#else
|
||||
bool softfloat_le128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
bool softfloat_le128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -252,10 +243,9 @@ bool softfloat_le128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
bool softfloat_lt128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
|
||||
{ return (a64 < b64) || ((a64 == b64) && (a0 < b0)); }
|
||||
bool softfloat_lt128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0) { return (a64 < b64) || ((a64 == b64) && (a0 < b0)); }
|
||||
#else
|
||||
bool softfloat_lt128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
bool softfloat_lt128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -266,17 +256,14 @@ bool softfloat_lt128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint128
|
||||
softfloat_shortShiftLeft128( uint64_t a64, uint64_t a0, uint_fast8_t dist )
|
||||
{
|
||||
struct uint128 softfloat_shortShiftLeft128(uint64_t a64, uint64_t a0, uint_fast8_t dist) {
|
||||
struct uint128 z;
|
||||
z.v64 = a64<<dist | a0>>(-dist & 63);
|
||||
z.v0 = a0<<dist;
|
||||
z.v64 = a64 << dist | a0 >> (-dist & 63);
|
||||
z.v0 = a0 << dist;
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128
|
||||
softfloat_shortShiftLeft128( uint64_t a64, uint64_t a0, uint_fast8_t dist );
|
||||
struct uint128 softfloat_shortShiftLeft128(uint64_t a64, uint64_t a0, uint_fast8_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -287,17 +274,14 @@ struct uint128
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint128
|
||||
softfloat_shortShiftRight128( uint64_t a64, uint64_t a0, uint_fast8_t dist )
|
||||
{
|
||||
struct uint128 softfloat_shortShiftRight128(uint64_t a64, uint64_t a0, uint_fast8_t dist) {
|
||||
struct uint128 z;
|
||||
z.v64 = a64>>dist;
|
||||
z.v0 = a64<<(-dist & 63) | a0>>dist;
|
||||
z.v64 = a64 >> dist;
|
||||
z.v0 = a64 << (-dist & 63) | a0 >> dist;
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128
|
||||
softfloat_shortShiftRight128( uint64_t a64, uint64_t a0, uint_fast8_t dist );
|
||||
struct uint128 softfloat_shortShiftRight128(uint64_t a64, uint64_t a0, uint_fast8_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -308,19 +292,14 @@ struct uint128
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint64_extra
|
||||
softfloat_shortShiftRightJam64Extra(
|
||||
uint64_t a, uint64_t extra, uint_fast8_t dist )
|
||||
{
|
||||
struct uint64_extra softfloat_shortShiftRightJam64Extra(uint64_t a, uint64_t extra, uint_fast8_t dist) {
|
||||
struct uint64_extra z;
|
||||
z.v = a>>dist;
|
||||
z.extra = a<<(-dist & 63) | (extra != 0);
|
||||
z.v = a >> dist;
|
||||
z.extra = a << (-dist & 63) | (extra != 0);
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint64_extra
|
||||
softfloat_shortShiftRightJam64Extra(
|
||||
uint64_t a, uint64_t extra, uint_fast8_t dist );
|
||||
struct uint64_extra softfloat_shortShiftRightJam64Extra(uint64_t a, uint64_t extra, uint_fast8_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -334,22 +313,15 @@ struct uint64_extra
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (3 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint128
|
||||
softfloat_shortShiftRightJam128(
|
||||
uint64_t a64, uint64_t a0, uint_fast8_t dist )
|
||||
{
|
||||
struct uint128 softfloat_shortShiftRightJam128(uint64_t a64, uint64_t a0, uint_fast8_t dist) {
|
||||
uint_fast8_t negDist = -dist;
|
||||
struct uint128 z;
|
||||
z.v64 = a64>>dist;
|
||||
z.v0 =
|
||||
a64<<(negDist & 63) | a0>>dist
|
||||
| ((uint64_t) (a0<<(negDist & 63)) != 0);
|
||||
z.v64 = a64 >> dist;
|
||||
z.v0 = a64 << (negDist & 63) | a0 >> dist | ((uint64_t)(a0 << (negDist & 63)) != 0);
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128
|
||||
softfloat_shortShiftRightJam128(
|
||||
uint64_t a64, uint64_t a0, uint_fast8_t dist );
|
||||
struct uint128 softfloat_shortShiftRightJam128(uint64_t a64, uint64_t a0, uint_fast8_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -360,21 +332,16 @@ struct uint128
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (3 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint128_extra
|
||||
softfloat_shortShiftRightJam128Extra(
|
||||
uint64_t a64, uint64_t a0, uint64_t extra, uint_fast8_t dist )
|
||||
{
|
||||
struct uint128_extra softfloat_shortShiftRightJam128Extra(uint64_t a64, uint64_t a0, uint64_t extra, uint_fast8_t dist) {
|
||||
uint_fast8_t negDist = -dist;
|
||||
struct uint128_extra z;
|
||||
z.v.v64 = a64>>dist;
|
||||
z.v.v0 = a64<<(negDist & 63) | a0>>dist;
|
||||
z.extra = a0<<(negDist & 63) | (extra != 0);
|
||||
z.v.v64 = a64 >> dist;
|
||||
z.v.v0 = a64 << (negDist & 63) | a0 >> dist;
|
||||
z.extra = a0 << (negDist & 63) | (extra != 0);
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128_extra
|
||||
softfloat_shortShiftRightJam128Extra(
|
||||
uint64_t a64, uint64_t a0, uint64_t extra, uint_fast8_t dist );
|
||||
struct uint128_extra softfloat_shortShiftRightJam128Extra(uint64_t a64, uint64_t a0, uint64_t extra, uint_fast8_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -397,14 +364,11 @@ struct uint128_extra
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (4 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint64_extra
|
||||
softfloat_shiftRightJam64Extra(
|
||||
uint64_t a, uint64_t extra, uint_fast32_t dist )
|
||||
{
|
||||
struct uint64_extra softfloat_shiftRightJam64Extra(uint64_t a, uint64_t extra, uint_fast32_t dist) {
|
||||
struct uint64_extra z;
|
||||
if ( dist < 64 ) {
|
||||
z.v = a>>dist;
|
||||
z.extra = a<<(-dist & 63);
|
||||
if(dist < 64) {
|
||||
z.v = a >> dist;
|
||||
z.extra = a << (-dist & 63);
|
||||
} else {
|
||||
z.v = 0;
|
||||
z.extra = (dist == 64) ? a : (a != 0);
|
||||
@ -413,9 +377,7 @@ struct uint64_extra
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint64_extra
|
||||
softfloat_shiftRightJam64Extra(
|
||||
uint64_t a, uint64_t extra, uint_fast32_t dist );
|
||||
struct uint64_extra softfloat_shiftRightJam64Extra(uint64_t a, uint64_t extra, uint_fast32_t dist);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -430,8 +392,7 @@ struct uint64_extra
|
||||
| greater than 128, the result will be either 0 or 1, depending on whether the
|
||||
| original 128 bits are all zeros.
|
||||
*----------------------------------------------------------------------------*/
|
||||
struct uint128
|
||||
softfloat_shiftRightJam128( uint64_t a64, uint64_t a0, uint_fast32_t dist );
|
||||
struct uint128 softfloat_shiftRightJam128(uint64_t a64, uint64_t a0, uint_fast32_t dist);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRightJam128Extra
|
||||
@ -452,9 +413,7 @@ struct uint128
|
||||
| is modified as described above and returned in the 'extra' field of the
|
||||
| result.)
|
||||
*----------------------------------------------------------------------------*/
|
||||
struct uint128_extra
|
||||
softfloat_shiftRightJam128Extra(
|
||||
uint64_t a64, uint64_t a0, uint64_t extra, uint_fast32_t dist );
|
||||
struct uint128_extra softfloat_shiftRightJam128Extra(uint64_t a64, uint64_t a0, uint64_t extra, uint_fast32_t dist);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRightJam256M
|
||||
@ -470,9 +429,7 @@ struct uint128_extra
|
||||
| is greater than 256, the stored result will be either 0 or 1, depending on
|
||||
| whether the original 256 bits are all zeros.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_shiftRightJam256M(
|
||||
const uint64_t *aPtr, uint_fast32_t dist, uint64_t *zPtr );
|
||||
void softfloat_shiftRightJam256M(const uint64_t* aPtr, uint_fast32_t dist, uint64_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_add128
|
||||
@ -483,17 +440,14 @@ void
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint128
|
||||
softfloat_add128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
|
||||
{
|
||||
struct uint128 softfloat_add128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0) {
|
||||
struct uint128 z;
|
||||
z.v0 = a0 + b0;
|
||||
z.v64 = a64 + b64 + (z.v0 < a0);
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128
|
||||
softfloat_add128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
struct uint128 softfloat_add128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -505,9 +459,7 @@ struct uint128
|
||||
| an array of four 64-bit elements that concatenate in the platform's normal
|
||||
| endian order to form a 256-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_add256M(
|
||||
const uint64_t *aPtr, const uint64_t *bPtr, uint64_t *zPtr );
|
||||
void softfloat_add256M(const uint64_t* aPtr, const uint64_t* bPtr, uint64_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_sub128
|
||||
@ -518,9 +470,7 @@ void
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint128
|
||||
softfloat_sub128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 )
|
||||
{
|
||||
struct uint128 softfloat_sub128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0) {
|
||||
struct uint128 z;
|
||||
z.v0 = a0 - b0;
|
||||
z.v64 = a64 - b64;
|
||||
@ -528,8 +478,7 @@ struct uint128
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128
|
||||
softfloat_sub128( uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0 );
|
||||
struct uint128 softfloat_sub128(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -542,9 +491,7 @@ struct uint128
|
||||
| 64-bit elements that concatenate in the platform's normal endian order to
|
||||
| form a 256-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_sub256M(
|
||||
const uint64_t *aPtr, const uint64_t *bPtr, uint64_t *zPtr );
|
||||
void softfloat_sub256M(const uint64_t* aPtr, const uint64_t* bPtr, uint64_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_mul64ByShifted32To128
|
||||
@ -552,17 +499,16 @@ void
|
||||
| Returns the 128-bit product of 'a', 'b', and 2^32.
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (3 <= INLINE_LEVEL)
|
||||
INLINE struct uint128 softfloat_mul64ByShifted32To128( uint64_t a, uint32_t b )
|
||||
{
|
||||
INLINE struct uint128 softfloat_mul64ByShifted32To128(uint64_t a, uint32_t b) {
|
||||
uint_fast64_t mid;
|
||||
struct uint128 z;
|
||||
mid = (uint_fast64_t) (uint32_t) a * b;
|
||||
z.v0 = mid<<32;
|
||||
z.v64 = (uint_fast64_t) (uint32_t) (a>>32) * b + (mid>>32);
|
||||
mid = (uint_fast64_t)(uint32_t)a * b;
|
||||
z.v0 = mid << 32;
|
||||
z.v64 = (uint_fast64_t)(uint32_t)(a >> 32) * b + (mid >> 32);
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128 softfloat_mul64ByShifted32To128( uint64_t a, uint32_t b );
|
||||
struct uint128 softfloat_mul64ByShifted32To128(uint64_t a, uint32_t b);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -570,7 +516,7 @@ struct uint128 softfloat_mul64ByShifted32To128( uint64_t a, uint32_t b );
|
||||
/*----------------------------------------------------------------------------
|
||||
| Returns the 128-bit product of 'a' and 'b'.
|
||||
*----------------------------------------------------------------------------*/
|
||||
struct uint128 softfloat_mul64To128( uint64_t a, uint64_t b );
|
||||
struct uint128 softfloat_mul64To128(uint64_t a, uint64_t b);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_mul128By32
|
||||
@ -581,19 +527,18 @@ struct uint128 softfloat_mul64To128( uint64_t a, uint64_t b );
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (4 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
struct uint128 softfloat_mul128By32( uint64_t a64, uint64_t a0, uint32_t b )
|
||||
{
|
||||
struct uint128 softfloat_mul128By32(uint64_t a64, uint64_t a0, uint32_t b) {
|
||||
struct uint128 z;
|
||||
uint_fast64_t mid;
|
||||
uint_fast32_t carry;
|
||||
z.v0 = a0 * b;
|
||||
mid = (uint_fast64_t) (uint32_t) (a0>>32) * b;
|
||||
carry = (uint32_t) ((uint_fast32_t) (z.v0>>32) - (uint_fast32_t) mid);
|
||||
z.v64 = a64 * b + (uint_fast32_t) ((mid + carry)>>32);
|
||||
mid = (uint_fast64_t)(uint32_t)(a0 >> 32) * b;
|
||||
carry = (uint32_t)((uint_fast32_t)(z.v0 >> 32) - (uint_fast32_t)mid);
|
||||
z.v64 = a64 * b + (uint_fast32_t)((mid + carry) >> 32);
|
||||
return z;
|
||||
}
|
||||
#else
|
||||
struct uint128 softfloat_mul128By32( uint64_t a64, uint64_t a0, uint32_t b );
|
||||
struct uint128 softfloat_mul128By32(uint64_t a64, uint64_t a0, uint32_t b);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -605,9 +550,7 @@ struct uint128 softfloat_mul128By32( uint64_t a64, uint64_t a0, uint32_t b );
|
||||
| Argument 'zPtr' points to an array of four 64-bit elements that concatenate
|
||||
| in the platform's normal endian order to form a 256-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_mul128To256M(
|
||||
uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0, uint64_t *zPtr );
|
||||
void softfloat_mul128To256M(uint64_t a64, uint64_t a0, uint64_t b64, uint64_t b0, uint64_t* zPtr);
|
||||
#endif
|
||||
|
||||
#else
|
||||
@ -626,7 +569,7 @@ void
|
||||
| Each of 'aPtr' and 'bPtr' points to an array of three 32-bit elements that
|
||||
| concatenate in the platform's normal endian order to form a 96-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
int_fast8_t softfloat_compare96M( const uint32_t *aPtr, const uint32_t *bPtr );
|
||||
int_fast8_t softfloat_compare96M(const uint32_t* aPtr, const uint32_t* bPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_compare128M
|
||||
@ -638,8 +581,7 @@ int_fast8_t softfloat_compare96M( const uint32_t *aPtr, const uint32_t *bPtr );
|
||||
| Each of 'aPtr' and 'bPtr' points to an array of four 32-bit elements that
|
||||
| concatenate in the platform's normal endian order to form a 128-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
int_fast8_t
|
||||
softfloat_compare128M( const uint32_t *aPtr, const uint32_t *bPtr );
|
||||
int_fast8_t softfloat_compare128M(const uint32_t* aPtr, const uint32_t* bPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftLeft64To96M
|
||||
@ -652,19 +594,14 @@ int_fast8_t
|
||||
*----------------------------------------------------------------------------*/
|
||||
#if defined INLINE_LEVEL && (2 <= INLINE_LEVEL)
|
||||
INLINE
|
||||
void
|
||||
softfloat_shortShiftLeft64To96M(
|
||||
uint64_t a, uint_fast8_t dist, uint32_t *zPtr )
|
||||
{
|
||||
zPtr[indexWord( 3, 0 )] = (uint32_t) a<<dist;
|
||||
void softfloat_shortShiftLeft64To96M(uint64_t a, uint_fast8_t dist, uint32_t* zPtr) {
|
||||
zPtr[indexWord(3, 0)] = (uint32_t)a << dist;
|
||||
a >>= 32 - dist;
|
||||
zPtr[indexWord( 3, 2 )] = a>>32;
|
||||
zPtr[indexWord( 3, 1 )] = a;
|
||||
zPtr[indexWord(3, 2)] = a >> 32;
|
||||
zPtr[indexWord(3, 1)] = a;
|
||||
}
|
||||
#else
|
||||
void
|
||||
softfloat_shortShiftLeft64To96M(
|
||||
uint64_t a, uint_fast8_t dist, uint32_t *zPtr );
|
||||
void softfloat_shortShiftLeft64To96M(uint64_t a, uint_fast8_t dist, uint32_t* zPtr);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -678,13 +615,7 @@ void
|
||||
| that concatenate in the platform's normal endian order to form an N-bit
|
||||
| integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_shortShiftLeftM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
uint_fast8_t dist,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_shortShiftLeftM(uint_fast8_t size_words, const uint32_t* aPtr, uint_fast8_t dist, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftLeft96M
|
||||
@ -692,7 +623,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shortShiftLeftM' with
|
||||
| 'size_words' = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shortShiftLeft96M( aPtr, dist, zPtr ) softfloat_shortShiftLeftM( 3, aPtr, dist, zPtr )
|
||||
#define softfloat_shortShiftLeft96M(aPtr, dist, zPtr) softfloat_shortShiftLeftM(3, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftLeft128M
|
||||
@ -700,7 +631,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shortShiftLeftM' with
|
||||
| 'size_words' = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shortShiftLeft128M( aPtr, dist, zPtr ) softfloat_shortShiftLeftM( 4, aPtr, dist, zPtr )
|
||||
#define softfloat_shortShiftLeft128M(aPtr, dist, zPtr) softfloat_shortShiftLeftM(4, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftLeft160M
|
||||
@ -708,7 +639,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shortShiftLeftM' with
|
||||
| 'size_words' = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shortShiftLeft160M( aPtr, dist, zPtr ) softfloat_shortShiftLeftM( 5, aPtr, dist, zPtr )
|
||||
#define softfloat_shortShiftLeft160M(aPtr, dist, zPtr) softfloat_shortShiftLeftM(5, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftLeftM
|
||||
@ -722,13 +653,7 @@ void
|
||||
| The value of 'dist' can be arbitrarily large. In particular, if 'dist' is
|
||||
| greater than N, the stored result will be 0.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_shiftLeftM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
uint32_t dist,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_shiftLeftM(uint_fast8_t size_words, const uint32_t* aPtr, uint32_t dist, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftLeft96M
|
||||
@ -736,7 +661,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shiftLeftM' with
|
||||
| 'size_words' = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shiftLeft96M( aPtr, dist, zPtr ) softfloat_shiftLeftM( 3, aPtr, dist, zPtr )
|
||||
#define softfloat_shiftLeft96M(aPtr, dist, zPtr) softfloat_shiftLeftM(3, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftLeft128M
|
||||
@ -744,7 +669,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shiftLeftM' with
|
||||
| 'size_words' = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shiftLeft128M( aPtr, dist, zPtr ) softfloat_shiftLeftM( 4, aPtr, dist, zPtr )
|
||||
#define softfloat_shiftLeft128M(aPtr, dist, zPtr) softfloat_shiftLeftM(4, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftLeft160M
|
||||
@ -752,7 +677,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shiftLeftM' with
|
||||
| 'size_words' = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shiftLeft160M( aPtr, dist, zPtr ) softfloat_shiftLeftM( 5, aPtr, dist, zPtr )
|
||||
#define softfloat_shiftLeft160M(aPtr, dist, zPtr) softfloat_shiftLeftM(5, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftRightM
|
||||
@ -765,13 +690,7 @@ void
|
||||
| that concatenate in the platform's normal endian order to form an N-bit
|
||||
| integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_shortShiftRightM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
uint_fast8_t dist,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_shortShiftRightM(uint_fast8_t size_words, const uint32_t* aPtr, uint_fast8_t dist, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftRight128M
|
||||
@ -779,7 +698,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shortShiftRightM' with
|
||||
| 'size_words' = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shortShiftRight128M( aPtr, dist, zPtr ) softfloat_shortShiftRightM( 4, aPtr, dist, zPtr )
|
||||
#define softfloat_shortShiftRight128M(aPtr, dist, zPtr) softfloat_shortShiftRightM(4, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftRight160M
|
||||
@ -787,7 +706,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shortShiftRightM' with
|
||||
| 'size_words' = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shortShiftRight160M( aPtr, dist, zPtr ) softfloat_shortShiftRightM( 5, aPtr, dist, zPtr )
|
||||
#define softfloat_shortShiftRight160M(aPtr, dist, zPtr) softfloat_shortShiftRightM(5, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftRightJamM
|
||||
@ -801,9 +720,7 @@ void
|
||||
| to a 'size_words'-long array of 32-bit elements that concatenate in the
|
||||
| platform's normal endian order to form an N-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_shortShiftRightJamM(
|
||||
uint_fast8_t, const uint32_t *, uint_fast8_t, uint32_t * );
|
||||
void softfloat_shortShiftRightJamM(uint_fast8_t, const uint32_t*, uint_fast8_t, uint32_t*);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shortShiftRightJam160M
|
||||
@ -811,7 +728,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shortShiftRightJamM' with
|
||||
| 'size_words' = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shortShiftRightJam160M( aPtr, dist, zPtr ) softfloat_shortShiftRightJamM( 5, aPtr, dist, zPtr )
|
||||
#define softfloat_shortShiftRightJam160M(aPtr, dist, zPtr) softfloat_shortShiftRightJamM(5, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRightM
|
||||
@ -825,13 +742,7 @@ void
|
||||
| The value of 'dist' can be arbitrarily large. In particular, if 'dist' is
|
||||
| greater than N, the stored result will be 0.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_shiftRightM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
uint32_t dist,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_shiftRightM(uint_fast8_t size_words, const uint32_t* aPtr, uint32_t dist, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRight96M
|
||||
@ -839,7 +750,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shiftRightM' with
|
||||
| 'size_words' = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shiftRight96M( aPtr, dist, zPtr ) softfloat_shiftRightM( 3, aPtr, dist, zPtr )
|
||||
#define softfloat_shiftRight96M(aPtr, dist, zPtr) softfloat_shiftRightM(3, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRightJamM
|
||||
@ -856,13 +767,7 @@ void
|
||||
| is greater than N, the stored result will be either 0 or 1, depending on
|
||||
| whether the original N bits are all zeros.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_shiftRightJamM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
uint32_t dist,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_shiftRightJamM(uint_fast8_t size_words, const uint32_t* aPtr, uint32_t dist, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRightJam96M
|
||||
@ -870,7 +775,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shiftRightJamM' with
|
||||
| 'size_words' = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shiftRightJam96M( aPtr, dist, zPtr ) softfloat_shiftRightJamM( 3, aPtr, dist, zPtr )
|
||||
#define softfloat_shiftRightJam96M(aPtr, dist, zPtr) softfloat_shiftRightJamM(3, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRightJam128M
|
||||
@ -878,7 +783,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shiftRightJamM' with
|
||||
| 'size_words' = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shiftRightJam128M( aPtr, dist, zPtr ) softfloat_shiftRightJamM( 4, aPtr, dist, zPtr )
|
||||
#define softfloat_shiftRightJam128M(aPtr, dist, zPtr) softfloat_shiftRightJamM(4, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_shiftRightJam160M
|
||||
@ -886,7 +791,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_shiftRightJamM' with
|
||||
| 'size_words' = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_shiftRightJam160M( aPtr, dist, zPtr ) softfloat_shiftRightJamM( 5, aPtr, dist, zPtr )
|
||||
#define softfloat_shiftRightJam160M(aPtr, dist, zPtr) softfloat_shiftRightJamM(5, aPtr, dist, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_addM
|
||||
@ -898,13 +803,7 @@ void
|
||||
| elements that concatenate in the platform's normal endian order to form an
|
||||
| N-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_addM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
const uint32_t *bPtr,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_addM(uint_fast8_t size_words, const uint32_t* aPtr, const uint32_t* bPtr, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_add96M
|
||||
@ -912,7 +811,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_addM' with 'size_words'
|
||||
| = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_add96M( aPtr, bPtr, zPtr ) softfloat_addM( 3, aPtr, bPtr, zPtr )
|
||||
#define softfloat_add96M(aPtr, bPtr, zPtr) softfloat_addM(3, aPtr, bPtr, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_add128M
|
||||
@ -920,7 +819,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_addM' with 'size_words'
|
||||
| = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_add128M( aPtr, bPtr, zPtr ) softfloat_addM( 4, aPtr, bPtr, zPtr )
|
||||
#define softfloat_add128M(aPtr, bPtr, zPtr) softfloat_addM(4, aPtr, bPtr, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_add160M
|
||||
@ -928,7 +827,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_addM' with 'size_words'
|
||||
| = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_add160M( aPtr, bPtr, zPtr ) softfloat_addM( 5, aPtr, bPtr, zPtr )
|
||||
#define softfloat_add160M(aPtr, bPtr, zPtr) softfloat_addM(5, aPtr, bPtr, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_addCarryM
|
||||
@ -940,14 +839,7 @@ void
|
||||
| points to a 'size_words'-long array of 32-bit elements that concatenate in
|
||||
| the platform's normal endian order to form an N-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
uint_fast8_t
|
||||
softfloat_addCarryM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
const uint32_t *bPtr,
|
||||
uint_fast8_t carry,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
uint_fast8_t softfloat_addCarryM(uint_fast8_t size_words, const uint32_t* aPtr, const uint32_t* bPtr, uint_fast8_t carry, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_addComplCarryM
|
||||
@ -956,14 +848,8 @@ uint_fast8_t
|
||||
| the value of the unsigned integer pointed to by 'bPtr' is bit-wise completed
|
||||
| before the addition.
|
||||
*----------------------------------------------------------------------------*/
|
||||
uint_fast8_t
|
||||
softfloat_addComplCarryM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
const uint32_t *bPtr,
|
||||
uint_fast8_t carry,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
uint_fast8_t softfloat_addComplCarryM(uint_fast8_t size_words, const uint32_t* aPtr, const uint32_t* bPtr, uint_fast8_t carry,
|
||||
uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_addComplCarry96M
|
||||
@ -971,7 +857,7 @@ uint_fast8_t
|
||||
| This function or macro is the same as 'softfloat_addComplCarryM' with
|
||||
| 'size_words' = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_addComplCarry96M( aPtr, bPtr, carry, zPtr ) softfloat_addComplCarryM( 3, aPtr, bPtr, carry, zPtr )
|
||||
#define softfloat_addComplCarry96M(aPtr, bPtr, carry, zPtr) softfloat_addComplCarryM(3, aPtr, bPtr, carry, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_negXM
|
||||
@ -981,7 +867,7 @@ uint_fast8_t
|
||||
| points to a 'size_words'-long array of 32-bit elements that concatenate in
|
||||
| the platform's normal endian order to form an N-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void softfloat_negXM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
void softfloat_negXM(uint_fast8_t size_words, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_negX96M
|
||||
@ -989,7 +875,7 @@ void softfloat_negXM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| This function or macro is the same as 'softfloat_negXM' with 'size_words'
|
||||
| = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_negX96M( zPtr ) softfloat_negXM( 3, zPtr )
|
||||
#define softfloat_negX96M(zPtr) softfloat_negXM(3, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_negX128M
|
||||
@ -997,7 +883,7 @@ void softfloat_negXM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| This function or macro is the same as 'softfloat_negXM' with 'size_words'
|
||||
| = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_negX128M( zPtr ) softfloat_negXM( 4, zPtr )
|
||||
#define softfloat_negX128M(zPtr) softfloat_negXM(4, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_negX160M
|
||||
@ -1005,7 +891,7 @@ void softfloat_negXM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| This function or macro is the same as 'softfloat_negXM' with 'size_words'
|
||||
| = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_negX160M( zPtr ) softfloat_negXM( 5, zPtr )
|
||||
#define softfloat_negX160M(zPtr) softfloat_negXM(5, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_negX256M
|
||||
@ -1013,7 +899,7 @@ void softfloat_negXM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| This function or macro is the same as 'softfloat_negXM' with 'size_words'
|
||||
| = 8 (N = 256).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_negX256M( zPtr ) softfloat_negXM( 8, zPtr )
|
||||
#define softfloat_negX256M(zPtr) softfloat_negXM(8, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_sub1XM
|
||||
@ -1024,7 +910,7 @@ void softfloat_negXM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| elements that concatenate in the platform's normal endian order to form an
|
||||
| N-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void softfloat_sub1XM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
void softfloat_sub1XM(uint_fast8_t size_words, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_sub1X96M
|
||||
@ -1032,7 +918,7 @@ void softfloat_sub1XM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| This function or macro is the same as 'softfloat_sub1XM' with 'size_words'
|
||||
| = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_sub1X96M( zPtr ) softfloat_sub1XM( 3, zPtr )
|
||||
#define softfloat_sub1X96M(zPtr) softfloat_sub1XM(3, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_sub1X160M
|
||||
@ -1040,7 +926,7 @@ void softfloat_sub1XM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| This function or macro is the same as 'softfloat_sub1XM' with 'size_words'
|
||||
| = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_sub1X160M( zPtr ) softfloat_sub1XM( 5, zPtr )
|
||||
#define softfloat_sub1X160M(zPtr) softfloat_sub1XM(5, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_subM
|
||||
@ -1052,13 +938,7 @@ void softfloat_sub1XM( uint_fast8_t size_words, uint32_t *zPtr );
|
||||
| array of 32-bit elements that concatenate in the platform's normal endian
|
||||
| order to form an N-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_subM(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *aPtr,
|
||||
const uint32_t *bPtr,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_subM(uint_fast8_t size_words, const uint32_t* aPtr, const uint32_t* bPtr, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_sub96M
|
||||
@ -1066,7 +946,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_subM' with 'size_words'
|
||||
| = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_sub96M( aPtr, bPtr, zPtr ) softfloat_subM( 3, aPtr, bPtr, zPtr )
|
||||
#define softfloat_sub96M(aPtr, bPtr, zPtr) softfloat_subM(3, aPtr, bPtr, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_sub128M
|
||||
@ -1074,7 +954,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_subM' with 'size_words'
|
||||
| = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_sub128M( aPtr, bPtr, zPtr ) softfloat_subM( 4, aPtr, bPtr, zPtr )
|
||||
#define softfloat_sub128M(aPtr, bPtr, zPtr) softfloat_subM(4, aPtr, bPtr, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_sub160M
|
||||
@ -1082,7 +962,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_subM' with 'size_words'
|
||||
| = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_sub160M( aPtr, bPtr, zPtr ) softfloat_subM( 5, aPtr, bPtr, zPtr )
|
||||
#define softfloat_sub160M(aPtr, bPtr, zPtr) softfloat_subM(5, aPtr, bPtr, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_mul64To128M
|
||||
@ -1092,7 +972,7 @@ void
|
||||
| elements that concatenate in the platform's normal endian order to form a
|
||||
| 128-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void softfloat_mul64To128M( uint64_t a, uint64_t b, uint32_t *zPtr );
|
||||
void softfloat_mul64To128M(uint64_t a, uint64_t b, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_mul128MTo256M
|
||||
@ -1104,9 +984,7 @@ void softfloat_mul64To128M( uint64_t a, uint64_t b, uint32_t *zPtr );
|
||||
| Argument 'zPtr' points to an array of eight 32-bit elements that concatenate
|
||||
| to form a 256-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_mul128MTo256M(
|
||||
const uint32_t *aPtr, const uint32_t *bPtr, uint32_t *zPtr );
|
||||
void softfloat_mul128MTo256M(const uint32_t* aPtr, const uint32_t* bPtr, uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_remStepMBy32
|
||||
@ -1119,15 +997,8 @@ void
|
||||
| to a 'size_words'-long array of 32-bit elements that concatenate in the
|
||||
| platform's normal endian order to form an N-bit integer.
|
||||
*----------------------------------------------------------------------------*/
|
||||
void
|
||||
softfloat_remStepMBy32(
|
||||
uint_fast8_t size_words,
|
||||
const uint32_t *remPtr,
|
||||
uint_fast8_t dist,
|
||||
const uint32_t *bPtr,
|
||||
uint32_t q,
|
||||
uint32_t *zPtr
|
||||
);
|
||||
void softfloat_remStepMBy32(uint_fast8_t size_words, const uint32_t* remPtr, uint_fast8_t dist, const uint32_t* bPtr, uint32_t q,
|
||||
uint32_t* zPtr);
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_remStep96MBy32
|
||||
@ -1135,7 +1006,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_remStepMBy32' with
|
||||
| 'size_words' = 3 (N = 96).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_remStep96MBy32( remPtr, dist, bPtr, q, zPtr ) softfloat_remStepMBy32( 3, remPtr, dist, bPtr, q, zPtr )
|
||||
#define softfloat_remStep96MBy32(remPtr, dist, bPtr, q, zPtr) softfloat_remStepMBy32(3, remPtr, dist, bPtr, q, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_remStep128MBy32
|
||||
@ -1143,7 +1014,7 @@ void
|
||||
| This function or macro is the same as 'softfloat_remStepMBy32' with
|
||||
| 'size_words' = 4 (N = 128).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_remStep128MBy32( remPtr, dist, bPtr, q, zPtr ) softfloat_remStepMBy32( 4, remPtr, dist, bPtr, q, zPtr )
|
||||
#define softfloat_remStep128MBy32(remPtr, dist, bPtr, q, zPtr) softfloat_remStepMBy32(4, remPtr, dist, bPtr, q, zPtr)
|
||||
#endif
|
||||
|
||||
#ifndef softfloat_remStep160MBy32
|
||||
@ -1151,10 +1022,9 @@ void
|
||||
| This function or macro is the same as 'softfloat_remStepMBy32' with
|
||||
| 'size_words' = 5 (N = 160).
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define softfloat_remStep160MBy32( remPtr, dist, bPtr, q, zPtr ) softfloat_remStepMBy32( 5, remPtr, dist, bPtr, q, zPtr )
|
||||
#define softfloat_remStep160MBy32(remPtr, dist, bPtr, q, zPtr) softfloat_remStepMBy32(5, remPtr, dist, bPtr, q, zPtr)
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user