This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC 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]

[patch] gcc/p*.[ch]: Fix formatting.


Hi,

Attached is a patch to fix formatting.  Committed as obvious.

Kazu Hirata

2002-05-20  Kazu Hirata  <kazu@cs.umass.edu>

	* params.c: Fix formatting.
	* params.h: Likewise.
	* predict.c: Likewise.
	* prefix.c: Likewise.
	* print-rtl.c: Likewise.
	* print-tree.c: Likewise.
	* profile.c: Likewise.

Index: params.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/params.c,v
retrieving revision 1.2
diff -u -r1.2 params.c
--- params.c	22 Aug 2001 14:35:31 -0000	1.2
+++ params.c	20 May 2002 18:02:45 -0000
@@ -37,14 +37,14 @@
 
 /* Add the N PARAMS to the current list of compiler parameters.  */
 
-void 
+void
 add_params (params, n)
      const param_info params[];
      size_t n;
 {
   /* Allocate enough space for the new parameters.  */
-  compiler_params = 
-    ((param_info *) 
+  compiler_params =
+    ((param_info *)
      xrealloc (compiler_params,
 	       (num_compiler_params + n) * sizeof (param_info)));
   /* Copy them into the table.  */
@@ -79,6 +79,3 @@
   /* If we didn't find this parameter, issue an error message.  */
   error ("invalid parameter `%s'", name);
 }
-
-     
-  
Index: params.h
===================================================================
RCS file: /cvs/gcc/gcc/gcc/params.h,v
retrieving revision 1.13
diff -u -r1.13 params.h
--- params.h	27 Apr 2002 18:59:40 -0000	1.13
+++ params.h	20 May 2002 18:02:45 -0000
@@ -59,7 +59,7 @@
 
 /* Add the N PARAMS to the current list of compiler parameters.  */
 
-extern void add_params 
+extern void add_params
   PARAMS ((const param_info params[], size_t n));
 
 /* Set the VALUE associated with the parameter given by NAME.  */
@@ -75,14 +75,14 @@
 #define DEFPARAM(enumerator, option, msgid, default) \
   enumerator,
 #include "params.def"
-#undef DEFPARAM  
+#undef DEFPARAM
   LAST_PARAM
 } compiler_param;
 
 /* The value of the parameter given by ENUM.  */
 #define PARAM_VALUE(ENUM) \
   (compiler_params[(int) ENUM].value)
-  
+
 /* Macros for the various parameters.  */
 #define MAX_INLINE_INSNS_SINGLE \
   PARAM_VALUE (PARAM_MAX_INLINE_INSNS_SINGLE)
Index: predict.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/predict.c,v
retrieving revision 1.65
diff -u -r1.65 predict.c
--- predict.c	17 May 2002 02:31:42 -0000	1.65
+++ predict.c	20 May 2002 18:02:46 -0000
@@ -74,9 +74,9 @@
 static void estimate_bb_frequencies	 PARAMS ((struct loops *));
 static void counts_to_freqs		 PARAMS ((void));
 static void process_note_predictions	 PARAMS ((basic_block, int *, int *,
-                                                  sbitmap *));
+						  sbitmap *));
 static void process_note_prediction	 PARAMS ((basic_block, int *, int *,
-                                                  sbitmap *, int, int));
+						  sbitmap *, int, int));
 static bool last_basic_block_p           PARAMS ((basic_block));
 static void compute_function_frequency	 PARAMS ((void));
 static void choose_function_section	 PARAMS ((void));
@@ -375,10 +375,10 @@
 
 	  dump_prediction (predictor, probability, bb,
 			   !first_match || best_predictor == predictor);
-          *pnote = XEXP (*pnote, 1);
+	  *pnote = XEXP (*pnote, 1);
 	}
       else
-        pnote = &XEXP (*pnote, 1);
+	pnote = &XEXP (*pnote, 1);
     }
 
   if (!prob_note)
@@ -705,7 +705,7 @@
    should be index of basic block in that we need to alter branch predictions
    (i.e. the first of our dominators such that we do not post-dominate it)
    (but we fill this information on demand, so -1 may be there in case this
-   was not needed yet). */
+   was not needed yet).  */
 
 static void
 process_note_prediction (bb, heads, dominators, post_dominators, pred, flags)
@@ -1117,7 +1117,7 @@
      is available and function has not been executed at all.  */
   if (ENTRY_BLOCK_PTR->frequency == 0)
     return true;
-    
+
   /* Maximally BB_FREQ_MAX^2 so overflow won't happen.  */
   limit = ENTRY_BLOCK_PTR->frequency * threshold;
   for (i = 0; i < n_basic_blocks; i++)
