--- /dev/null
+\r
+#include <stdbool.h>\r
+#include <stdint.h>\r
+#include "platform.h"\r
+#include "primitives.h"\r
+#include "internals.h"\r
+\r
+float64_t\r
+ softfloat_normRoundPackToF64( bool sign, int_fast16_t exp, uint_fast64_t sig )\r
+{\r
+ int shiftCount;\r
+ union ui64_f64 uZ;\r
+\r
+ shiftCount = softfloat_countLeadingZeros64( sig ) - 1;\r
+ exp -= shiftCount;\r
+ if ( ( 10 <= shiftCount ) && ( (uint16_t) exp < 0x7FD ) ) {\r
+ uZ.ui = packToF64UI( sign, sig ? exp : 0, sig<<( shiftCount - 10 ) );\r
+ return uZ.f;\r
+ } else {\r
+ return softfloat_roundPackToF64( sign, exp, sig<<shiftCount );\r
+ }\r
+\r
+}\r
+\r