sfp-machine.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. /* Use 32-bit types here to prevent longlong.h trying to use TImode.
  2. Once TImode works we might be better to use 64-bit here. */
  3. #define _FP_W_TYPE_SIZE 32
  4. #define _FP_W_TYPE unsigned int
  5. #define _FP_WS_TYPE signed int
  6. #define _FP_I_TYPE int
  7. #define _FP_MUL_MEAT_S(R,X,Y) \
  8. _FP_MUL_MEAT_1_wide(_FP_WFRACBITS_S,R,X,Y,umul_ppmm)
  9. #define _FP_MUL_MEAT_D(R,X,Y) \
  10. _FP_MUL_MEAT_2_wide(_FP_WFRACBITS_D,R,X,Y,umul_ppmm)
  11. #define _FP_DIV_MEAT_S(R,X,Y) _FP_DIV_MEAT_1_loop(S,R,X,Y)
  12. #define _FP_DIV_MEAT_D(R,X,Y) _FP_DIV_MEAT_2_udiv(D,R,X,Y)
  13. #define _FP_NANFRAC_S ((_FP_QNANBIT_S << 1) - 1)
  14. #define _FP_NANFRAC_D ((_FP_QNANBIT_D << 1) - 1), -1
  15. #define _FP_NANSIGN_S 0
  16. #define _FP_NANSIGN_D 0
  17. #define _FP_KEEPNANFRACP 1
  18. #define _FP_QNANNEGATEDP 0
  19. /* Someone please check this. */
  20. #define _FP_CHOOSENAN(fs, wc, R, X, Y, OP) \
  21. do { \
  22. if ((_FP_FRAC_HIGH_RAW_##fs(X) & _FP_QNANBIT_##fs) \
  23. && !(_FP_FRAC_HIGH_RAW_##fs(Y) & _FP_QNANBIT_##fs)) \
  24. { \
  25. R##_s = Y##_s; \
  26. _FP_FRAC_COPY_##wc(R,Y); \
  27. } \
  28. else \
  29. { \
  30. R##_s = X##_s; \
  31. _FP_FRAC_COPY_##wc(R,X); \
  32. } \
  33. R##_c = FP_CLS_NAN; \
  34. } while (0)
  35. #define _FP_TININESS_AFTER_ROUNDING 0
  36. #define __LITTLE_ENDIAN 1234
  37. #define __BIG_ENDIAN 4321
  38. #define __BYTE_ORDER __LITTLE_ENDIAN
  39. /* Define ALIASNAME as a strong alias for NAME. */
  40. # define strong_alias(name, aliasname) _strong_alias(name, aliasname)
  41. # define _strong_alias(name, aliasname) \
  42. extern __typeof (name) aliasname __attribute__ ((alias (#name)));