This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gas warning fixes 8


gas/ChangeLog
	* config/tc-m32r.c (md_parse_option <arg>): Add ATTRIBUTE_UNUSED.
	(fill_insn <ignore>): Likewise.
	(debug_sym <ignore>): Likewise.
	(md_undefined_symbol <name>): Likewise.
	(m32r_scomm <ignore>): Likewise.
	(md_convert_frag <abfd>): Likewise.
	(md_cgen_lookup_reloc <insn>): Likewise.
	(m32r_record_hi16 <seg>): Likewise.
	(md_estimate_size_before_relax): #if 0 old_fr_fix.
	(allow_m32rx): Prototype.
	(first_writes_to_seconds_operands): Prototype.
	(writes_to_pc): Prototype.
	(can_make_parallel): Prototype.
	(make_parallel): Prototype.
	(target_make_parallel): Prototype.
	(assemble_two_insns): Prototype.
	(m32r_record_hi16): Prototype.
	(md_atof): Remove declaration of atof_ieee.
	* config/tc-m32r.h (m32r_fix_adjustable): Declare.
	(m32r_force_relocation): Prototype.
	(m32r_elf_section_change_hook): Prototype.

Index: gas/config/tc-m32r.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-m32r.c,v
retrieving revision 1.26
diff -u -p -r1.26 tc-m32r.c
--- gas/config/tc-m32r.c	30 Nov 2002 08:39:43 -0000	1.26
+++ gas/config/tc-m32r.c	12 Dec 2002 12:44:44 -0000
@@ -146,6 +146,8 @@ struct m32r_hi_fixup
 
 static struct m32r_hi_fixup *m32r_hi_fixup_list;
 
+static void allow_m32rx PARAMS ((int));
+
 static void
 allow_m32rx (on)
      int on;
