1999-09-11 Donn Terry <donn@interix.com>
authorIan Lance Taylor <ian@airs.com>
Sun, 12 Sep 1999 02:27:58 +0000 (02:27 +0000)
committerIan Lance Taylor <ian@airs.com>
Sun, 12 Sep 1999 02:27:58 +0000 (02:27 +0000)
* expr.c (expr): Change first parameter to int.
* config/obj-coff.c: Add declarations for static functions.
(coff_frob_symbol): Use SYM_AUXENT.
* config/tc-i386.h (flag_16bit_code): Don't declare.

gas/ChangeLog
gas/config/obj-coff.c
gas/config/tc-i386.h
gas/expr.c

index 5903fd0..a042380 100644 (file)
        int.
        (md_atof): Return NULL rather than 0.
        * config/tc-i386.c (md_atof): Change type to int.
+       * expr.c (expr): Change first parameter to int.
+       * config/obj-coff.c: Add declarations for static functions.
+       (coff_frob_symbol): Use SYM_AUXENT.
+       * config/tc-i386.h (flag_16bit_code): Don't declare.
 
        * config/obj-coff.c (obj_coff_section): Default to setting
        SEC_LOAD.  Don't set SEC_DATA for 'w' modifier.
index a2a3bbd..f52732d 100644 (file)
 
 static void obj_coff_bss PARAMS ((int));
 const char *s_get_name PARAMS ((symbolS * s));
+static void obj_coff_ln PARAMS ((int));
+static void obj_coff_def PARAMS ((int));
+static void obj_coff_endef PARAMS ((int));
+static void obj_coff_dim PARAMS ((int));
+static void obj_coff_line PARAMS ((int));
+static void obj_coff_size PARAMS ((int));
+static void obj_coff_scl PARAMS ((int));
+static void obj_coff_tag PARAMS ((int));
+static void obj_coff_val PARAMS ((int));
+static void obj_coff_type PARAMS ((int));
+
+/* This is used to hold the symbol built by a sequence of pseudo-ops
+   from .def and .endef.  */
 static symbolS *def_symbol_in_progress;
-
 \f
 /* stack stuff */
 typedef struct
@@ -334,6 +346,8 @@ c_dot_file_symbol (filename)
 {
   symbolS *symbolP;
 
+  /* BFD converts filename to a .file symbol with an aux entry.  It
+     also handles chaining.  */
   symbolP = symbol_new (filename, bfd_abs_section_ptr, 0, &zero_address_frag);
 
   S_SET_STORAGE_CLASS (symbolP, C_FILE);
@@ -928,8 +942,15 @@ obj_coff_val (ignore)
             resolved, then copy the segment id from the forward
             symbol.  */
          SF_SET_GET_SEGMENT (def_symbol_in_progress);
+
+         /* FIXME: gcc can generate address expressions here in
+            unusual cases (search for "obscure" in sdbout.c).  We
+            just ignore the offset here, thus generating incorrect
+            debugging information.  We ignore the rest of the line
+            just below.  */
        }
-      /* Otherwise, it is the name of a non debug symbol and its value will be calculated later. */
+      /* Otherwise, it is the name of a non debug symbol and its value
+         will be calculated later. */
       *input_line_pointer = name_end;
     }
   else
@@ -1037,8 +1058,7 @@ coff_frob_symbol (symp, punt)
              coff_last_function = symp;
              if (S_GET_NUMBER_AUXILIARY (symp) < 1)
                S_SET_NUMBER_AUXILIARY (symp, 1);
-             auxp =
-               &coffsymbol (symbol_get_bfdsym (symp))->native[1].u.auxent;
+             auxp = SYM_AUXENT (symp);
              memset (auxp->x_sym.x_fcnary.x_ary.x_dimen, 0,
                      sizeof (auxp->x_sym.x_fcnary.x_ary.x_dimen));
            }
@@ -2609,12 +2629,11 @@ obj_coff_val (ignore)
             symbol.  */
          SF_SET_GET_SEGMENT (def_symbol_in_progress);
 
-         /* FIXME: gcc can generate address expressions
-            here in unusual cases (search for "obscure"
-            in sdbout.c).  We just ignore the offset
-            here, thus generating incorrect debugging
-            information.  We ignore the rest of the
-            line just below.  */
+         /* FIXME: gcc can generate address expressions here in
+            unusual cases (search for "obscure" in sdbout.c).  We
+            just ignore the offset here, thus generating incorrect
+            debugging information.  We ignore the rest of the line
+            just below.  */
        }
       /* Otherwise, it is the name of a non debug symbol and
         its value will be calculated later. */
@@ -4430,6 +4449,9 @@ const pseudo_typeS obj_pseudo_table[] =
 \f
 #ifdef BFD_ASSEMBLER
 
+static void coff_pop_insert PARAMS ((void));
+static int coff_sec_sym_ok_for_reloc PARAMS ((asection *));
+
 /* Support for a COFF emulation.  */
 
 static void
index b263b28..641ace9 100644 (file)
@@ -445,9 +445,6 @@ void i386_validate_fix PARAMS ((struct fix *));
 extern const struct relax_type md_relax_table[];
 #define TC_GENERIC_RELAX_TABLE md_relax_table
 
-
-extern int flag_16bit_code;
-
 #define md_do_align(n, fill, len, max, around)                         \
 if ((n) && !need_pass_2                                                        \
     && (!(fill) || ((char)*(fill) == (char)0x90 && (len) == 1))                \
index fcc633f..acf2804 100644 (file)
@@ -1616,10 +1616,11 @@ operator ()
 /* Parse an expression.  */
 
 segT
-expr (rank, resultP)
-     operator_rankT rank;      /* Larger # is higher rank. */
+expr (rankarg, resultP)
+     int rankarg;      /* Larger # is higher rank. */
      expressionS *resultP;     /* Deliver result here. */
 {
+  operator_rankT rank = (operator_rankT) rankarg;
   segT retval;
   expressionS right;
   operatorT op_left;