From 87e97de6e42a3b00713ce8f634524c31e9016650 Mon Sep 17 00:00:00 2001
From: aj <aj@138bc75d-0d04-0410-961f-82ee72b054a4>
Date: Mon, 16 Jul 2001 09:16:04 +0000
Subject: [PATCH] 	* gcov.c (output_data): Use HOST_WIDEST_INT_PRINT_DEC
 to output 	variables of type HOST_WIDEST_INT.

	* libgcc2.c (__bb_exit_func): Handle gcov_type as long long.
	(__bb_exit_func): Correct type of count_max to avoid overflow.
	(num_digits): Handle long long argument.

	* combine.c (gen_lowpart_for_combine): Remove unused variable.


git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@44033 138bc75d-0d04-0410-961f-82ee72b054a4
---
 gcc/ChangeLog |  29 +++++++++-----
 gcc/combine.c |  43 ++++++++++-----------
 gcc/gcov.c    |  36 ++++++++++--------
 gcc/libgcc2.c | 103 +++++++++++++++++++++++++++-----------------------
 4 files changed, 116 insertions(+), 95 deletions(-)

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 0526f8f51bde..c5dd275ed535 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,14 @@
+2001-07-16  Andreas Jaeger  <aj@suse.de>
+
+	* gcov.c (output_data): Use HOST_WIDEST_INT_PRINT_DEC to output
+	variables of type HOST_WIDEST_INT.
+
+	* libgcc2.c (__bb_exit_func): Handle gcov_type as long long.
+	(__bb_exit_func): Correct type of count_max to avoid overflow.
+	(num_digits): Handle long long argument.
+
+	* combine.c (gen_lowpart_for_combine): Remove unused variable.
+
 2001-07-16  Neil Booth  <neil@cat.daikokuya.demon.co.uk>
 
 	* output.h (sdb_begin_function_line): Restore as an extern
@@ -271,16 +282,16 @@ Fri Jul 13 23:04:00 2001  Denis Chertykov  <denisc@overta.ru>
 
 2001-07-13  Hartmut Penner  <hpenner@de.ibm.com>
 
-        * config.gcc: Add configuration for s/390. 
-        * config/s390/s390.c: New. Subroutines for code generation.
+	* config.gcc: Add configuration for s/390.
+	* config/s390/s390.c: New. Subroutines for code generation.
 	* config/s390/s390.h: New. Definitions for s/390.
 	* config/s390/s390-protos.h: New. Prototypes.
 	* config/s390/linux.h: New. Definitions for linux for s/390.
 	* config/s390/linux64.h: New. Definitions for linux for zSeries.
-        * config/s390/t-linux: New. Makefile fragment.
-        * config/s390/s390.md: New. Machine description for s/390 and zSeries.
+	* config/s390/t-linux: New. Makefile fragment.
+	* config/s390/s390.md: New. Machine description for s/390 and zSeries.
 	* config/s390/fixdfdi.h: New. Fix L_fix*di.
-	
+
 Fri Jul 13 14:46:21 CEST 2001  Jan Hubicka  <jh@suse.cz>
 
 	* emit-rtl.c (try_split): Update mark_jump_label call.
@@ -475,7 +486,7 @@ Wed Jul 11 21:27:25 CEST 2001  Jan Hubicka  <jh@suse.cz>
 	* jump.c (rtx_renumbered_equal_p): Handle 't' fields.
 	* output.h (cleanup_cfg): Update prototype.
 	* reg-stack.c (reg_to_stack): Use cleanup_cfg instead of jump_optimize
-	* sibcall.c (optimize_sibling_and_tail_recursive_call): Update 
+	* sibcall.c (optimize_sibling_and_tail_recursive_call): Update
 	cleanup_cfg call; kill missleading comment.
 	* toplev.c (rest_of_compilation): Update all cleanup_cfg calls.
 	* flow.c (merge_blocks, try_optimize_cfg, cleanup_cfg): Accept mode
