MCPcopy Create free account
hub / github.com/BlitterStudio/amiberry / floatx80_to_floatx80

Function floatx80_to_floatx80

src/softfloat/softfloat.cpp:2022–2040  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2020 *----------------------------------------------------------------------------*/
2021
2022floatx80 floatx80_to_floatx80( floatx80 a, float_status *status )
2023{
2024 flag aSign;
2025 int32_t aExp;
2026 uint64_t aSig;
2027
2028 aSig = extractFloatx80Frac( a );
2029 aExp = extractFloatx80Exp( a );
2030 aSign = extractFloatx80Sign( a );
2031
2032 if ( aExp == 0x7FFF && (uint64_t) ( aSig<<1 ) ) {
2033 return propagateFloatx80NaNOneArg( a, status );
2034 }
2035 if ( aExp == 0 && aSig != 0 ) {
2036 return normalizeRoundAndPackFloatx80( status->floatx80_rounding_precision, aSign, aExp, aSig, 0, status );
2037 }
2038 return a;
2039
2040}
2041#endif
2042
2043#ifdef SOFTFLOAT_68K // 30-01-2016: Added for Previous

Callers 1

from_extenFunction · 0.85

Calls 5

extractFloatx80FracFunction · 0.85
extractFloatx80ExpFunction · 0.85
extractFloatx80SignFunction · 0.85

Tested by

no test coverage detected