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]

Some prototypes for opcodes/*



Here're some more prototypes fixes.  Ok to commit?

Andreas

2001-08-21  Andreas Jaeger  <aj@suse.de>

	* i960-dis.c: Add parameters for prototypes
	(ctrl): Add unused attributes.
	(cobr): Likewise.
	(put_abs): Likewise.

	* mips-dis.c: Add missing prototypes.
	* a29k-dis.c: Likewise.
	* arc-dis.c: Likewise.
	* ia64-opc.c: Likewise.

	* s390-dis.c: Add missing prototypes.
	(init_disasm): Remove unused attribute since the parameter is
	used.

============================================================
Index: opcodes/mips-dis.c
--- opcodes/mips-dis.c	2001/08/13 08:09:58	1.19
+++ opcodes/mips-dis.c	2001/08/21 07:39:41
@@ -45,8 +45,12 @@
   PARAMS ((bfd_vma, unsigned long int, struct disassemble_info *));
 static void print_insn_arg
   PARAMS ((const char *, unsigned long, bfd_vma, struct disassemble_info *));
+static void mips_isa_type
+  PARAMS ((int, int *, int *));
 static int print_insn_mips16
   PARAMS ((bfd_vma, struct disassemble_info *));
+static int is_newabi
+  PARAMS ((Elf_Internal_Ehdr *));
 static void print_mips16_insn_arg
   PARAMS ((int, const struct mips_opcode *, int, boolean, int, bfd_vma,
 	   struct disassemble_info *));
============================================================
Index: opcodes/a29k-dis.c
--- opcodes/a29k-dis.c	2001/03/13 22:58:34	1.3
+++ opcodes/a29k-dis.c	2001/08/21 07:39:42
@@ -1,5 +1,5 @@
 /* Instruction printing code for the AMD 29000
-   Copyright 1990, 1993, 1994, 1995, 1998, 2000
+   Copyright 1990, 1993, 1994, 1995, 1998, 2000, 2001
    Free Software Foundation, Inc.
    Contributed by Cygnus Support.  Written by Jim Kingdon.
 
@@ -23,6 +23,18 @@
 #include "dis-asm.h"
 #include "opcode/a29k.h"
 
+static void print_general PARAMS ((int, struct disassemble_info *));
+static void print_special PARAMS ((unsigned int, struct disassemble_info *));
+static int is_delayed_branch PARAMS ((int));
+static void find_bytes_little
+  PARAMS ((char *, unsigned char *, unsigned char *, unsigned char *,
+	   unsigned char *));
+static void find_bytes_big
+  PARAMS ((char *, unsigned char *, unsigned char *, unsigned char *,
+	   unsigned char *));
+static int print_insn PARAMS ((bfd_vma, struct disassemble_info *));
+
+
 /* Print a symbolic representation of a general-purpose
    register number NUM on STREAM.
    NUM is a number as found in the instruction, not as found in
@@ -39,7 +51,7 @@
 }
 
 /* Like print_general but a special-purpose register.
-   
+
    The mnemonics used by the AMD assembler are not quite the same
    as the ones in the User's Manual.  We use the ones that the
    assembler uses.  */
@@ -171,7 +183,7 @@
       if (((unsigned long) insn24 << 24) == opcode->opcode)
 	{
 	  char *s;
-	  
+
 	  (*info->fprintf_func) (info->stream, "%s ", opcode->name);
 	  for (s = opcode->args; *s != '\0'; ++s)
 	    {
@@ -180,7 +192,7 @@
 		case 'a':
 		  print_general (insn8, info);
 		  break;
-		  
+
 		case 'b':
 		  print_general (insn0, info);
 		  break;
@@ -281,7 +293,7 @@
 	      int errcode;
 	      char prev_insn[4];
 	      unsigned char prev_insn0, prev_insn8, prev_insn16, prev_insn24;
-	      
+
 	      errcode = (*info->read_memory_func) (memaddr - 4,
 						   (bfd_byte *) &prev_insn[0],
 						   4,
@@ -291,7 +303,7 @@
 		  /* If it is a delayed branch, we need to look at the
 		     instruction before the delayed brach to handle
 		     things like
-		     
+
 		     const _foo
 		     call _printf
 		     consth _foo
@@ -306,7 +318,7 @@
 					 &prev_insn16, &prev_insn24);
 		    }
 		}
-		  
+
 	      /* If there was a problem reading memory, then assume
 		 the previous instruction was not const.  */
 	      if (errcode == 0)
============================================================
Index: opcodes/s390-dis.c
--- opcodes/s390-dis.c	2001/07/23 13:41:14	1.3
+++ opcodes/s390-dis.c	2001/08/21 07:39:42
@@ -29,11 +29,15 @@
 static int opc_index[256];
 static int current_arch_mask = 0;
 
+static void init_disasm PARAMS ((struct disassemble_info *));
+static unsigned int s390_extract_operand
+  PARAMS ((unsigned char *, const struct s390_operand *));
+
 /* Set up index table for first opcode byte.  */
 
 static void
 init_disasm (info)
-     struct disassemble_info *info ATTRIBUTE_UNUSED;
+     struct disassemble_info *info;
 {
   const struct s390_opcode *opcode;
   const struct s390_opcode *opcode_end;
============================================================
Index: opcodes/i960-dis.c
--- opcodes/i960-dis.c	2001/03/13 22:58:35	1.3
+++ opcodes/i960-dis.c	2001/08/21 07:39:42
@@ -1,5 +1,5 @@
 /* Disassemble i80960 instructions.
-   Copyright 1990, 1991, 1993, 1994, 1995, 1996, 1998, 1999, 2000
+   Copyright 1990, 1991, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
    Free Software Foundation, Inc.
 
 This program is free software; you can redistribute it and/or modify
@@ -31,17 +31,17 @@
 
 static FILE *stream;		/* Output goes here */
 static struct disassemble_info *info;
-static void print_addr();
-static void ctrl();
-static void cobr();
-static void reg();
-static int mem();
-static void ea();
-static void dstop();
-static void regop();
-static void invalid();
-static int pinsn();
-static void put_abs();
+static void print_addr PARAMS ((bfd_vma));
+static void ctrl PARAMS ((bfd_vma, unsigned long, unsigned long));
+static void cobr PARAMS ((bfd_vma, unsigned long, unsigned long));
+static void reg PARAMS ((unsigned long));
+static int mem PARAMS ((bfd_vma, unsigned long, unsigned long, int));
+static void ea PARAMS ((bfd_vma, int, char *, char *, int, unsigned int));
+static void dstop PARAMS ((int, int, int));
+static void regop PARAMS ((int, int, int, int));
+static void invalid PARAMS ((int));
+static int pinsn PARAMS ((bfd_vma, unsigned long, unsigned long));
+static void put_abs PARAMS ((unsigned long, unsigned long));
 
 
 /* Print the i960 instruction at address 'memaddr' in debugged memory,
@@ -163,7 +163,8 @@
 static void
 ctrl( memaddr, word1, word2 )
     bfd_vma memaddr;
-    unsigned long word1, word2;
+    unsigned long word1;
+    unsigned long word2 ATTRIBUTE_UNUSED;
 {
 	int i;
 	static const struct tabent ctrl_tab[] = {
@@ -229,7 +230,8 @@
 static void
 cobr( memaddr, word1, word2 )
     bfd_vma memaddr;
-    unsigned long word1, word2;
+    unsigned long word1;
+    unsigned long word2 ATTRIBUTE_UNUSED;
 {
 	int src1;
 	int src2;
@@ -884,7 +886,8 @@
 
 static void
 put_abs( word1, word2 )
-    unsigned long word1, word2;
+    unsigned long word1 ATTRIBUTE_UNUSED;
+    unsigned long word2 ATTRIBUTE_UNUSED;
 {
 #ifdef IN_GDB
 	return;

-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj


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