-extern void earith PARAMS ((REAL_VALUE_TYPE *, int,
- REAL_VALUE_TYPE *, REAL_VALUE_TYPE *));
-extern REAL_VALUE_TYPE etrunci PARAMS ((REAL_VALUE_TYPE));
-extern REAL_VALUE_TYPE etruncui PARAMS ((REAL_VALUE_TYPE));
-extern REAL_VALUE_TYPE ereal_negate PARAMS ((REAL_VALUE_TYPE));
-extern HOST_WIDE_INT efixi PARAMS ((REAL_VALUE_TYPE));
-extern unsigned HOST_WIDE_INT efixui PARAMS ((REAL_VALUE_TYPE));
-extern void ereal_from_int PARAMS ((REAL_VALUE_TYPE *,
- HOST_WIDE_INT, HOST_WIDE_INT,
- enum machine_mode));
-extern void ereal_from_uint PARAMS ((REAL_VALUE_TYPE *,
- unsigned HOST_WIDE_INT,
- unsigned HOST_WIDE_INT,
- enum machine_mode));
-extern void ereal_to_int PARAMS ((HOST_WIDE_INT *, HOST_WIDE_INT *,
- REAL_VALUE_TYPE));
-extern REAL_VALUE_TYPE ereal_ldexp PARAMS ((REAL_VALUE_TYPE, int));
-
-extern void etartdouble PARAMS ((REAL_VALUE_TYPE, long *));
-extern void etarldouble PARAMS ((REAL_VALUE_TYPE, long *));
-extern void etardouble PARAMS ((REAL_VALUE_TYPE, long *));
-extern long etarsingle PARAMS ((REAL_VALUE_TYPE));
-extern void ereal_to_decimal PARAMS ((REAL_VALUE_TYPE, char *));
-extern int ereal_cmp PARAMS ((REAL_VALUE_TYPE, REAL_VALUE_TYPE));
-extern int ereal_isneg PARAMS ((REAL_VALUE_TYPE));
-extern REAL_VALUE_TYPE ereal_unto_float PARAMS ((long));
-extern REAL_VALUE_TYPE ereal_unto_double PARAMS ((long *));
-extern REAL_VALUE_TYPE ereal_from_float PARAMS ((HOST_WIDE_INT));
-extern REAL_VALUE_TYPE ereal_from_double PARAMS ((HOST_WIDE_INT *));
-
-#define REAL_VALUES_EQUAL(x, y) (ereal_cmp ((x), (y)) == 0)
-/* true if x < y : */
-#define REAL_VALUES_LESS(x, y) (ereal_cmp ((x), (y)) == -1)
-#define REAL_VALUE_LDEXP(x, n) ereal_ldexp (x, n)
-
-/* Compare two floating-point objects for bitwise identity.
- This is not the same as comparing for equality on IEEE hosts:
- -0.0 equals 0.0 but they are not identical, and conversely
- two NaNs might be identical but they cannot be equal. */
-#define REAL_VALUES_IDENTICAL(x, y) \
- (!memcmp ((char *) &(x), (char *) &(y), sizeof (REAL_VALUE_TYPE)))
-
-/* These return REAL_VALUE_TYPE: */
-#define REAL_VALUE_RNDZINT(x) (etrunci (x))
-#define REAL_VALUE_UNSIGNED_RNDZINT(x) (etruncui (x))
-
-/* Truncate the floating-point value X to mode MODE. */
-#define REAL_VALUE_TRUNCATE(mode, x) real_value_truncate (mode, x)
-extern REAL_VALUE_TYPE real_value_truncate PARAMS ((enum machine_mode,
- REAL_VALUE_TYPE));
-
-/* Expansion of REAL_VALUE_TRUNCATE.
- The result is in floating point, rounded to nearest or even. */
-extern bool exact_real_truncate PARAMS ((enum machine_mode,
- REAL_VALUE_TYPE *));
-
-/* These return HOST_WIDE_INT: */
-/* Convert a floating-point value to integer, rounding toward zero. */
-#define REAL_VALUE_FIX(x) (efixi (x))
-/* Convert a floating-point value to unsigned integer, rounding
- toward zero. */
-#define REAL_VALUE_UNSIGNED_FIX(x) (efixui (x))
-
-/* Convert ASCII string S to floating point in mode M.
- Decimal input uses ATOF. Hexadecimal uses HTOF. */
-#define REAL_VALUE_ATOF(s,m) ereal_atof(s,m)
-#define REAL_VALUE_HTOF(s,m) ereal_atof(s,m)
-
-#define REAL_VALUE_NEGATE ereal_negate
-
-/* Compute the absolute value of a floating-point value X. */
-#define REAL_VALUE_ABS(x) \
- (REAL_VALUE_NEGATIVE (x) ? REAL_VALUE_NEGATE (x) : (x))
+
+/* Binary or unary arithmetic on tree_code. */
+extern bool real_arithmetic (REAL_VALUE_TYPE *, int, const REAL_VALUE_TYPE *,
+ const REAL_VALUE_TYPE *);
+
+/* Compare reals by tree_code. */
+extern bool real_compare (int, const REAL_VALUE_TYPE *, const REAL_VALUE_TYPE *);
+
+/* Determine whether a floating-point value X is infinite. */
+extern bool real_isinf (const REAL_VALUE_TYPE *);
+
+/* Determine whether a floating-point value X is a NaN. */
+extern bool real_isnan (const REAL_VALUE_TYPE *);
+
+/* Determine whether a floating-point value X is finite. */
+extern bool real_isfinite (const REAL_VALUE_TYPE *);
+
+/* Determine whether a floating-point value X is negative. */
+extern bool real_isneg (const REAL_VALUE_TYPE *);
+
+/* Determine whether a floating-point value X is minus zero. */
+extern bool real_isnegzero (const REAL_VALUE_TYPE *);
+
+/* Compare two floating-point objects for bitwise identity. */
+extern bool real_identical (const REAL_VALUE_TYPE *, const REAL_VALUE_TYPE *);
+
+/* Extend or truncate to a new mode. */
+extern void real_convert (REAL_VALUE_TYPE *, enum machine_mode,
+ const REAL_VALUE_TYPE *);
+
+/* Return true if truncating to NEW is exact. */
+extern bool exact_real_truncate (enum machine_mode, const REAL_VALUE_TYPE *);
+
+/* Render R as a decimal floating point constant. */
+extern void real_to_decimal (char *, const REAL_VALUE_TYPE *, size_t,
+ size_t, int);
+
+/* Render R as a decimal floating point constant, rounded so as to be
+ parsed back to the same value when interpreted in mode MODE. */
+extern void real_to_decimal_for_mode (char *, const REAL_VALUE_TYPE *, size_t,
+ size_t, int, enum machine_mode);
+
+/* Render R as a hexadecimal floating point constant. */
+extern void real_to_hexadecimal (char *, const REAL_VALUE_TYPE *,
+ size_t, size_t, int);
+
+/* Render R as an integer. */
+extern HOST_WIDE_INT real_to_integer (const REAL_VALUE_TYPE *);
+extern void real_to_integer2 (HOST_WIDE_INT *, HOST_WIDE_INT *,
+ const REAL_VALUE_TYPE *);
+
+/* Initialize R from a decimal or hexadecimal string. Return -1 if
+ the value underflows, +1 if overflows, and 0 otherwise. */
+extern int real_from_string (REAL_VALUE_TYPE *, const char *);
+/* Wrapper to allow different internal representation for decimal floats. */
+extern void real_from_string3 (REAL_VALUE_TYPE *, const char *, enum machine_mode);
+
+/* Initialize R from an integer pair HIGH/LOW. */
+extern void real_from_integer (REAL_VALUE_TYPE *, enum machine_mode,
+ unsigned HOST_WIDE_INT, HOST_WIDE_INT, int);
+
+extern long real_to_target_fmt (long *, const REAL_VALUE_TYPE *,
+ const struct real_format *);
+extern long real_to_target (long *, const REAL_VALUE_TYPE *, enum machine_mode);
+
+extern void real_from_target_fmt (REAL_VALUE_TYPE *, const long *,
+ const struct real_format *);
+extern void real_from_target (REAL_VALUE_TYPE *, const long *,
+ enum machine_mode);
+
+extern void real_inf (REAL_VALUE_TYPE *);
+
+extern bool real_nan (REAL_VALUE_TYPE *, const char *, int, enum machine_mode);
+
+extern void real_maxval (REAL_VALUE_TYPE *, int, enum machine_mode);
+
+extern void real_2expN (REAL_VALUE_TYPE *, int, enum machine_mode);
+
+extern unsigned int real_hash (const REAL_VALUE_TYPE *);
+
+
+/* Target formats defined in real.c. */
+extern const struct real_format ieee_single_format;
+extern const struct real_format mips_single_format;
+extern const struct real_format motorola_single_format;
+extern const struct real_format spu_single_format;
+extern const struct real_format ieee_double_format;
+extern const struct real_format mips_double_format;
+extern const struct real_format motorola_double_format;
+extern const struct real_format ieee_extended_motorola_format;
+extern const struct real_format ieee_extended_intel_96_format;
+extern const struct real_format ieee_extended_intel_96_round_53_format;
+extern const struct real_format ieee_extended_intel_128_format;
+extern const struct real_format ibm_extended_format;
+extern const struct real_format mips_extended_format;
+extern const struct real_format ieee_quad_format;
+extern const struct real_format mips_quad_format;
+extern const struct real_format vax_f_format;
+extern const struct real_format vax_d_format;
+extern const struct real_format vax_g_format;
+extern const struct real_format real_internal_format;
+extern const struct real_format decimal_single_format;
+extern const struct real_format decimal_double_format;
+extern const struct real_format decimal_quad_format;
+
+
+/* ====================================================================== */
+/* Crap. */
+
+#define REAL_ARITHMETIC(value, code, d1, d2) \
+ real_arithmetic (&(value), code, &(d1), &(d2))
+
+#define REAL_VALUES_IDENTICAL(x, y) real_identical (&(x), &(y))
+#define REAL_VALUES_EQUAL(x, y) real_compare (EQ_EXPR, &(x), &(y))
+#define REAL_VALUES_LESS(x, y) real_compare (LT_EXPR, &(x), &(y))