@@ -506,7 +517,7 @@ Wed Jul 11 21:27:25 CEST 2001  Jan Hubicka  <jh@suse.cz>
 
 2001-07-11  Mark Mitchell  <mark@codesourcery.com>
 
-	* stmt.c (parse_output_constraint): New function, split out 
+	* stmt.c (parse_output_constraint): New function, split out
 	from ...
 	(expand_asm_operands): ... here.  Use parse_output_constraint.
 	* tree.h (parse_output_constraint): Declare it.
@@ -573,7 +584,7 @@ Tue Jul 10 07:27:53 2001  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
 	* recog.c (offsettable_address_p): Handle LO_SUM case.
 	* config/mips/mips.c (double_memory_operand): Use adjust_address_nv
 	instead of plus_constant.
-	
+
 2001-07-10  Stephane Carrez  <Stephane.Carrez@worldnet.fr>
 
 	* reload1.c (merge_assigned_reloads): After a RELOAD_OTHER merge,
@@ -640,7 +651,7 @@ Tue Jul 10 09:04:45 2001  Jeffrey A Law  (law@cygnus.com)
 	.loc support.
 
 	* collect2.c (main): Set COLLECT_NO_DEMANGLE for subprocesses.
-	(dump_file): Only pad the demangled name with spaces if the 
+	(dump_file): Only pad the demangled name with spaces if the
 	mangled name was padded with spaces.
 
 2001-07-10  Bernd Schmidt  <bernds@redhat.com>
diff --git a/gcc/combine.c b/gcc/combine.c
index 2557d7583676..6c2f40fdb74c 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -1133,7 +1133,7 @@ can_combine_p (insn, i3, pred, succ, pdest, psrc)
 
       for (p = NEXT_INSN (insn); p != i3; p = NEXT_INSN (p))
         if (INSN_P (p) && p != succ && volatile_refs_p (PATTERN (p)))
-  	return 0;
+	return 0;
     }
 
   /* If INSN is an asm, and DEST is a hard register, reject, since it has
@@ -1245,7 +1245,7 @@ sets_function_arg_p (pat)
    This is NOT equivalent to:
 
          (parallel [(set (subreg:SI (reg:DI 100) 0) <foo>)
-	 	    (set (reg:DI 101) (reg:DI 100))])
+		    (set (reg:DI 101) (reg:DI 100))])
 
    Not only does this modify 100 (in which case it might still be valid
    if 100 were dead in I2), it sets 101 to the ORIGINAL value of 100.
@@ -1421,7 +1421,7 @@ cant_combine_insn_p (insn)
 {
   rtx set;
   rtx src, dest;
-  
+
   /* If this isn't really an insn, we can't do anything.
      This can occur when flow deletes an insn that it has merged into an
      auto-increment address.  */
@@ -1771,7 +1771,7 @@ try_combine (i3, i2, i1, new_direct_jump_p)
   /* If I3 has an inc, then give up if I1 or I2 uses the reg that is inc'd.
      We used to do this EXCEPT in one case: I3 has a post-inc in an
      output operand.  However, that exception can give rise to insns like
-     	mov r3,(r3)+
+	mov r3,(r3)+
      which is a famous insn on the PDP-11 where the value of r3 used as the
      source was model-dependent.  Avoid this sort of thing.  */
 
@@ -2136,7 +2136,7 @@ try_combine (i3, i2, i1, new_direct_jump_p)
 	  insn_code_number = recog_for_combine (&m_split, i3, &new_i3_notes);
 	  if (insn_code_number >= 0)
 	    newpat = m_split;
