#include <stdbool.h>
#include <stdint.h>
#include "platform.h"
#include "internals.h"
#include "specialize.h"
#include "softfloat.h"
Go to the source code of this file.
◆ f128M_to_f16()
Definition at line 55 of file f128M_to_f16.c.
56{
59 bool sign;
65
66
67
69
70
74 frac32 =
78 != 0);
79
80
81 if ( exp == 0x7FFF ) {
82 if ( frac32 ) {
85 } else {
87 }
88 goto uiZ;
89 }
90
91
92 frac16 = frac32>>2 | (frac32 & 3);
93 if ( ! (exp | frac16) ) {
95 goto uiZ;
96 }
97
98
99 exp -= 0x3FF1;
101 if ( exp < -0x40 ) exp = -0x40;
102 }
104
105
106 uiZ:
107 uZ.ui = uiZ;
108 return uZ.f;
109
110}
#define softfloat_commonNaNToF16UI(aPtr)
#define softfloat_f128MToCommonNaN(aWPtr, zPtr)
#define fracF128UI96(a96)
float16_t softfloat_roundPackToF16(bool, int_fast16_t, uint_fast16_t)
#define signF128UI96(a96)
#define packToF16UI(sign, exp, sig)
#define indexWord(total, n)
#define indexWordHi(total)