/* hist.c - Histogram related operations.
- Copyright 1999, 2000, 2001, 2002, 2004, 2005
+ Copyright 1999, 2000, 2001, 2002, 2004, 2005, 2007
Free Software Foundation, Inc.
This file is part of GNU Binutils.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
+ the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
for (sym = symtab.base; sym < symtab.limit; sym++)
{
- sym->hist.scaled_addr = sym->addr / sizeof (UNIT);
-
histogram *r = find_histogram_for_pc (sym->addr);
+ sym->hist.scaled_addr = sym->addr / sizeof (UNIT);
+
if (r)
{
bin_of_entry = (sym->hist.scaled_addr - r->lowpc) / hist_scale;
if (bsd_style_output)
{
printf (_("\ngranularity: each sample hit covers %ld byte(s)"),
- (long) hist_scale * sizeof (UNIT));
+ (long) hist_scale * (long) sizeof (UNIT));
if (total_time > 0.0)
{
printf (_(" for %.2f%% of %.2f %s\n\n"),