45{
46 union ui128_f128 uA;
48 bool sign;
52 struct uint128 uiZ;
55 struct exp32_sig128 normExpSig;
56 struct uint128 sig128;
58
59
60
62 uiA64 = uA.ui.v64;
63 uiA0 = uA.ui.v0;
64 sign = signF128UI64( uiA64 );
65 exp = expF128UI64( uiA64 );
66 frac64 = fracF128UI64( uiA64 );
67 frac0 = uiA0;
68
69
70 if ( exp == 0x7FFF ) {
71 if ( frac64 | frac0 ) {
74 uiZ64 = uiZ.v64;
75 uiZ0 = uiZ.v0;
76 } else {
78 uiZ0 =
UINT64_C( 0x8000000000000000 );
79 }
80 goto uiZ;
81 }
82
83
84 if ( ! exp ) {
85 if ( ! (frac64 | frac0) ) {
87 uiZ0 = 0;
88 goto uiZ;
89 }
91 exp = normExpSig.exp;
92 frac64 = normExpSig.sig.v64;
93 frac0 = normExpSig.sig.v0;
94 }
95
96
97 sig128 =
99 frac64 |
UINT64_C( 0x0001000000000000 ), frac0, 15 );
101
102
103 uiZ:
104 uZ.s.signExp = uiZ64;
105 uZ.s.signif = uiZ0;
106 return uZ.f;
107
108}
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
void softfloat_f128UIToCommonNaN(uint_fast64_t uiA64, uint_fast64_t uiA0, struct commonNaN *zPtr)
#define softfloat_commonNaNToExtF80UI
#define packToExtF80UI64(sign, exp)
struct exp32_sig128 softfloat_normSubnormalF128Sig(uint_fast64_t sig64, uint_fast64_t sig0)
extFloat80_t softfloat_roundPackToExtF80(bool sign, int_fast32_t exp, uint_fast64_t sig, uint_fast64_t sigExtra, uint_fast8_t roundingPrecision)
struct uint128 softfloat_shortShiftLeft128(uint64_t a64, uint64_t a0, uint_fast8_t dist)