@@ -198,7 +200,7 @@ size_t md_longopts_size = sizeof (md_lon
 int
 md_parse_option (c, arg)
      int c;
-     char *arg;
+     char *arg ATTRIBUTE_UNUSED;
 {
   switch (c)
     {
@@ -379,7 +381,7 @@ m32r_handle_align (fragp)
 
 static void
 fill_insn (ignore)
-     int ignore;
+     int ignore ATTRIBUTE_UNUSED;
 {
   frag_align_code (2, 0);
   prev_insn.insn = NULL;
@@ -394,7 +396,7 @@ fill_insn (ignore)
 
 static void
 debug_sym (ignore)
-     int ignore;
+     int ignore ATTRIBUTE_UNUSED;
 {
   register char *name;
   register char delim;
@@ -568,6 +570,9 @@ md_begin ()
    of instruction 'b'.  If 'check_outputs' is true then b's outputs are
    checked, otherwise its inputs are examined.  */
 
+static int first_writes_to_seconds_operands
+  PARAMS ((m32r_insn *, m32r_insn *, const int));
+
 static int
 first_writes_to_seconds_operands (a, b, check_outputs)
      m32r_insn *a;
@@ -642,6 +647,8 @@ first_writes_to_seconds_operands (a, b, 
 
 /* Returns true if the insn can (potentially) alter the program counter.  */
 
+static int writes_to_pc PARAMS ((m32r_insn *));
+
 static int
 writes_to_pc (a)
      m32r_insn *a;
@@ -674,6 +681,8 @@ writes_to_pc (a)
 /* Return NULL if the two 16 bit insns can be executed in parallel.
    Otherwise return a pointer to an error message explaining why not.  */
 
+static const char *can_make_parallel PARAMS ((m32r_insn *, m32r_insn *));
+
 static const char *
 can_make_parallel (a, b)
      m32r_insn *a;
@@ -710,6 +719,8 @@ can_make_parallel (a, b)
 
 /* Force the top bit of the second 16-bit insn to be set.  */
 
+static void make_parallel PARAMS ((CGEN_INSN_BYTES_PTR));
+
 static void
 make_parallel (buffer)
      CGEN_INSN_BYTES_PTR buffer;
@@ -724,6 +735,8 @@ make_parallel (buffer)
 
 /* Same as make_parallel except buffer contains the bytes in target order.  */
 
+static void target_make_parallel PARAMS ((char *));
+
 static void
 target_make_parallel (buffer)
      char *buffer;
@@ -735,6 +748,8 @@ target_make_parallel (buffer)
 /* Assemble two instructions with an explicit parallel operation (||) or
    sequential operation (->).  */
 
+static void assemble_two_insns PARAMS ((char *, char *, int));
+
 static void
 assemble_two_insns (str, str2, parallel_p)
      char *str;
@@ -1216,7 +1231,7 @@ md_section_align (segment, size)
 
 symbolS *
 md_undefined_symbol (name)
-     char *name;
+     char *name ATTRIBUTE_UNUSED;
 {
   return 0;
 }
@@ -1230,7 +1245,7 @@ md_undefined_symbol (name)
 
 static void
 m32r_scomm (ignore)
-     int ignore;
+     int ignore ATTRIBUTE_UNUSED;
 {
   register char *name;
   register char c;
@@ -1450,7 +1465,9 @@ md_estimate_size_before_relax (fragP, se
 
   if (S_GET_SEGMENT (fragP->fr_symbol) != segment)
     {
+#if 0
       int old_fr_fix = fragP->fr_fix;
+#endif
 
       /* The symbol is undefined in this segment.
 	 Change the relaxation subtype to the max allowable and leave
@@ -1514,7 +1531,7 @@ md_estimate_size_before_relax (fragP, se
 
 void
 md_convert_frag (abfd, sec, fragP)
-     bfd *abfd;
+     bfd *abfd ATTRIBUTE_UNUSED;
      segT sec;
      fragS *fragP;
 {
@@ -1626,7 +1643,7 @@ md_pcrel_from_section (fixP, sec)
 
 bfd_reloc_code_real_type
 md_cgen_lookup_reloc (insn, operand, fixP)
-     const CGEN_INSN *insn;
+     const CGEN_INSN *insn ATTRIBUTE_UNUSED;
      const CGEN_OPERAND *operand;
      fixS *fixP;
 {
@@ -1652,11 +1669,13 @@ md_cgen_lookup_reloc (insn, operand, fix
 
 /* Record a HI16 reloc for later matching with its LO16 cousin.  */
 
+static void m32r_record_hi16 PARAMS ((int, fixS *, segT));
+
 static void
 m32r_record_hi16 (reloc_type, fixP, seg)
      int reloc_type;
      fixS *fixP;
-     segT seg;
+     segT seg ATTRIBUTE_UNUSED;
 {
   struct m32r_hi_fixup *hi_fixup;
 
@@ -1842,7 +1861,6 @@ md_atof (type, litP, sizeP)
   int prec;
   LITTLENUM_TYPE words[MAX_LITTLENUMS];
   char *t;
-  char *atof_ieee ();
 
   switch (type)
     {
Index: gas/config/tc-m32r.h
===================================================================
RCS file: /cvs/src/src/gas/config/tc-m32r.h,v
retrieving revision 1.7
diff -u -p -r1.7 tc-m32r.h
--- gas/config/tc-m32r.h	5 Sep 2002 00:01:18 -0000	1.7
+++ gas/config/tc-m32r.h	12 Dec 2002 12:44:44 -0000
@@ -74,6 +74,7 @@ extern void m32r_handle_align PARAMS ((f
 #define md_apply_fix3 gas_cgen_md_apply_fix3
 
 #define tc_fix_adjustable(FIX) m32r_fix_adjustable (FIX)
+bfd_boolean m32r_fix_adjustable PARAMS ((struct fix *));
 
 /* After creating a fixup for an instruction operand, we need to check for
    HI16 relocs and queue them up for later sorting.  */
@@ -90,7 +91,7 @@ extern void m32r_frob_file PARAMS ((void
 
 /* When relaxing, we need to emit various relocs we otherwise wouldn't.  */
 #define TC_FORCE_RELOCATION(fix) m32r_force_relocation (fix)
-extern int m32r_force_relocation ();
+extern int m32r_force_relocation PARAMS ((struct fix *));
 
 /* Ensure insns at labels are aligned to 32 bit boundaries.  */
 int m32r_fill_insn PARAMS ((int));
@@ -104,4 +105,4 @@ int m32r_fill_insn PARAMS ((int));
 
 #define md_cleanup                 m32r_elf_section_change_hook
 #define md_elf_section_change_hook m32r_elf_section_change_hook
-extern void m32r_elf_section_change_hook ();
+extern void m32r_elf_section_change_hook PARAMS ((void));

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]