gas reloc rewrite.
[binutils-gdb.git] / gas / config / atof-ieee.c
index ce6afbbd340dcee089d6664091b4300e19bf52dc..0ad39c9b30111208c5bbc36d991d3994577446c0 100644 (file)
    Software Foundation, 59 Temple Place - Suite 330, Boston, MA
    02111-1307, USA.  */
 
-/* Some float formats are based on the IEEE standard, but use the
-   largest exponent for normal numbers instead of NaNs and infinites.
-   The macro TC_LARGEST_EXPONENT_IS_NORMAL should evaluate to true
-   if the target machine uses such a format.  The macro can depend on
-   command line flags if necessary.  There is no need to define the
-   macro if it would always be 0.  */
-
 #include "as.h"
 
 /* Flonums returned here.  */
@@ -48,7 +41,7 @@ extern const char EXP_CHARS[];
 #define GUARD (2)
 
 #ifndef TC_LARGEST_EXPONENT_IS_NORMAL
-#define TC_LARGEST_EXPONENT_IS_NORMAL 0
+#define TC_LARGEST_EXPONENT_IS_NORMAL(PRECISION) 0
 #endif
 
 static const unsigned long mask[] =
@@ -302,7 +295,7 @@ gen_to_words (words, precision, exponent_bits)
   /* NaN:  Do the right thing.  */
   if (generic_floating_point_number.sign == 0)
     {
-      if (TC_LARGEST_EXPONENT_IS_NORMAL)
+      if (TC_LARGEST_EXPONENT_IS_NORMAL (precision))
        as_warn ("NaNs are not supported by this target\n");
       if (precision == F_PRECISION)
        {
@@ -341,7 +334,7 @@ gen_to_words (words, precision, exponent_bits)
     }
   else if (generic_floating_point_number.sign == 'P')
     {
-      if (TC_LARGEST_EXPONENT_IS_NORMAL)
+      if (TC_LARGEST_EXPONENT_IS_NORMAL (precision))
        as_warn ("Infinities are not supported by this target\n");
 
       /* +INF:  Do the right thing.  */
@@ -382,7 +375,7 @@ gen_to_words (words, precision, exponent_bits)
     }
   else if (generic_floating_point_number.sign == 'N')
     {
-      if (TC_LARGEST_EXPONENT_IS_NORMAL)
+      if (TC_LARGEST_EXPONENT_IS_NORMAL (precision))
        as_warn ("Infinities are not supported by this target\n");
 
       /* Negative INF.  */
@@ -598,7 +591,7 @@ gen_to_words (words, precision, exponent_bits)
       return return_value;
     }
   else if ((unsigned long) exponent_4 > mask[exponent_bits]
-          || (! TC_LARGEST_EXPONENT_IS_NORMAL
+          || (! TC_LARGEST_EXPONENT_IS_NORMAL (precision)
               && (unsigned long) exponent_4 == mask[exponent_bits]))
     {
       /* Exponent overflow.  Lose immediately.  */