-	} 
+	}
       else if (m_split && GET_CODE (m_split) == SEQUENCE
 	       && XVECLEN (m_split, 0) == 2
 	       && (next_real_insn (i2) == i3
@@ -3786,7 +3786,7 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
       {
 	rtx temp;
 	temp = simplify_subreg (mode, SUBREG_REG (x), op0_mode,
-		       		SUBREG_BYTE (x));
+				SUBREG_BYTE (x));
 	if (temp)
 	  return temp;
       }
@@ -3861,12 +3861,12 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
 	return gen_rtx_GE (mode, XEXP (XEXP (x, 0), 0), const0_rtx);
 
       /* Apply De Morgan's laws to reduce number of patterns for machines
- 	 with negating logical insns (and-not, nand, etc.).  If result has
- 	 only one NOT, put it first, since that is how the patterns are
- 	 coded.  */
+	 with negating logical insns (and-not, nand, etc.).  If result has
+	 only one NOT, put it first, since that is how the patterns are
+	 coded.  */
 
       if (GET_CODE (XEXP (x, 0)) == IOR || GET_CODE (XEXP (x, 0)) == AND)
- 	{
+	{
 	  rtx in1 = XEXP (XEXP (x, 0), 0), in2 = XEXP (XEXP (x, 0), 1);
 	  enum machine_mode op_mode;
 
@@ -3931,7 +3931,7 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
       temp = expand_compound_operation (XEXP (x, 0));
 
       /* For C equal to the width of MODE minus 1, (neg (ashiftrt X C)) can be
- 	 replaced by (lshiftrt X C).  This will convert
+	 replaced by (lshiftrt X C).  This will convert
 	 (neg (sign_extract X 1 Y)) to (zero_extract X 1 Y).  */
 
       if (GET_CODE (temp) == ASHIFTRT
@@ -4015,7 +4015,7 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
 	  && num_sign_bit_copies (XEXP (x, 0), GET_MODE (XEXP (x, 0)))
 	     >= GET_MODE_BITSIZE (mode) + 1
 	  && ! (GET_CODE (XEXP (x, 0)) == LSHIFTRT
- 		&& GET_CODE (XEXP (XEXP (x, 0), 0)) == MULT))
+		&& GET_CODE (XEXP (XEXP (x, 0), 0)) == MULT))
 	return gen_lowpart_for_combine (mode, XEXP (x, 0));
 
       /* A truncate of a comparison can be replaced with a subreg if
@@ -4250,8 +4250,8 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
     case GT:  case GTU:  case GE:  case GEU:
     case LT:  case LTU:  case LE:  case LEU:
     case UNEQ:  case LTGT:
-    case UNGT:  case UNGE:  
-    case UNLT:  case UNLE:  
+    case UNGT:  case UNGE:
+    case UNLT:  case UNLE:
     case UNORDERED: case ORDERED:
       /* If the first operand is a condition code, we can't do anything
 	 with it.  */
@@ -4527,7 +4527,7 @@ combine_simplify_rtx (x, op0_mode, last, in_dest)
       }
 
       break;
-      
+
     default:
       break;
     }
@@ -5579,7 +5579,7 @@ expand_compound_operation (x)
 	  && GET_RTX_CLASS (GET_CODE (XEXP (XEXP (x, 0), 0))) == '<'
 	  && (GET_MODE_BITSIZE (GET_MODE (XEXP (x, 0)))
 	      <= HOST_BITS_PER_WIDE_INT)
- 	  && ((HOST_WIDE_INT) STORE_FLAG_VALUE
+	  && ((HOST_WIDE_INT) STORE_FLAG_VALUE
 	      & ~GET_MODE_MASK (GET_MODE (XEXP (x, 0)))) == 0)
 	return XEXP (XEXP (x, 0), 0);
 
@@ -5922,9 +5922,9 @@ make_extraction (mode, inner, pos, pos_rtx, len,
 
 	      new = gen_rtx_SUBREG (tmode, inner, final_word);
 	    }
