x86: de-duplicate sub-architecture strings accumulation
[binutils-gdb.git] / gprof / hist.c
index d81ca269c494db882686719b705eabf11764c45e..91a0d32a7a1bba9aea5aab3e0882bc6240757980 100644 (file)
@@ -1,6 +1,6 @@
 /* hist.c  -  Histogram related operations.
 
-   Copyright (C) 1999-2016 Free Software Foundation, Inc.
+   Copyright (C) 1999-2022 Free Software Foundation, Inc.
 
    This file is part of GNU Binutils.
 
@@ -39,7 +39,7 @@
 static void scale_and_align_entries (void);
 static void print_header (int);
 static void print_line (Sym *, double);
-static int cmp_time (const PTR, const PTR);
+static int cmp_time (const void *, const void *);
 
 /* Declarations of automatically generated functions to output blurbs.  */
 extern void flat_blurb (FILE * fp);
@@ -289,7 +289,7 @@ hist_write_hist (FILE * ofp, const char *filename)
    next bin.  */
 
 static void
-scale_and_align_entries ()
+scale_and_align_entries (void)
 {
   Sym *sym;
   bfd_vma bin_of_entry;
@@ -445,7 +445,7 @@ hist_assign_samples_1 (histogram *r)
 
 /* Calls 'hist_assign_sampes_1' for all histogram records read so far. */
 void
-hist_assign_samples ()
+hist_assign_samples (void)
 {
   unsigned i;
 
@@ -535,7 +535,7 @@ print_line (Sym *sym, double scale)
    lexicographic order of the function names.  */
 
 static int
-cmp_time (const PTR lp, const PTR rp)
+cmp_time (const void *lp, const void *rp)
 {
   const Sym *left = *(const Sym **) lp;
   const Sym *right = *(const Sym **) rp;
@@ -562,7 +562,7 @@ cmp_time (const PTR lp, const PTR rp)
 /* Print the flat histogram profile.  */
 
 void
-hist_print ()
+hist_print (void)
 {
   Sym **time_sorted_syms, *top_dog, *sym;
   unsigned int sym_index;
@@ -571,7 +571,7 @@ hist_print ()
   bfd_vma addr;
 
   if (first_output)
-    first_output = FALSE;
+    first_output = false;
   else
     printf ("\f\n");