123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- #include "soft-fp.h"
- #include "single.h"
- #include "quad.h"
- void _Qp_stoq(long double *c, const float a)
- {
- FP_DECL_EX;
- FP_DECL_S(A);
- FP_DECL_Q(C);
- FP_INIT_ROUNDMODE;
- FP_UNPACK_RAW_S(A, a);
- #if (2 * _FP_W_TYPE_SIZE) < _FP_FRACBITS_Q
- FP_EXTEND(Q,S,4,1,C,A);
- #else
- FP_EXTEND(Q,S,2,1,C,A);
- #endif
- FP_PACK_RAW_QP(c, C);
- QP_HANDLE_EXCEPTIONS(__asm (
- " fstoq %1, %%f60\n"
- " std %%f60, [%0]\n"
- " std %%f62, [%0+8]\n"
- " " : : "r" (c), "f" (a) : QP_CLOBBER));
- }
|