-  	  else
-  	    new = inner;
-  	}
+	  else
+	    new = inner;
+	}
       else
 	new = force_to_mode (inner, tmode,
 			     len >= HOST_BITS_PER_WIDE_INT
@@ -7418,7 +7418,7 @@ known_cond (x, cond, reg, val)
 	      /* Do not reverse the condition when it is NE or EQ.
 		 This is because we cannot conclude anything about
 		 the value of 'SMAX (x, y)' when x is not equal to y,
-		 but we can when x equals y.  */ 
+		 but we can when x equals y.  */
 	      if ((code == SMAX || code == UMAX)
 		  && ! (cond == EQ || cond == NE))
 		cond = reverse_condition (cond);
@@ -9717,7 +9717,6 @@ gen_lowpart_for_combine (mode, x)
   if (GET_CODE (x) == MEM)
     {
       register int offset = 0;
-      rtx new;
 
       /* Refuse to work on a volatile memory ref or one with a mode-dependent
 	 address.  */
@@ -10530,7 +10529,7 @@ simplify_comparison (code, pop0, pop1)
 		new_code = GET_CODE (op0);
 	      else
 		new_code = combine_reversed_comparison_code (op0);
-	  
+
 	      if (new_code != UNKNOWN)
 		{
 		  code = new_code;
diff --git a/gcc/gcov.c b/gcc/gcov.c
index fa1e9d9937a2..0251a65703ea 100644
--- a/gcc/gcov.c
+++ b/gcc/gcov.c
@@ -1,7 +1,7 @@
 /* Gcov.c: prepend line execution counts and branch probabilities to a
    source file.
    Copyright (C) 1990, 1991, 1992, 1993, 1994, 1996, 1997, 1998,
-   1999, 2000 Free Software Foundation, Inc.
+   1999, 2000, 2001 Free Software Foundation, Inc.
    Contributed by James E. Wilson of Cygnus Support.
    Mangled by Bob Manson of Cygnus Support.
 
@@ -218,7 +218,7 @@ static char *object_directory = 0;
 
 /* Output the number of times a branch was taken as opposed to the percentage
    of times it was taken.  Turned on by the -c option */
-   
+
 static int output_branch_counts = 0;
 
 /* Forward declarations.  */
@@ -438,7 +438,7 @@ open_files ()
       fnotice (stderr, "Could not open data file %s.\n", da_file_name);
       fnotice (stderr, "Assuming that all execution counts are zero.\n");
     }
-    
+
   bbg_file = fopen (bbg_file_name, "rb");
   if (bbg_file == NULL)
     {
@@ -590,7 +590,7 @@ create_program_flow_graph (bptr)
 	  bb_graph[arcptr->target].pred_count--;
 	}
 }
-  
+
 static void
 solve_program_flow_graph (bptr)
      struct bb_info_list *bptr;
@@ -707,7 +707,7 @@ solve_program_flow_graph (bptr)
 	    }
 	}
     }
-	      
+
   /* If the graph has been correctly solved, every block will have a
      succ and pred count of zero.  */
   for (i = 0; i < num_blocks; i++)
@@ -772,7 +772,7 @@ read_files ()
 
   bb_data = (char *) xmalloc ((unsigned) buf.st_size);
   fread (bb_data, sizeof (char), buf.st_size, bb_file);
-  
+
   fclose (bb_file);
   if (da_file)
     fclose (da_file);
@@ -890,7 +890,7 @@ calculate_branch_probs (current_graph, block_num, branch_probs, last_line_num)
 
       if (arcptr->fall_through)
 	continue;
-		      
+
       a_ptr = (struct arcdata *) xmalloc (sizeof (struct arcdata));
       a_ptr->total = total;
       if (total == 0)
@@ -1042,7 +1042,7 @@ output_data ()
       if (output_branch_probs)
 	branch_probs = (struct arcdata **)
 	  xcalloc (sizeof (struct arcdata *), s_ptr->maxlineno);
-      
+
       /* There will be a zero at the beginning of the bb info, before the
 	 first list of line numbers, so must initialize block_num to 0.  */
       block_num = 0;
