aboutsummaryrefslogtreecommitdiff
path: root/gcc/varray.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/varray.c')
-rw-r--r--gcc/varray.c21
1 files changed, 12 insertions, 9 deletions
diff --git a/gcc/varray.c b/gcc/varray.c
index 9900f9e..2044629 100644
--- a/gcc/varray.c
+++ b/gcc/varray.c
@@ -246,14 +246,17 @@ dump_varray_statistics (void)
#ifdef GATHER_STATISTICS
struct output_info info;
- fprintf (stderr, "\nVARRAY Kind Count Bytes Resized copied\n");
- fprintf (stderr, "-------------------------------------------------------\n");
- info.count = 0;
- info.size = 0;
- htab_traverse (varray_hash, print_statistics, &info);
- fprintf (stderr, "-------------------------------------------------------\n");
- fprintf (stderr, "%-20s %7d %10d\n",
- "Total", info.count, info.size);
- fprintf (stderr, "-------------------------------------------------------\n");
+ if (varray_hash)
+ {
+ fprintf (stderr, "\nVARRAY Kind Count Bytes Resized copied\n");
+ fprintf (stderr, "-------------------------------------------------------\n");
+ info.count = 0;
+ info.size = 0;
+ htab_traverse (varray_hash, print_statistics, &info);
+ fprintf (stderr, "-------------------------------------------------------\n");
+ fprintf (stderr, "%-20s %7d %10d\n",
+ "Total", info.count, info.size);
+ fprintf (stderr, "-------------------------------------------------------\n");
+ }
#endif
}