Index: prefix.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/prefix.c,v
retrieving revision 1.33
diff -u -r1.33 prefix.c
--- prefix.c	11 Oct 2001 03:15:55 -0000	1.33
+++ prefix.c	20 May 2002 18:02:46 -0000
@@ -42,7 +42,7 @@
    be considered a "key" and looked up as follows:
 
    -- If this is a Win32 OS, then the Registry will be examined for
-      an entry of "key" in 
+      an entry of "key" in
 
       HKEY_LOCAL_MACHINE\SOFTWARE\Free Software Foundation\<KEY>
 
@@ -58,7 +58,7 @@
    as an environment variable, whose value will be returned.
 
    Once all this is done, any '/' will be converted to DIR_SEPARATOR,
-   if they are different. 
+   if they are different.
 
    NOTE:  using resolve_keyed_path under Win32 requires linking with
    advapi32.dll.  */
@@ -149,10 +149,10 @@
 			     KEY_READ, &reg_key);
 
       if (res != ERROR_SUCCESS)
-        {
-          reg_key = (HKEY) INVALID_HANDLE_VALUE;
-          return 0;
-        }
+	{
+	  reg_key = (HKEY) INVALID_HANDLE_VALUE;
+	  return 0;
+	}
     }
 
   size = 32;
Index: print-rtl.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/print-rtl.c,v
retrieving revision 1.78
diff -u -r1.78 print-rtl.c
--- print-rtl.c	17 May 2002 02:31:45 -0000	1.78
+++ print-rtl.c	20 May 2002 18:02:48 -0000
@@ -85,7 +85,7 @@
   if (TREE_CODE (expr) == COMPONENT_REF)
     {
       if (TREE_OPERAND (expr, 0))
-        print_mem_expr (outfile, TREE_OPERAND (expr, 0));
+	print_mem_expr (outfile, TREE_OPERAND (expr, 0));
       else
 	fputs (" <variable>", outfile);
       fprintf (outfile, ".%s",
@@ -151,7 +151,7 @@
 	fputc ('(', outfile);
       else
 	fprintf (outfile, "(%s", GET_RTX_NAME (GET_CODE (in_rtx)));
-      
+
       if (! flag_simple)
 	{
 	  if (RTX_FLAG (in_rtx, in_struct))
@@ -159,26 +159,26 @@
 
 	  if (RTX_FLAG (in_rtx, volatil))
 	    fputs ("/v", outfile);
-	  
+
 	  if (RTX_FLAG (in_rtx, unchanging))
 	    fputs ("/u", outfile);
-	  
+
 	  if (RTX_FLAG (in_rtx, integrated))
 	    fputs ("/i", outfile);
-	  
+
 	  if (RTX_FLAG (in_rtx, frame_related))
 	    fputs ("/f", outfile);
-	  
+
 	  if (RTX_FLAG (in_rtx, jump))
 	    fputs ("/j", outfile);
-	  
+
 	  if (RTX_FLAG (in_rtx, call))
 	    fputs ("/c", outfile);
 
 	  if (GET_MODE (in_rtx) != VOIDmode)
 	    {
 	      /* Print REG_NOTE names for EXPR_LIST and INSN_LIST.  */
-	      if (GET_CODE (in_rtx) == EXPR_LIST 
+	      if (GET_CODE (in_rtx) == EXPR_LIST
 		  || GET_CODE (in_rtx) == INSN_LIST)
 		fprintf (outfile, ":%s",
 			 GET_REG_NOTE_NAME (GET_MODE (in_rtx)));
@@ -246,7 +246,7 @@
 		if (flag_dump_unnumbered)
 		  fprintf (outfile, "#");
 		else
-		  fprintf (outfile, HOST_PTR_PRINTF, 
+		  fprintf (outfile, HOST_PTR_PRINTF,
 			   (char *) NOTE_BLOCK (in_rtx));
 		sawclose = 1;
 		break;
@@ -284,15 +284,15 @@
 		  fprintf (outfile, " \"\"");
 		break;
 
-              case NOTE_INSN_PREDICTION:
-                if (NOTE_PREDICTION (in_rtx))
-                  fprintf (outfile, " [ %d %d ] ",
-                    (int)NOTE_PREDICTION_ALG (in_rtx),
-                    (int) NOTE_PREDICTION_FLAGS (in_rtx));
-                else
-                  fprintf (outfile, " [ ERROR ]");
-                break;
-                            
+	      case NOTE_INSN_PREDICTION:
+		if (NOTE_PREDICTION (in_rtx))
+		  fprintf (outfile, " [ %d %d ] ",
+			   (int)NOTE_PREDICTION_ALG (in_rtx),
+			   (int) NOTE_PREDICTION_FLAGS (in_rtx));
+		else
+		  fprintf (outfile, " [ ERROR ]");
+		break;
+
 	      default:
 		{
 		  const char * const str = X0STR (in_rtx, i);
@@ -329,7 +329,7 @@
 	if (sawclose)
 	  {
 	    fprintf (outfile, "\n%s%*s",
-                     print_rtx_head, indent * 2, "");
+		     print_rtx_head, indent * 2, "");
 	    sawclose = 0;
 	  }
 	fputs ("[ ", outfile);
@@ -531,7 +531,7 @@
     case CODE_LABEL:
       fprintf (outfile, " [%d uses]", LABEL_NUSES (in_rtx));
       if (LABEL_ALTERNATE_NAME (in_rtx))
-        fprintf (outfile, " [alternate name: %s]",
+	fprintf (outfile, " [alternate name: %s]",
 		 LABEL_ALTERNATE_NAME (in_rtx));
       break;
 
@@ -731,14 +731,14 @@
 	  if (! flag_dump_unnumbered
 	      || GET_CODE (tmp_rtx) != NOTE || NOTE_LINE_NUMBER (tmp_rtx) < 0)
 	    {
-              fputs (print_rtx_head, outfile);
+	      fputs (print_rtx_head, outfile);
 	      print_rtx (tmp_rtx);
 	      fprintf (outfile, "\n");
 	    }
 	break;
 
       default:
-        fputs (print_rtx_head, outfile);
+	fputs (print_rtx_head, outfile);
 	print_rtx (rtx_first);
       }
 }
Index: print-tree.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/print-tree.c,v
retrieving revision 1.56
diff -u -r1.56 print-tree.c
--- print-tree.c	15 Mar 2002 07:09:54 -0000	1.56
+++ print-tree.c	20 May 2002 18:02:48 -0000
@@ -384,7 +384,7 @@
 
       print_node (file, "size", DECL_SIZE (node), indent + 4);
       print_node (file, "unit size", DECL_SIZE_UNIT (node), indent + 4);
-      
+
       if (TREE_CODE (node) != FUNCTION_DECL
 	  || DECL_INLINE (node) || DECL_BUILT_IN (node))
 	indent_to (file, indent + 3);
@@ -415,7 +415,7 @@
       if (DECL_POINTER_ALIAS_SET_KNOWN_P (node))
 	{
 	  fprintf (file, " alias set ");
-	  fprintf (file, HOST_WIDE_INT_PRINT_DEC, 
+	  fprintf (file, HOST_WIDE_INT_PRINT_DEC,
 		   DECL_POINTER_ALIAS_SET (node));
 	}
 
@@ -633,7 +633,7 @@
       if (TREE_CODE (node) == EXPR_WITH_FILE_LOCATION)
 	{
 	  indent_to (file, indent+4);
-          fprintf (file, "%s:%d:%d", 
+	  fprintf (file, "%s:%d:%d",
 		   (EXPR_WFL_FILENAME_NODE (node ) ?
 		    EXPR_WFL_FILENAME (node) : "(no file info)"),
 		   EXPR_WFL_LINENO (node), EXPR_WFL_COLNO (node));
Index: profile.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/profile.c,v
retrieving revision 1.86
diff -u -r1.86 profile.c
--- profile.c	17 May 2002 02:31:46 -0000	1.86
+++ profile.c	20 May 2002 18:02:50 -0000
@@ -209,7 +209,7 @@
 }
 
 
-/* Computes hybrid profile for all matching entries in da_file. 
+/* Computes hybrid profile for all matching entries in da_file.
    Sets max_counter_in_program as a side effect.  */
 
 static gcov_type *
@@ -244,7 +244,7 @@
 	  }
     }
 
-  /* now read and combine all matching profiles. */
+  /* now read and combine all matching profiles.  */
 
   profile = xmalloc (sizeof (gcov_type) * num_edges);
   rewind (da_file);
@@ -698,7 +698,7 @@
   long chsum = 0;
   int i;
 
-  
+
   for (i = 0; i < n_basic_blocks ; i++)
     {
       basic_block bb = BASIC_BLOCK (i);
@@ -741,9 +741,9 @@
   profile_info.current_function_cfg_checksum = compute_checksum ();
 
   if (rtl_dump_file)
-    fprintf (rtl_dump_file, "CFG checksum is %ld\n", 
+    fprintf (rtl_dump_file, "CFG checksum is %ld\n",
 	profile_info.current_function_cfg_checksum);
-  
+
   /* Start of a function.  */
   if (flag_test_coverage)
     output_gcov_string (current_function_name, (long) -2);
@@ -820,14 +820,14 @@
 	  if (rtl_dump_file)
 	    fprintf (rtl_dump_file, "Adding fake exit edge to bb %i\n",
 		     bb->index);
-          make_edge (bb, EXIT_BLOCK_PTR, EDGE_FAKE);
+	  make_edge (bb, EXIT_BLOCK_PTR, EDGE_FAKE);
 	}
       if (need_entry_edge && !have_entry_edge)
 	{
 	  if (rtl_dump_file)
 	    fprintf (rtl_dump_file, "Adding fake entry edge to bb %i\n",
 		     bb->index);
-          make_edge (ENTRY_BLOCK_PTR, bb, EDGE_FAKE);
+	  make_edge (ENTRY_BLOCK_PTR, bb, EDGE_FAKE);
 	}
     }
 
@@ -844,10 +844,10 @@
       /* Mark edges we've replaced by fake edges above as ignored.  */
       if ((e->flags & (EDGE_ABNORMAL | EDGE_ABNORMAL_CALL))
 	  && e->src != ENTRY_BLOCK_PTR && e->dest != EXIT_BLOCK_PTR)
-        {
+	{
 	  EDGE_INFO (e)->ignore = 1;
 	  ignored_edges++;
-        }
+	}
     }
 
 #ifdef ENABLE_CHECKING
@@ -860,10 +860,10 @@
     {
       int i = 0;
       for (i = 0 ; i < n_basic_blocks; i++)
-        {
+	{
 	  basic_block bb = BASIC_BLOCK (i);
 	  rtx insn = bb->head;
-          static int ignore_next_note = 0;
+	  static int ignore_next_note = 0;
 
 	  /* We are looking for line number notes.  Search backward before
 	     basic block to find correct ones.  */
@@ -916,7 +916,7 @@
 		}
 	      insn = NEXT_INSN (insn);
 	    }
-        }
+	}
       __write_long (0, bb_file, 4);
     }
 
@@ -933,10 +933,10 @@
       edge e = INDEX_EDGE (el, i);
       struct edge_info *inf = EDGE_INFO (e);
       if ((e->flags & EDGE_FAKE) && !inf->ignore && !inf->on_tree)
-        {
-          inf->ignore = 1;
-          ignored_edges++;
-        }
+	{
+	  inf->ignore = 1;
+	  ignored_edges++;
+	}
     }
 
   total_num_blocks += n_basic_blocks + 2;
@@ -965,7 +965,7 @@
 
       /* write checksum.  */
       __write_long (profile_info.current_function_cfg_checksum, bbg_file, 4);
-      
+
       /* The plus 2 stands for entry and exit block.  */
       __write_long (n_basic_blocks + 2, bbg_file, 4);
       __write_long (num_edges - ignored_edges + 1, bbg_file, 4);
@@ -1099,14 +1099,14 @@
     {
       edge e = INDEX_EDGE (el, i);
       if (((e->flags & (EDGE_ABNORMAL | EDGE_ABNORMAL_CALL | EDGE_FAKE))
-           || e->dest == EXIT_BLOCK_PTR
-          )
+	   || e->dest == EXIT_BLOCK_PTR
+	   )
 	  && !EDGE_INFO (e)->ignore
 	  && (find_group (e->src) != find_group (e->dest)))
 	{
 	  if (rtl_dump_file)
 	    fprintf (rtl_dump_file, "Abnormal edge %d to %d put to tree\n",
-                     e->src->index, e->dest->index);
+		     e->src->index, e->dest->index);
 	  EDGE_INFO (e)->on_tree = 1;
 	  union_groups (e->src, e->dest);
 	}
@@ -1122,7 +1122,7 @@
 	{
 	  if (rtl_dump_file)
 	    fprintf (rtl_dump_file, "Critical edge %d to %d put to tree\n",
-                     e->src->index, e->dest->index);
+		     e->src->index, e->dest->index);
 	  EDGE_INFO (e)->on_tree = 1;
 	  union_groups (e->src, e->dest);
 	}
@@ -1137,7 +1137,7 @@
 	{
 	  if (rtl_dump_file)
 	    fprintf (rtl_dump_file, "Normal edge %d to %d put to tree\n",
-                     e->src->index, e->dest->index);
+		     e->src->index, e->dest->index);
 	  EDGE_INFO (e)->on_tree = 1;
 	  union_groups (e->src, e->dest);
 	}


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