@@ -1066,7 +1066,7 @@ output_data ()
 		  this_file = 0;
 		else
 		  this_file = 1;
-	      
+
 		/* Scan past the file name.  */
 		do {
 		  count++;
@@ -1139,7 +1139,7 @@ output_data ()
 			     function_name);
 		    abort ();
 		  }
-		  
+
 		if (output_branch_probs && this_file)
 		  calculate_branch_probs (current_graph, block_num,
 					  branch_probs, last_line_num);
@@ -1246,7 +1246,7 @@ output_data ()
 	  /* Now the statistics are ready.  Read in the source file one line
 	     at a time, and output that line to the gcov file preceded by
 	     its execution count if non zero.  */
-      
+
 	  source_file = fopen (source_file_name, "r");
 	  if (source_file == NULL)
 	    {
@@ -1266,7 +1266,7 @@ output_data ()
 	  if (output_long_names && strcmp (cptr, input_file_name))
 	    {
 	      gcov_file_name = xmalloc (count + 7 + strlen (input_file_name));
-	      
+
 	      cptr = strrchr (input_file_name, '/');
 	      if (cptr)
 		strcpy (gcov_file_name, cptr + 1);
@@ -1361,11 +1361,13 @@ output_data ()
 			      {
 				if (output_branch_counts)
 				  fnotice (gcov_file,
-				           "call %d returns = %d\n",
+				           "call %d returns = "
+					   HOST_WIDEST_INT_PRINT_DEC "\n",
 				           i, a_ptr->total - a_ptr->hits);
 			        else
                                   fnotice (gcov_file,
-				           "call %d returns = %d%%\n",
+				           "call %d returns = "
+					   HOST_WIDEST_INT_PRINT_DEC "%%\n",
 				            i, 100 - ((a_ptr->hits * 100) +
                                            (a_ptr->total >> 1))/a_ptr->total);
 			      }
@@ -1379,11 +1381,13 @@ output_data ()
 			    {
 			      if (output_branch_counts)
 			        fnotice (gcov_file,
-				         "branch %d taken = %d\n",
+				         "branch %d taken = "
+					 HOST_WIDEST_INT_PRINT_DEC "\n",
                                          i, a_ptr->hits);
 			      else
                                 fnotice (gcov_file,
-                                         "branch %d taken = %d%%\n", i,
+                                         "branch %d taken = "
+					 HOST_WIDEST_INT_PRINT_DEC "%%\n", i,
                                          ((a_ptr->hits * 100) +
                                           (a_ptr->total >> 1))/
                                           a_ptr->total);
diff --git a/gcc/libgcc2.c b/gcc/libgcc2.c
index 0c42ac6e2db2..0ab29f747ab7 100644
--- a/gcc/libgcc2.c
+++ b/gcc/libgcc2.c
@@ -76,7 +76,7 @@ __addvsi3 (Wtype a, Wtype b)
     abort ();
 
   return w;
-} 
+}
 #endif
 
 #ifdef L_addvdi3
@@ -1069,7 +1069,7 @@ __floatdidf (DWtype u)
 
 /* Define codes for all the float formats that we know of.  Note
    that this is copied from real.h.  */
-   
+
 #define UNKNOWN_FLOAT_FORMAT 0
 #define IEEE_FLOAT_FORMAT 1
 #define VAX_FLOAT_FORMAT 2
@@ -1311,13 +1311,13 @@ char *ctime PARAMS ((const time_t *));
 
 static struct bb *bb_head;
 
-static int num_digits (long value, int base) __attribute__ ((const));
+static int num_digits (long long value, int base) __attribute__ ((const));
 
 /* Return the number of digits needed to print a value */
-/* __inline__ */ static int num_digits (long value, int base)
+/* __inline__ */ static int num_digits (long long value, int base)
 {
   int minus = (value < 0 && base != 16);
-  unsigned long v = (minus) ? -value : value;
+  unsigned long long v = (minus) ? -value : value;
   int ret = minus;
 
   do
@@ -1406,7 +1406,7 @@ __bb_exit_func (void)
 	  else
 	    {
 	      long n_counts = 0;
-	      
+
 	      if (ungetc (firstchar, da_file) == EOF)
 		rewind (da_file);
 	      if (__read_long (&n_counts, da_file, 8) != 0)
@@ -1448,7 +1448,7 @@ __bb_exit_func (void)
 
 	  if (__write_gcov_type (ptr->ncounts, da_file, 8) != 0)
 	    {
-	      
+
 	      fprintf (stderr, "arc profiling: Error writing output file %s.\n",
 		       ptr->filename);
 	    }
@@ -1470,7 +1470,7 @@ __bb_exit_func (void)
 		fprintf (stderr, "arc profiling: Error writing output file %s.\n",
 			 ptr->filename);
 	    }
-	  
+
 	  if (fclose (da_file) == EOF)
 	    fprintf (stderr, "arc profiling: Error closing output file %s.\n",
 		     ptr->filename);
@@ -1512,7 +1512,7 @@ __bb_exit_func (void)
 	  int file_p	= (func_p && ptr->filenames);
 	  int addr_p	= (ptr->addresses != 0);
 	  long ncounts	= ptr->ncounts;
-	  long cnt_max  = 0;
+	  gcov_type cnt_max  = 0;
 	  long line_max = 0;
 	  long addr_max = 0;
 	  int file_len	= 0;
@@ -1564,10 +1564,17 @@ __bb_exit_func (void)
 	  /* Now print out the basic block information.  */
 	  for (i = 0; i < ncounts; i++)
 	    {
+#if LONG_TYPE_SIZE == GCOV_TYPE_SIZE
 	      fprintf (file,
 		       "    Block #%*d: executed %*ld time(s)",
 		       blk_len, i+1,
 		       cnt_len, ptr->counts[i]);
+#else
+	      fprintf (file,
+		       "    Block #%*d: executed %*lld time(s)",
+		       blk_len, i+1,
+		       cnt_len, ptr->counts[i]);
+#endif
 
 	      if (addr_p)
 		fprintf (file, " address= 0x%.*lx", addr_len,
@@ -1677,7 +1684,7 @@ struct {
   struct bb *blocks;
 } __bb;
 
-/* Vars to store addrs of source and destination basic blocks 
+/* Vars to store addrs of source and destination basic blocks
    of a jump.  */
 
 static unsigned long bb_src = 0;
@@ -1727,7 +1734,7 @@ gopen (char *fn, char *mode)
   if (mode[1])
     return (FILE *) 0;
 
-  if (mode[0] != 'r' && mode[0] != 'w') 
+  if (mode[0] != 'r' && mode[0] != 'w')
     return (FILE *) 0;
 
   p = fn + strlen (fn)-1;
@@ -1791,7 +1798,7 @@ __bb_exit_trace_func (void)
   FILE *file = fopen ("bb.out", "a");
   struct bb_func *f;
   struct bb *b;
-        
+
   if (!file)
     perror ("bb.out");
 
@@ -1832,7 +1839,7 @@ __bb_exit_trace_func (void)
                     goto found;
                 }
             }
-  
+
           if (!printed_something)
             {
               fprintf (file, "Functions in `bb.in' not executed during basic block profiling on %s\n", ctime ((void *) &time_value));
@@ -1843,7 +1850,7 @@ __bb_exit_trace_func (void)
           if (p->filename)
               fprintf (file, " of file %s", p->filename);
           fprintf (file, "\n" );
-  
+
 found:        ;
         }
 
@@ -1863,7 +1870,7 @@ found:        ;
             }
           return;
         }
