MCPcopy Create free account
hub / github.com/numpy/numpy / Dragon4_PrintFloat_Intel_extended80

Function Dragon4_PrintFloat_Intel_extended80

numpy/core/src/multiarray/dragon4.c:2604–2623  ·  view source on GitHub ↗

* Intel's 80-bit IEEE extended precision format, 80-bit storage * * Note: It is not clear if a long double with 10-byte storage exists on any * system. But numpy defines NPY_FLOAT80, so if we come across it, assume it is * an Intel extended format. */

Source from the content-addressed store, hash-verified

2602 * an Intel extended format.
2603 */
2604static npy_uint32
2605Dragon4_PrintFloat_Intel_extended80(
2606 Dragon4_Scratch *scratch, npy_float80 *value, Dragon4_Options *opt)
2607{
2608 FloatVal128 val128;
2609 union {
2610 npy_float80 floatingPoint;
2611 struct {
2612 npy_uint64 a;
2613 npy_uint16 b;
2614 } integer;
2615 } buf80;
2616
2617 buf80.floatingPoint = *value;
2618 /* Intel is little-endian */
2619 val128.lo = buf80.integer.a;
2620 val128.hi = buf80.integer.b;
2621
2622 return Dragon4_PrintFloat_Intel_extended(scratch, val128, opt);
2623}
2624#endif /* HAVE_LDOUBLE_INTEL_EXTENDED_10_BYTES_LE */
2625
2626#ifdef HAVE_LDOUBLE_INTEL_EXTENDED_12_BYTES_LE

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected