This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB 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]

[commit] Strip out more "register" attributes


Hello,

This gets rid of most of the not-so-easy-to-remove uses of the "register" attribute.

committed,
Andrew
2003-09-16  Andrew Cagney  <cagney@redhat.com>

	* buildsym.c: Remove more occurances of "register".
	* coffread.c, dbxread.c, dcache.c, dwarf2read.c: Ditto.
	* environ.c, eval.c, f-valprint.c, findvar.c: Ditto.
	* gdbtypes.c, gnu-v2-abi.c, h8300-tdep.c, hppa-tdep.c: Ditto.
	* infcmd.c, mdebugread.c, minsyms.c, mips-tdep.c: Ditto.
	* printcmd.c, remote-vx.c, sh-stub.c, sh-tdep.c: Ditto.
	* sh64-tdep.c, source.c, stabsread.c, stack.c: Ditto.
	* standalone.c, symfile.c, symmisc.c, symtab.c: Ditto.
	* utils.c, valops.c, values.c, xcoffread.c: Ditto.

Index: buildsym.c
===================================================================
RCS file: /cvs/src/src/gdb/buildsym.c,v
retrieving revision 1.35
diff -u -r1.35 buildsym.c
--- buildsym.c	14 Sep 2003 16:32:12 -0000	1.35
+++ buildsym.c	16 Sep 2003 18:52:33 -0000
@@ -709,7 +709,7 @@
    line vector for SUBFILE.  */
 
 void
-record_line (register struct subfile *subfile, int line, CORE_ADDR pc)
+record_line (struct subfile *subfile, int line, CORE_ADDR pc)
 {
   struct linetable_entry *e;
   /* Ignore the dummy line number in libg.o */
Index: coffread.c
===================================================================
RCS file: /cvs/src/src/gdb/coffread.c,v
retrieving revision 1.43
diff -u -r1.43 coffread.c
--- coffread.c	14 Sep 2003 16:32:12 -0000	1.43
+++ coffread.c	16 Sep 2003 18:52:33 -0000
@@ -313,7 +313,7 @@
    or for associating a new type with the index.  */
 
 static struct type **
-coff_lookup_type (register int index)
+coff_lookup_type (int index)
 {
   if (index >= type_vector_length)
     {
@@ -1119,9 +1119,9 @@
    in internal_auxent form, and skip any other auxents.  */
 
 static void
-read_one_sym (register struct coff_symbol *cs,
-	      register struct internal_syment *sym,
-	      register union internal_auxent *aux)
+read_one_sym (struct coff_symbol *cs,
+	      struct internal_syment *sym,
+	      union internal_auxent *aux)
 {
   int i;
 
@@ -1348,8 +1348,8 @@
 #endif
 
 static void
-enter_linenos (long file_offset, register int first_line,
-	       register int last_line, struct objfile *objfile)
+enter_linenos (long file_offset, int first_line,
+	       int last_line, struct objfile *objfile)
 {
   char *rawptr;
   struct internal_lineno lptr;
@@ -1431,9 +1431,9 @@
 	  TYPE_CODE (SYMBOL_TYPE (real_sym)) == TYPE_CODE_PTR &&
 	  TYPE_LENGTH (TYPE_TARGET_TYPE (SYMBOL_TYPE (real_sym))) != 0)
 	{
-	  register char *name = DEPRECATED_SYMBOL_NAME (real_sym);
-	  register int hash = hashname (name);
-	  register struct symbol *sym, *prev;
+	  char *name = DEPRECATED_SYMBOL_NAME (real_sym);
+	  int hash = hashname (name);
+	  struct symbol *sym, *prev;
 
 	  prev = 0;
 	  for (sym = opaque_type_chain[hash]; sym;)
@@ -1472,8 +1472,8 @@
 }
 
 static struct symbol *
-process_coff_symbol (register struct coff_symbol *cs,
-		     register union internal_auxent *aux,
+process_coff_symbol (struct coff_symbol *cs,
+		     union internal_auxent *aux,
 		     struct objfile *objfile)
 {
   struct symbol *sym
@@ -1659,7 +1659,7 @@
 	      TYPE_CODE (TYPE_TARGET_TYPE (SYMBOL_TYPE (sym))) !=
 	      TYPE_CODE_UNDEF)
 	    {
-	      register int i = hashname (DEPRECATED_SYMBOL_NAME (sym));
+	      int i = hashname (DEPRECATED_SYMBOL_NAME (sym));
 
 	      SYMBOL_VALUE_CHAIN (sym) = opaque_type_chain[i];
 	      opaque_type_chain[i] = sym;
@@ -1696,8 +1696,8 @@
 /* Decode a coff type specifier;  return the type that is meant.  */
 
 static struct type *
-decode_type (register struct coff_symbol *cs, unsigned int c_type,
-	     register union internal_auxent *aux)
+decode_type (struct coff_symbol *cs, unsigned int c_type,
+	     union internal_auxent *aux)
 {
   struct type *type = 0;
   unsigned int new_c_type;
@@ -1718,7 +1718,7 @@
       else if (ISARY (c_type))
 	{
 	  int i, n;
-	  register unsigned short *dim;
+	  unsigned short *dim;
 	  struct type *base_type, *index_type, *range_type;
 
 	  /* Define an array type.  */
@@ -1777,8 +1777,8 @@
    return the type that the function returns.  */
 
 static struct type *
-decode_function_type (register struct coff_symbol *cs, unsigned int c_type,
-		      register union internal_auxent *aux)
+decode_function_type (struct coff_symbol *cs, unsigned int c_type,
+		      union internal_auxent *aux)
 {
   if (aux->x_sym.x_tagndx.l == 0)
     cs->c_naux = 0;		/* auxent refers to function, not base type */
@@ -1789,8 +1789,8 @@
 /* basic C types */
 
 static struct type *
-decode_base_type (register struct coff_symbol *cs, unsigned int c_type,
-		  register union internal_auxent *aux)
+decode_base_type (struct coff_symbol *cs, unsigned int c_type,
+		  union internal_auxent *aux)
 {
   struct type *type;
 
Index: dbxread.c
===================================================================
RCS file: /cvs/src/src/gdb/dbxread.c,v
retrieving revision 1.55
diff -u -r1.55 dbxread.c
--- dbxread.c	14 Sep 2003 16:32:12 -0000	1.55
+++ dbxread.c	16 Sep 2003 18:52:34 -0000
@@ -752,8 +752,8 @@
     {
       if (HEADER_FILES (objfile) != NULL)
 	{
-	  register int i = N_HEADER_FILES (objfile);
-	  register struct header_file *hfiles = HEADER_FILES (objfile);
+	  int i = N_HEADER_FILES (objfile);
+	  struct header_file *hfiles = HEADER_FILES (objfile);
 
 	  while (--i >= 0)
 	    {
@@ -1715,7 +1715,7 @@
 	    if (pst && STREQ (namestring, pst->filename))
 	    continue;
 	    {
-	      register int i;
+	      int i;
 	      for (i = 0; i < includes_used; i++)
 		if (STREQ (namestring, psymtab_include_list[i]))
 		  {
Index: dcache.c
===================================================================
RCS file: /cvs/src/src/gdb/dcache.c,v
retrieving revision 1.17
diff -u -r1.17 dcache.c
--- dcache.c	14 Sep 2003 22:35:33 -0000	1.17
+++ dcache.c	16 Sep 2003 18:52:34 -0000
@@ -240,7 +240,7 @@
    be written is. */
 
 static int
-dcache_write_line (DCACHE *dcache, register struct dcache_block *db)
+dcache_write_line (DCACHE *dcache, struct dcache_block *db)
 {
   CORE_ADDR memaddr;
   char *myaddr;
Index: dwarf2read.c
===================================================================
RCS file: /cvs/src/src/gdb/dwarf2read.c,v
retrieving revision 1.105
diff -u -r1.105 dwarf2read.c
--- dwarf2read.c	15 Sep 2003 17:19:23 -0000	1.105
+++ dwarf2read.c	16 Sep 2003 18:52:36 -0000
@@ -5912,7 +5912,7 @@
 /* Convert a DIE tag into its string name.  */
 
 static char *
-dwarf_tag_name (register unsigned tag)
+dwarf_tag_name (unsigned tag)
 {
   switch (tag)
     {
@@ -6044,7 +6044,7 @@
 /* Convert a DWARF attribute code into its string name.  */
 
 static char *
-dwarf_attr_name (register unsigned attr)
+dwarf_attr_name (unsigned attr)
 {
   switch (attr)
     {
@@ -6235,7 +6235,7 @@
 /* Convert a DWARF value form code into its string name.  */
 
 static char *
-dwarf_form_name (register unsigned form)
+dwarf_form_name (unsigned form)
 {
   switch (form)
     {
@@ -6289,7 +6289,7 @@
 /* Convert a DWARF stack opcode into its string name.  */
 
 static char *
-dwarf_stack_op_name (register unsigned op)
+dwarf_stack_op_name (unsigned op)
 {
   switch (op)
     {
@@ -6612,7 +6612,7 @@
 /* Convert a DWARF type code into its string name.  */
 
 static char *
-dwarf_type_encoding_name (register unsigned enc)
+dwarf_type_encoding_name (unsigned enc)
 {
   switch (enc)
     {
@@ -6643,7 +6643,7 @@
 
 #if 0
 static char *
-dwarf_cfi_name (register unsigned cfi_opc)
+dwarf_cfi_name (unsigned cfi_opc)
 {
   switch (cfi_opc)
     {
Index: environ.c
===================================================================
RCS file: /cvs/src/src/gdb/environ.c,v
retrieving revision 1.7
diff -u -r1.7 environ.c
--- environ.c	14 Sep 2003 22:35:33 -0000	1.7
+++ environ.c	16 Sep 2003 18:52:36 -0000
@@ -44,7 +44,7 @@
 /* Free an environment and all the strings in it.  */
 
 void
-free_environ (register struct environ *e)
+free_environ (struct environ *e)
 {
   char **vector = e->vector;
 
@@ -59,7 +59,7 @@
    that all strings in these environments are safe to free.  */
 
 void
-init_environ (register struct environ *e)
+init_environ (struct environ *e)
 {
   extern char **environ;
   int i;
@@ -80,8 +80,8 @@
 
   while (--i >= 0)
     {
-      register int len = strlen (e->vector[i]);
-      register char *new = (char *) xmalloc (len + 1);
+      int len = strlen (e->vector[i]);
+      char *new = (char *) xmalloc (len + 1);
       memcpy (new, e->vector[i], len + 1);
       e->vector[i] = new;
     }
Index: eval.c
===================================================================
RCS file: /cvs/src/src/gdb/eval.c,v
retrieving revision 1.35
diff -u -r1.35 eval.c
--- eval.c	14 Sep 2003 16:32:12 -0000	1.35
+++ eval.c	16 Sep 2003 18:52:36 -0000
@@ -67,8 +67,8 @@
 				   LONGEST, LONGEST);
 
 static struct value *
-evaluate_subexp (struct type *expect_type, register struct expression *exp,
-		 register int *pos, enum noside noside)
+evaluate_subexp (struct type *expect_type, struct expression *exp,
+		 int *pos, enum noside noside)
 {
   return (*exp->language_defn->evaluate_exp) (expect_type, exp, pos, noside);
 }
@@ -176,7 +176,7 @@
    returning the label.  Otherwise, does nothing and returns NULL. */
 
 static char *
-get_label (register struct expression *exp, int *pos)
+get_label (struct expression *exp, int *pos)
 {
   if (exp->elts[*pos].opcode == OP_LABELED)
     {
@@ -195,8 +195,8 @@
 
 static struct value *
 evaluate_struct_tuple (struct value *struct_val,
-		       register struct expression *exp,
-		       register int *pos, enum noside noside, int nargs)
+		       struct expression *exp,
+		       int *pos, enum noside noside, int nargs)
 {
   struct type *struct_type = check_typedef (VALUE_TYPE (struct_val));
   struct type *substruct_type = struct_type;
@@ -338,7 +338,7 @@
 
 static LONGEST
 init_array_element (struct value *array, struct value *element,
-		    register struct expression *exp, register int *pos,
+		    struct expression *exp, int *pos,
 		    enum noside noside, LONGEST low_bound, LONGEST high_bound)
 {
   LONGEST index;
@@ -379,7 +379,7 @@
 
 struct value *
 evaluate_subexp_standard (struct type *expect_type,
-			  register struct expression *exp, register int *pos,
+			  struct expression *exp, int *pos,
 			  enum noside noside)
 {
   enum exp_opcode op;
@@ -2063,7 +2063,7 @@
    then only the type of the result need be correct.  */
 
 static struct value *
-evaluate_subexp_for_address (register struct expression *exp, register int *pos,
+evaluate_subexp_for_address (struct expression *exp, int *pos,
 			     enum noside noside)
 {
   enum exp_opcode op;
@@ -2143,8 +2143,8 @@
  */
 
 struct value *
-evaluate_subexp_with_coercion (register struct expression *exp,
-			       register int *pos, enum noside noside)
+evaluate_subexp_with_coercion (struct expression *exp,
+			       int *pos, enum noside noside)
 {
   enum exp_opcode op;
   int pc;
@@ -2180,7 +2180,7 @@
    Advance *POS over the subexpression.  */
 
 static struct value *
-evaluate_subexp_for_sizeof (register struct expression *exp, register int *pos)
+evaluate_subexp_for_sizeof (struct expression *exp, int *pos)
 {
   enum exp_opcode op;
   int pc;
Index: f-valprint.c
===================================================================
RCS file: /cvs/src/src/gdb/f-valprint.c,v
retrieving revision 1.17
diff -u -r1.17 f-valprint.c
--- f-valprint.c	15 Sep 2003 15:14:12 -0000	1.17
+++ f-valprint.c	16 Sep 2003 18:52:36 -0000
@@ -631,7 +631,7 @@
     }
   else
     {
-      register struct minimal_symbol *msymbol =
+      struct minimal_symbol *msymbol =
       lookup_minimal_symbol_by_pc (get_frame_pc (fi));
 
       if (msymbol != NULL)
@@ -723,7 +723,7 @@
     }
   else
     {
-      register struct minimal_symbol *msymbol =
+      struct minimal_symbol *msymbol =
       lookup_minimal_symbol_by_pc (fi->pc);
 
       if (msymbol != NULL)
Index: findvar.c
===================================================================
RCS file: /cvs/src/src/gdb/findvar.c,v
retrieving revision 1.64
diff -u -r1.64 findvar.c
--- findvar.c	14 Sep 2003 16:32:12 -0000	1.64
+++ findvar.c	16 Sep 2003 18:52:37 -0000
@@ -391,7 +391,7 @@
    If FRAME is NULL, use the deprecated_selected_frame.  */
 
 struct value *
-read_var_value (register struct symbol *var, struct frame_info *frame)
+read_var_value (struct symbol *var, struct frame_info *frame)
 {
   struct value *v;
   struct type *type = SYMBOL_TYPE (var);
@@ -730,7 +730,7 @@
    address.  */
 
 struct value *
-locate_var_value (register struct symbol *var, struct frame_info *frame)
+locate_var_value (struct symbol *var, struct frame_info *frame)
 {
   CORE_ADDR addr = 0;
   struct type *type = SYMBOL_TYPE (var);
Index: gdbtypes.c
===================================================================
RCS file: /cvs/src/src/gdb/gdbtypes.c,v
retrieving revision 1.76
diff -u -r1.76 gdbtypes.c
--- gdbtypes.c	14 Sep 2003 16:32:12 -0000	1.76
+++ gdbtypes.c	16 Sep 2003 18:52:37 -0000
@@ -1020,7 +1020,7 @@
    "union ", or "enum ".  If the type has a NULL name, return NULL.  */
 
 char *
-type_name_no_tag (register const struct type *type)
+type_name_no_tag (const struct type *type)
 {
   if (TYPE_TAG_NAME (type) != NULL)
     return TYPE_TAG_NAME (type);
Index: gnu-v2-abi.c
===================================================================
RCS file: /cvs/src/src/gdb/gnu-v2-abi.c,v
retrieving revision 1.12
diff -u -r1.12 gnu-v2-abi.c
--- gnu-v2-abi.c	8 Jun 2003 18:27:13 -0000	1.12
+++ gnu-v2-abi.c	16 Sep 2003 18:52:37 -0000
@@ -354,8 +354,8 @@
   if (BASETYPE_VIA_VIRTUAL (type, index))
     {
       /* Must hunt for the pointer to this virtual baseclass.  */
-      register int i, len = TYPE_NFIELDS (type);
-      register int n_baseclasses = TYPE_N_BASECLASSES (type);
+      int i, len = TYPE_NFIELDS (type);
+      int n_baseclasses = TYPE_N_BASECLASSES (type);
 
       /* First look for the virtual baseclass pointer
          in the fields.  */
Index: h8300-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/h8300-tdep.c,v
retrieving revision 1.79
diff -u -r1.79 h8300-tdep.c
--- h8300-tdep.c	14 Sep 2003 16:32:12 -0000	1.79
+++ h8300-tdep.c	16 Sep 2003 18:52:38 -0000
@@ -321,7 +321,7 @@
  */
 
 static CORE_ADDR
-h8300_examine_prologue (register CORE_ADDR ip, register CORE_ADDR limit,
+h8300_examine_prologue (CORE_ADDR ip, CORE_ADDR limit,
 			CORE_ADDR after_prolog_fp, CORE_ADDR *fsr,
 			struct frame_info *fi)
 {
Index: hppa-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/hppa-tdep.c,v
retrieving revision 1.95
diff -u -r1.95 hppa-tdep.c
--- hppa-tdep.c	14 Sep 2003 16:32:12 -0000	1.95
+++ hppa-tdep.c	16 Sep 2003 18:52:39 -0000
@@ -2068,7 +2068,7 @@
    gets the value from the stack rather than from the buffer where all the
    registers were saved when the function called completed. */
 struct value *
-hppa_value_returned_from_stack (register struct type *valtype, CORE_ADDR addr)
+hppa_value_returned_from_stack (struct type *valtype, CORE_ADDR addr)
 {
   struct value *val;
 
Index: infcmd.c
===================================================================
RCS file: /cvs/src/src/gdb/infcmd.c,v
retrieving revision 1.88
diff -u -r1.88 infcmd.c
--- infcmd.c	14 Sep 2003 16:32:13 -0000	1.88
+++ infcmd.c	16 Sep 2003 18:52:39 -0000
@@ -1337,7 +1337,7 @@
 {
   if (var)
     {
-      register char *val = get_in_environ (inferior_environ, var);
+      char *val = get_in_environ (inferior_environ, var);
       if (val)
 	{
 	  puts_filtered (var);
@@ -1354,7 +1354,7 @@
     }
   else
     {
-      register char **vector = environ_vector (inferior_environ);
+      char **vector = environ_vector (inferior_environ);
       while (*vector)
 	{
 	  puts_filtered (*vector++);
Index: mdebugread.c
===================================================================
RCS file: /cvs/src/src/gdb/mdebugread.c,v
retrieving revision 1.50
diff -u -r1.50 mdebugread.c
--- mdebugread.c	14 Sep 2003 16:32:13 -0000	1.50
+++ mdebugread.c	16 Sep 2003 18:52:41 -0000
@@ -508,7 +508,7 @@
   /* Initialize new frame with previous content */
   if (top_stack)
     {
-      register struct parse_stack *prev = new->prev;
+      struct parse_stack *prev = new->prev;
 
       *new = *top_stack;
       top_stack->prev = new;
@@ -2936,7 +2936,7 @@
 		      if (pst && STREQ (namestring, pst->filename))
 			continue;
 		      {
-			register int i;
+			int i;
 			for (i = 0; i < includes_used; i++)
 			  if (STREQ (namestring, psymtab_include_list[i]))
 			    {
@@ -4438,7 +4438,7 @@
    keeping the symtab sorted */
 
 static struct symbol *
-mylookup_symbol (char *name, register struct block *block,
+mylookup_symbol (char *name, struct block *block,
 		 domain_enum domain, enum address_class class)
 {
   struct dict_iterator iter;
@@ -4568,8 +4568,8 @@
 	   compare_blocks);
 
   {
-    register CORE_ADDR high = 0;
-    register int i, j = BLOCKVECTOR_NBLOCKS (bv);
+    CORE_ADDR high = 0;
+    int i, j = BLOCKVECTOR_NBLOCKS (bv);
 
     for (i = FIRST_LOCAL_BLOCK; i < j; i++)
       if (high < BLOCK_END (BLOCKVECTOR_BLOCK (bv, i)))
Index: minsyms.c
===================================================================
RCS file: /cvs/src/src/gdb/minsyms.c,v
retrieving revision 1.33
diff -u -r1.33 minsyms.c
--- minsyms.c	14 Sep 2003 16:32:13 -0000	1.33
+++ minsyms.c	16 Sep 2003 18:52:41 -0000
@@ -148,7 +148,7 @@
    names (the dynamic linker deals with the duplication).  */
 
 struct minimal_symbol *
-lookup_minimal_symbol (register const char *name, const char *sfile,
+lookup_minimal_symbol (const char *name, const char *sfile,
 		       struct objfile *objf)
 {
   struct objfile *objfile;
@@ -268,7 +268,7 @@
    This function only searches the mangled (linkage) names.  */
 
 struct minimal_symbol *
-lookup_minimal_symbol_text (register const char *name, const char *sfile,
+lookup_minimal_symbol_text (const char *name, const char *sfile,
 			    struct objfile *objf)
 {
   struct objfile *objfile;
@@ -345,8 +345,9 @@
    This function only searches the mangled (linkage) names.  */
 
 struct minimal_symbol *
-lookup_minimal_symbol_solib_trampoline (register const char *name,
-					const char *sfile, struct objfile *objf)
+lookup_minimal_symbol_solib_trampoline (const char *name,
+					const char *sfile,
+					struct objfile *objf)
 {
   struct objfile *objfile;
   struct minimal_symbol *msymbol;
Index: mips-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/mips-tdep.c,v
retrieving revision 1.231
diff -u -r1.231 mips-tdep.c
--- mips-tdep.c	14 Sep 2003 16:32:13 -0000	1.231
+++ mips-tdep.c	16 Sep 2003 18:52:42 -0000
@@ -2589,7 +2589,7 @@
          to have their own proc_descs, and even if they don't,
          heuristic_proc_desc knows how to create them! */
 
-      register struct linked_proc_info *link;
+      struct linked_proc_info *link;
 
       for (link = linked_proc_desc_table; link; link = link->next)
 	if (PROC_LOW_ADDR (&link->info) <= pc
Index: printcmd.c
===================================================================
RCS file: /cvs/src/src/gdb/printcmd.c,v
retrieving revision 1.67
diff -u -r1.67 printcmd.c
--- printcmd.c	14 Sep 2003 16:32:13 -0000	1.67
+++ printcmd.c	16 Sep 2003 18:52:43 -0000
@@ -275,7 +275,7 @@
    This is used to pad hex numbers so they line up.  */
 
 static void
-print_formatted (struct value *val, register int format, int size,
+print_formatted (struct value *val, int format, int size,
 		 struct ui_file *stream)
 {
   struct type *type = check_typedef (VALUE_TYPE (val));
Index: remote-vx.c
===================================================================
RCS file: /cvs/src/src/gdb/remote-vx.c,v
retrieving revision 1.28
diff -u -r1.28 remote-vx.c
--- remote-vx.c	14 Sep 2003 16:32:13 -0000	1.28
+++ remote-vx.c	16 Sep 2003 18:52:43 -0000
@@ -255,7 +255,7 @@
    argument string ARGSTRING.  */
 
 static void
-parse_args (register char *arg_string, arg_array *arg_struct)
+parse_args (char *arg_string, arg_array *arg_struct)
 {
   int arg_count = 0;	/* number of arguments */
   int arg_index = 0;
@@ -295,7 +295,7 @@
    to the first non-white character.  */
 
 static char *
-skip_white_space (register char *p)
+skip_white_space (char *p)
 {
   while (*p == ' ' || *p == '\t')
     p++;
@@ -307,7 +307,7 @@
    if no whitespace is found.  */
 
 static char *
-find_white_space (register char *p)
+find_white_space (char *p)
 {
   int c;
 
@@ -1139,7 +1139,7 @@
       pLoadFile = &loadTable.tbl_ent[i];
 #ifdef WRS_ORIG
       {
-	register int desc;
+	int desc;
 	struct cleanup *old_chain;
 	char *fullname = NULL;
 
Index: sh-stub.c
===================================================================
RCS file: /cvs/src/src/gdb/sh-stub.c,v
retrieving revision 1.2
diff -u -r1.2 sh-stub.c
--- sh-stub.c	30 Jul 2000 01:48:27 -0000	1.2
+++ sh-stub.c	16 Sep 2003 18:52:43 -0000
@@ -450,10 +450,10 @@
 /* send the packet in buffer. */
 
 static void
-putpacket (register char *buffer)
+putpacket (char *buffer)
 {
-  register  int checksum;
-  register  int count;
+  int checksum;
+  int count;
 
   /*  $<packet info>#<checksum>. */
   do
Index: sh-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/sh-tdep.c,v
retrieving revision 1.140
diff -u -r1.140 sh-tdep.c
--- sh-tdep.c	16 Sep 2003 15:56:03 -0000	1.140
+++ sh-tdep.c	16 Sep 2003 18:52:44 -0000
@@ -1845,7 +1845,7 @@
   fprintf_filtered (file, "\t(raw 0x");
   for (j = 0; j < register_size (gdbarch, regnum); j++)
     {
-      register int idx = TARGET_BYTE_ORDER == BFD_ENDIAN_BIG ? j
+      int idx = TARGET_BYTE_ORDER == BFD_ENDIAN_BIG ? j
 	: register_size (gdbarch, regnum) - 1 - j;
       fprintf_filtered (file, "%02x", (unsigned char) raw_buffer[idx]);
     }
Index: sh64-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/sh64-tdep.c,v
retrieving revision 1.4
diff -u -r1.4 sh64-tdep.c
--- sh64-tdep.c	14 Sep 2003 16:32:14 -0000	1.4
+++ sh64-tdep.c	16 Sep 2003 18:52:45 -0000
@@ -2602,7 +2602,7 @@
   fprintf_filtered (file, "\t(raw 0x");
   for (j = 0; j < register_size (gdbarch, regnum); j++)
     {
-      register int idx = TARGET_BYTE_ORDER == BFD_ENDIAN_BIG ? j
+      int idx = TARGET_BYTE_ORDER == BFD_ENDIAN_BIG ? j
 	: register_size (gdbarch, regnum) - 1 - j;
       fprintf_filtered (file, "%02x", (unsigned char) raw_buffer[idx]);
     }
Index: source.c
===================================================================
RCS file: /cvs/src/src/gdb/source.c,v
retrieving revision 1.44
diff -u -r1.44 source.c
--- source.c	14 Sep 2003 16:32:14 -0000	1.44
+++ source.c	16 Sep 2003 18:52:45 -0000
@@ -219,7 +219,7 @@
    before we need to would make things slower than necessary.  */
 
 void
-select_source_symtab (register struct symtab *s)
+select_source_symtab (struct symtab *s)
 {
   struct symtabs_and_lines sals;
   struct symtab_and_line sal;
@@ -418,7 +418,7 @@
   do
     {
       char *name = dirname;
-      register char *p;
+      char *p;
       struct stat st;
 
       {
@@ -526,7 +526,7 @@
 
     append:
       {
-	register unsigned int len = strlen (name);
+	unsigned int len = strlen (name);
 
 	p = *which_path;
 	while (1)
@@ -1019,7 +1019,7 @@
 /* Return the line number of character position POS in symtab S.  */
 
 int
-source_charpos_line (register struct symtab *s, register int chr)
+source_charpos_line (struct symtab *s, int chr)
 {
   int line = 0;
   int *lnp;
@@ -1390,7 +1390,7 @@
   while (1)
     {
       static char *buf = NULL;
-      register char *p;
+      char *p;
       int cursize, newsize;
 
       cursize = 256;
@@ -1487,7 +1487,7 @@
     {
 /* FIXME!!!  We walk right off the end of buf if we get a long line!!! */
       char buf[4096];		/* Should be reasonable??? */
-      register char *p = buf;
+      char *p = buf;
 
       c = getc (stream);
       if (c == EOF)
Index: stabsread.c
===================================================================
RCS file: /cvs/src/src/gdb/stabsread.c,v
retrieving revision 1.61
diff -u -r1.61 stabsread.c
--- stabsread.c	14 Sep 2003 16:32:14 -0000	1.61
+++ stabsread.c	16 Sep 2003 18:52:46 -0000
@@ -468,7 +468,7 @@
    Returns 0 for success, -1 for error.  */
 
 static int
-read_type_number (register char **pp, register int *typenums)
+read_type_number (char **pp, int *typenums)
 {
   int nbits;
   if (**pp == '(')
@@ -1941,7 +1941,7 @@
       if (synonym)
 	{
 	  /* Clone the sym and then modify it. */
-	  register struct symbol *typedef_sym = (struct symbol *)
+	  struct symbol *typedef_sym = (struct symbol *)
 	  obstack_alloc (&objfile->symbol_obstack, sizeof (struct symbol));
 	  *typedef_sym = *sym;
 	  SYMBOL_CLASS (typedef_sym) = LOC_TYPEDEF;
@@ -2264,7 +2264,7 @@
    deciding whether to call read_type.  */
 
 static struct type *
-read_type (register char **pp, struct objfile *objfile)
+read_type (char **pp, struct objfile *objfile)
 {
   struct type *type = 0;
   struct type *type1;
@@ -4027,7 +4027,7 @@
 }
 
 static int
-attach_fn_fields_to_type (struct field_info *fip, register struct type *type)
+attach_fn_fields_to_type (struct field_info *fip, struct type *type)
 {
   int n;
 
@@ -4178,7 +4178,7 @@
    for this class's virtual functions.  */
 
 static int
-attach_fields_to_type (struct field_info *fip, register struct type *type,
+attach_fields_to_type (struct field_info *fip, struct type *type,
 		       struct objfile *objfile)
 {
   int nfields = 0;
@@ -4382,7 +4382,7 @@
    array.  */
 
 static struct type *
-read_array_type (register char **pp, register struct type *type,
+read_array_type (char **pp, struct type *type,
 		 struct objfile *objfile)
 {
   struct type *index_type, *element_type, *range_type;
@@ -4445,7 +4445,7 @@
    Also defines the symbols that represent the values of the type.  */
 
 static struct type *
-read_enum_type (register char **pp, register struct type *type,
+read_enum_type (char **pp, struct type *type,
 		struct objfile *objfile)
 {
   char *p;
@@ -5119,7 +5119,7 @@
   struct pending *next = (struct pending *) SYMBOL_TYPE (sym);
   for (; next; next = next->next)
     {
-      register int j;
+      int j;
       for (j = next->nsyms - 1; j >= 0; j--)
 	SYMBOL_VALUE_ADDRESS (next->symbol[j]) += valu;
     }
Index: stack.c
===================================================================
RCS file: /cvs/src/src/gdb/stack.c,v
retrieving revision 1.85
diff -u -r1.85 stack.c
--- stack.c	14 Sep 2003 16:32:14 -0000	1.85
+++ stack.c	16 Sep 2003 18:52:47 -0000
@@ -899,7 +899,7 @@
     }
   else
     {
-      register struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (get_frame_pc (fi));
+      struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (get_frame_pc (fi));
       if (msymbol != NULL)
 	{
 	  funname = DEPRECATED_SYMBOL_NAME (msymbol);
@@ -1347,7 +1347,7 @@
 
 static int
 print_block_frame_labels (struct block *b, int *have_default,
-			  register struct ui_file *stream)
+			  struct ui_file *stream)
 {
   struct dict_iterator iter;
   struct symbol *sym;
@@ -1388,8 +1388,8 @@
    on the function running in FRAME.  */
 
 static void
-print_frame_local_vars (register struct frame_info *fi, register int num_tabs,
-			register struct ui_file *stream)
+print_frame_local_vars (struct frame_info *fi, int num_tabs,
+			struct ui_file *stream)
 {
   struct block *block = get_frame_block (fi, 0);
   int values_printed = 0;
@@ -1421,8 +1421,8 @@
 /* Same, but print labels.  */
 
 static void
-print_frame_label_vars (register struct frame_info *fi, int this_level_only,
-			register struct ui_file *stream)
+print_frame_label_vars (struct frame_info *fi, int this_level_only,
+			struct ui_file *stream)
 {
   struct blockvector *bl;
   struct block *block = get_frame_block (fi, 0);
@@ -1526,8 +1526,8 @@
 }
 
 static void
-print_frame_arg_vars (register struct frame_info *fi,
-		      register struct ui_file *stream)
+print_frame_arg_vars (struct frame_info *fi,
+		      struct ui_file *stream)
 {
   struct symbol *func = get_frame_function (fi);
   struct block *b;
@@ -1657,8 +1657,8 @@
    how much farther the original request asked to go.  */
 
 struct frame_info *
-find_relative_frame (register struct frame_info *frame,
-		     register int *level_offset_ptr)
+find_relative_frame (struct frame_info *frame,
+		     int *level_offset_ptr)
 {
   struct frame_info *prev;
   struct frame_info *frame1;
Index: standalone.c
===================================================================
RCS file: /cvs/src/src/gdb/standalone.c,v
retrieving revision 1.9
diff -u -r1.9 standalone.c
--- standalone.c	14 Sep 2003 22:35:33 -0000	1.9
+++ standalone.c	16 Sep 2003 18:52:47 -0000
@@ -283,7 +283,7 @@
   display_string (buffer);
 }
 
-fwrite (register char *buf, int numelts, int size, int stream)
+fwrite (char *buf, int numelts, int size, int stream)
 {
   int i = numelts * size;
   while (i-- > 0)
Index: symfile.c
===================================================================
RCS file: /cvs/src/src/gdb/symfile.c,v
retrieving revision 1.107
diff -u -r1.107 symfile.c
--- symfile.c	14 Sep 2003 16:32:14 -0000	1.107
+++ symfile.c	16 Sep 2003 18:52:48 -0000
@@ -249,8 +249,8 @@
      short.  FIXME: Is this really still true with a compiler that can
      inline memcpy? */
   {
-    register const char *p1 = ptr;
-    register char *p2 = p;
+    const char *p1 = ptr;
+    char *p2 = p;
     const char *end = ptr + size;
     while (p1 != end)
       *p2++ = *p1++;
@@ -290,7 +290,7 @@
    case inline.  */
 
 struct symtab *
-psymtab_to_symtab (register struct partial_symtab *pst)
+psymtab_to_symtab (struct partial_symtab *pst)
 {
   /* If it's been looked up before, return it. */
   if (pst->symtab)
Index: symmisc.c
===================================================================
RCS file: /cvs/src/src/gdb/symmisc.c,v
retrieving revision 1.24
diff -u -r1.24 symmisc.c
--- symmisc.c	14 Sep 2003 16:32:14 -0000	1.24
+++ symmisc.c	16 Sep 2003 18:52:48 -0000
@@ -116,7 +116,7 @@
    It is s->free_code that says which alternative to use.  */
 
 void
-free_symtab (register struct symtab *s)
+free_symtab (struct symtab *s)
 {
   int i, n;
   struct blockvector *bv;
@@ -1228,7 +1228,7 @@
    be freed in free_objfile().  */
 
 void
-extend_psymbol_list (register struct psymbol_allocation_list *listp,
+extend_psymbol_list (struct psymbol_allocation_list *listp,
 		     struct objfile *objfile)
 {
   int new_size;
Index: symtab.c
===================================================================
RCS file: /cvs/src/src/gdb/symtab.c,v
retrieving revision 1.115
diff -u -r1.115 symtab.c
--- symtab.c	14 Sep 2003 16:32:14 -0000	1.115
+++ symtab.c	16 Sep 2003 18:52:49 -0000
@@ -1630,7 +1630,7 @@
 */
 
 struct symbol *
-lookup_block_symbol (register const struct block *block, const char *name,
+lookup_block_symbol (const struct block *block, const char *name,
 		     const char *linkage_name,
 		     const domain_enum domain)
 {
@@ -2288,7 +2288,7 @@
    Set *EXACT_MATCH nonzero if the value returned is an exact match.  */
 
 static int
-find_line_common (register struct linetable *l, register int lineno,
+find_line_common (struct linetable *l, int lineno,
 		  int *exact_match)
 {
   int i;
@@ -2309,7 +2309,7 @@
   len = l->nitems;
   for (i = 0; i < len; i++)
     {
-      register struct linetable_entry *item = &(l->item[i]);
+      struct linetable_entry *item = &(l->item[i]);
 
       if (item->line == lineno)
 	{
@@ -2417,7 +2417,7 @@
 
   if (isalpha (*p) || *p == '_' || *p == '$')
     {
-      register char *q = p + 1;
+      char *q = p + 1;
       while (isalnum (*q) || *q == '_' || *q == '$')
 	q++;
       *end = q;
Index: utils.c
===================================================================
RCS file: /cvs/src/src/gdb/utils.c,v
retrieving revision 1.107
diff -u -r1.107 utils.c
--- utils.c	14 Sep 2003 16:32:14 -0000	1.107
+++ utils.c	16 Sep 2003 18:52:49 -0000
@@ -282,38 +282,38 @@
    until we get back to the point OLD_CHAIN in the cleanup_chain.  */
 
 void
-do_cleanups (register struct cleanup *old_chain)
+do_cleanups (struct cleanup *old_chain)
 {
   do_my_cleanups (&cleanup_chain, old_chain);
 }
 
 void
-do_final_cleanups (register struct cleanup *old_chain)
+do_final_cleanups (struct cleanup *old_chain)
 {
   do_my_cleanups (&final_cleanup_chain, old_chain);
 }
 
 void
-do_run_cleanups (register struct cleanup *old_chain)
+do_run_cleanups (struct cleanup *old_chain)
 {
   do_my_cleanups (&run_cleanup_chain, old_chain);
 }
 
 void
-do_exec_cleanups (register struct cleanup *old_chain)
+do_exec_cleanups (struct cleanup *old_chain)
 {
   do_my_cleanups (&exec_cleanup_chain, old_chain);
 }
 
 void
-do_exec_error_cleanups (register struct cleanup *old_chain)
+do_exec_error_cleanups (struct cleanup *old_chain)
 {
   do_my_cleanups (&exec_error_cleanup_chain, old_chain);
 }
 
 void
-do_my_cleanups (register struct cleanup **pmy_chain,
-		register struct cleanup *old_chain)
+do_my_cleanups (struct cleanup **pmy_chain,
+		struct cleanup *old_chain)
 {
   struct cleanup *ptr;
   while ((ptr = *pmy_chain) != old_chain)
@@ -328,26 +328,26 @@
    until we get back to the point OLD_CHAIN in the cleanup_chain.  */
 
 void
-discard_cleanups (register struct cleanup *old_chain)
+discard_cleanups (struct cleanup *old_chain)
 {
   discard_my_cleanups (&cleanup_chain, old_chain);
 }
 
 void
-discard_final_cleanups (register struct cleanup *old_chain)
+discard_final_cleanups (struct cleanup *old_chain)
 {
   discard_my_cleanups (&final_cleanup_chain, old_chain);
 }
 
 void
-discard_exec_error_cleanups (register struct cleanup *old_chain)
+discard_exec_error_cleanups (struct cleanup *old_chain)
 {
   discard_my_cleanups (&exec_error_cleanup_chain, old_chain);
 }
 
 void
-discard_my_cleanups (register struct cleanup **pmy_chain,
-		     register struct cleanup *old_chain)
+discard_my_cleanups (struct cleanup **pmy_chain,
+		     struct cleanup *old_chain)
 {
   struct cleanup *ptr;
   while ((ptr = *pmy_chain) != old_chain)
@@ -1265,7 +1265,7 @@
 }
 
 void
-print_spaces (register int n, register struct ui_file *file)
+print_spaces (int n, struct ui_file *file)
 {
   fputs_unfiltered (n_spaces (n), file);
 }
@@ -1456,8 +1456,8 @@
       case '6':
       case '7':
 	{
-	  register int i = c - '0';
-	  register int count = 0;
+	  int i = c - '0';
+	  int count = 0;
 	  while (++count < 3)
 	    {
 	      c = (**string_ptr);
Index: valops.c
===================================================================
RCS file: /cvs/src/src/gdb/valops.c,v
retrieving revision 1.114
diff -u -r1.114 valops.c
--- valops.c	14 Sep 2003 16:32:14 -0000	1.114
+++ valops.c	16 Sep 2003 18:52:50 -0000
@@ -969,7 +969,7 @@
    it to be an argument to a function.  */
 
 static CORE_ADDR
-value_push (register CORE_ADDR sp, struct value *arg)
+value_push (CORE_ADDR sp, struct value *arg)
 {
   int len = TYPE_LENGTH (VALUE_ENCLOSING_TYPE (arg));
   int container_len = len;
@@ -1232,7 +1232,7 @@
 
 static struct value *
 search_struct_field (char *name, struct value *arg1, int offset,
-		     register struct type *type, int looking_for_baseclass)
+		     struct type *type, int looking_for_baseclass)
 {
   int i;
   int nbases = TYPE_N_BASECLASSES (type);
@@ -1472,7 +1472,7 @@
 static struct value *
 search_struct_method (char *name, struct value **arg1p,
 		      struct value **args, int offset,
-		      int *static_memfuncp, register struct type *type)
+		      int *static_memfuncp, struct type *type)
 {
   int i;
   struct value *v;
@@ -2138,7 +2138,7 @@
    target structure/union is defined, otherwise, return 0. */
 
 static int
-check_field_in (register struct type *type, const char *name)
+check_field_in (struct type *type, const char *name)
 {
   int i;
 
Index: values.c
===================================================================
RCS file: /cvs/src/src/gdb/values.c,v
retrieving revision 1.55
diff -u -r1.55 values.c
--- values.c	15 Sep 2003 20:15:19 -0000	1.55
+++ values.c	16 Sep 2003 18:52:50 -0000
@@ -883,7 +883,7 @@
 
 struct value *
 value_primitive_field (struct value *arg1, int offset,
-		       register int fieldno, register struct type *arg_type)
+		       int fieldno, struct type *arg_type)
 {
   struct value *v;
   struct type *type;
@@ -952,7 +952,7 @@
    FIELDNO says which field. */
 
 struct value *
-value_field (struct value *arg1, register int fieldno)
+value_field (struct value *arg1, int fieldno)
 {
   return value_primitive_field (arg1, 0, fieldno, VALUE_TYPE (arg1));
 }
@@ -1114,7 +1114,7 @@
 /* Convert C numbers into newly allocated values */
 
 struct value *
-value_from_longest (struct type *type, register LONGEST num)
+value_from_longest (struct type *type, LONGEST num)
 {
   struct value *val = allocate_value (type);
   enum type_code code;
Index: xcoffread.c
===================================================================
RCS file: /cvs/src/src/gdb/xcoffread.c,v
retrieving revision 1.33
diff -u -r1.33 xcoffread.c
--- xcoffread.c	14 Sep 2003 16:32:14 -0000	1.33
+++ xcoffread.c	16 Sep 2003 18:52:51 -0000
@@ -1438,7 +1438,7 @@
 /* process one xcoff symbol. */
 
 static struct symbol *
-process_xcoff_symbol (register struct coff_symbol *cs, struct objfile *objfile)
+process_xcoff_symbol (struct coff_symbol *cs, struct objfile *objfile)
 {
   struct symbol onesymbol;
   struct symbol *sym = &onesymbol;
@@ -2535,7 +2535,7 @@
 	    if (pst && STREQ (namestring, pst->filename))
 	      continue;
 	    {
-	      register int i;
+	      int i;
 	      for (i = 0; i < includes_used; i++)
 		if (STREQ (namestring, psymtab_include_list[i]))
 		  {

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