-    
+
       else if (file)
         {
           long time_value;
@@ -1872,13 +1879,13 @@ found:        ;
           unsigned long cnt_max  = 0;
           int cnt_len;
           int addr_len;
-    
+
           /* This is somewhat type incorrect, but it avoids worrying about
              exactly where time.h is included from.  It should be ok unless
              a void * differs from other pointer formats, or if sizeof (long)
              is < sizeof (time_t).  It would be nice if we could assume the
              use of rationale standards here.  */
-    
+
           time ((void *) &time_value);
           fprintf (file, "Basic block jump tracing");
 
@@ -1902,36 +1909,36 @@ found:        ;
             }
 
           fprintf (file, " finished on %s\n", ctime ((void *) &time_value));
-    
+
           for (i = 0; i < BB_BUCKETS; i++)
             {
                struct bb_edge *bucket = bb_hashbuckets[i];
                for ( ; bucket; bucket = bucket->next )
                  {
-                   if (addr_max < bucket->src_addr) 
+                   if (addr_max < bucket->src_addr)
                      addr_max = bucket->src_addr;
-                   if (addr_max < bucket->dst_addr) 
+                   if (addr_max < bucket->dst_addr)
                      addr_max = bucket->dst_addr;
-                   if (cnt_max < bucket->count) 
+                   if (cnt_max < bucket->count)
                      cnt_max = bucket->count;
                  }
             }
           addr_len = num_digits (addr_max, 16);
           cnt_len  = num_digits (cnt_max, 10);
