aboutsummaryrefslogtreecommitdiff
path: root/gprof/symtab.h
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1998-08-12 19:06:24 +0000
committerIan Lance Taylor <ian@airs.com>1998-08-12 19:06:24 +0000
commit8c73afb3537b7271772a31466ec614a4d0634436 (patch)
tree639323c1b8888bf5fe9abcccb505211b1d56383b /gprof/symtab.h
parent15ec5eb33b983e2900205cffd919cca52f8e1394 (diff)
downloadgdb-8c73afb3537b7271772a31466ec614a4d0634436.zip
gdb-8c73afb3537b7271772a31466ec614a4d0634436.tar.gz
gdb-8c73afb3537b7271772a31466ec614a4d0634436.tar.bz2
Avoid some overflow cases:
* basic_blocks.h (bb_min_calls): Change to unsigned long. * call_graph.h (cg_tally): Change count parameter to unsigned long. * cg_arcs.h (Arc): Change count field to unsigned long. (arc_add): Change count parameter to unsigned long. * source.h (Source_File): Change ncalls field to unsigned long. * symtab.h (Sym): Change fields ncalls, bb_calls, and cg.self_calls to unsigned long. * Many files: Update accordingly.
Diffstat (limited to 'gprof/symtab.h')
-rw-r--r--gprof/symtab.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/gprof/symtab.h b/gprof/symtab.h
index 1ffbc6e..a6a450e 100644
--- a/gprof/symtab.h
+++ b/gprof/symtab.h
@@ -41,11 +41,11 @@ typedef struct sym
is_bb_head:1, /* is this the head of a basic-blk? */
mapped:1, /* this symbol was mapped to another name */
has_been_placed:1; /* have we placed this symbol? */
- int ncalls; /* how many times executed */
+ unsigned long ncalls; /* how many times executed */
int nuses; /* how many times this symbol appears in
a particular context */
bfd_vma bb_addr[NBBS]; /* address of basic-block start */
- int bb_calls[NBBS]; /* how many times basic-block was called */
+ unsigned long bb_calls[NBBS]; /* how many times basic-block was called */
struct sym *next; /* for building chains of syms */
struct sym *prev; /* for building chains of syms */
@@ -62,7 +62,7 @@ typedef struct sym
/* call-graph specific info: */
struct
{
- int self_calls; /* how many calls to self */
+ unsigned long self_calls; /* how many calls to self */
double child_time; /* cumulative ticks in children */
int index; /* index in the graph list */
int top_order; /* graph call chain top-sort order */