-    
+
           for ( i = 0; i < BB_BUCKETS; i++)
             {
                struct bb_edge *bucket = bb_hashbuckets[i];
                for ( ; bucket; bucket = bucket->next )
                  {
                    fprintf (file,
-	"Jump from block 0x%.*lx to block 0x%.*lx executed %*lu time(s)\n", 
-                            addr_len, bucket->src_addr, 
-                            addr_len, bucket->dst_addr, 
+	"Jump from block 0x%.*lx to block 0x%.*lx executed %*lu time(s)\n",
+                            addr_len, bucket->src_addr,
+                            addr_len, bucket->dst_addr,
                             cnt_len, bucket->count);
                  }
             }
-  
+
           fprintf (file, "\n");
 
         }
@@ -2003,14 +2010,14 @@ __bb_init_prg (void)
 	buf[i--] = '\0';
 
       p = buf;
-      if (*p == '-') 
-        { 
-          m = TRACE_OFF; 
-          p++; 
+      if (*p == '-')
+        {
+          m = TRACE_OFF;
+          p++;
         }
-      else 
-        { 
-          m = TRACE_ON; 
+      else
+        {
+          m = TRACE_ON;
         }
       if (!strcmp (p, "__bb_trace__"))
         bb_mode |= 1;
@@ -2020,7 +2027,7 @@ __bb_init_prg (void)
         bb_mode |= 4;
       else if (!strcmp (p, "__bb_showret__"))
         bb_mode |= 8;
-      else 
+      else
         {
           struct bb_func *f = (struct bb_func *) malloc (sizeof (struct bb_func));
           if (f)
@@ -2055,7 +2062,7 @@ __bb_init_prg (void)
     }
   fclose (file);
 
-#ifdef HAVE_POPEN 
+#ifdef HAVE_POPEN
 
   if (bb_mode & 1)
       bb_tracefile = gopen ("bbtrace.gz", "w");
@@ -2069,7 +2076,7 @@ __bb_init_prg (void)
 
   if (bb_mode & 2)
     {
-      bb_hashbuckets = (struct bb_edge **) 
+      bb_hashbuckets = (struct bb_edge **)
                    malloc (BB_BUCKETS * sizeof (struct bb_edge *));
       if (bb_hashbuckets)
 	/* Use a loop here rather than calling bzero to avoid having to
@@ -2116,7 +2123,7 @@ __bb_trace_func (void)
 	= & bb_hashbuckets[ (((int) bb_src*8) ^ (int) bb_dst) % BB_BUCKETS ];
       bucket = *startbucket;
 
-      for (bucket = *startbucket; bucket; 
+      for (bucket = *startbucket; bucket;
            oldnext = &(bucket->next), bucket = *oldnext)
         {
           if (bucket->src_addr == bb_src
@@ -2179,7 +2186,7 @@ __bb_trace_func_ret (void)
 	= & bb_hashbuckets[ (((int) bb_dst * 8) ^ (int) bb_src) % BB_BUCKETS ];
       bucket = *startbucket;
 
-      for (bucket = *startbucket; bucket; 
+      for (bucket = *startbucket; bucket;
            oldnext = &(bucket->next), bucket = *oldnext)
         {
           if (bucket->src_addr == bb_dst
@@ -2293,9 +2300,9 @@ __bb_init_trace_func (struct bb *blocks, unsigned long blockno)
   MACHINE_STATE_SAVE("3")
 
   if (!blocks->zero_word)
-    { 
+    {
       if (!trace_init)
-        { 
+        {
           trace_init = 1;
           __bb_init_prg ();
         }
@@ -2362,7 +2369,7 @@ void
 __clear_cache (char *beg __attribute__((__unused__)),
 	       char *end __attribute__((__unused__)))
 {
-#ifdef CLEAR_INSN_CACHE 
+#ifdef CLEAR_INSN_CACHE
   CLEAR_INSN_CACHE (beg, end);
 #else
 #ifdef INSN_CACHE_SIZE
@@ -2426,7 +2433,7 @@ __clear_cache (char *beg __attribute__((__unused__)),
   /* Compute the cache alignment of the place to stop clearing.  */
 #if 0  /* This is not needed for gcc's purposes.  */
   /* If the block to clear is bigger than a cache plane,
-     we clear the entire cache, and OFFSET is already correct.  */ 
+     we clear the entire cache, and OFFSET is already correct.  */
   if (end < beg + INSN_CACHE_PLANE_SIZE)
 #endif
     offset = (((int) (end + INSN_CACHE_LINE_WIDTH - 1)
@@ -2514,8 +2521,8 @@ mprotect (char *addr, int len, int prot)
 
 #endif /* WINNT && ! __CYGWIN__ && ! _UWIN */
 
-#ifdef TRANSFER_FROM_TRAMPOLINE 
-TRANSFER_FROM_TRAMPOLINE 
+#ifdef TRANSFER_FROM_TRAMPOLINE
+TRANSFER_FROM_TRAMPOLINE
 #endif
 
 #if defined (NeXT) && defined (__MACH__)
@@ -2550,7 +2557,7 @@ __enable_execute_stack (char *addr)
 #else
   __clear_cache ((int) addr, (int) eaddr);
 #endif
-} 
+}
 
 #endif /* defined (NeXT) && defined (__MACH__) */
 
@@ -2596,7 +2603,7 @@ __enable_execute_stack (void)
   int save_errno;
   static unsigned long lowest = USRSTACK;
   unsigned long current = (unsigned long) &save_errno & -NBPC;
-  
+
   /* Ignore errno being set. memctl sets errno to EINVAL whenever the
      address is seen as 'negative'. That is the case with the stack.   */
 
@@ -2650,7 +2657,7 @@ __clear_insn_cache (void)
   errno changing without explicitly calling any system-call. */
   save_errno = errno;
 
-  /* Keep it simple : memctl (MCT_TEXT) always fully clears the insn cache. 
+  /* Keep it simple : memctl (MCT_TEXT) always fully clears the insn cache.
      No need to use an address derived from _start or %sp, as 0 works also. */
   memctl(0, 4096, MCT_TEXT);
   errno = save_errno;
@@ -2878,7 +2885,7 @@ atexit (func_ptr func)
 extern void _cleanup (void);
 extern void _exit (int) __attribute__ ((__noreturn__));
 
-void 
+void
 exit (int status)
 {
   if (atexit_chain)
-- 
GitLab