From 6de9cd9a886ea695aa892c3c7c07818a7b7e9e6f Mon Sep 17 00:00:00 2001 From: Diego Novillo Date: Thu, 13 May 2004 02:41:07 -0400 Subject: Merge tree-ssa-20020619-branch into mainline. From-SVN: r81764 --- gcc/et-forest.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'gcc/et-forest.c') diff --git a/gcc/et-forest.c b/gcc/et-forest.c index e65ccda..9b09971 100644 --- a/gcc/et-forest.c +++ b/gcc/et-forest.c @@ -206,9 +206,13 @@ et_check_tree_sanity (struct et_occ *occ) /* For recording the paths. */ +/* An ad-hoc constant; if the function has more blocks, this won't work, + but since it is used for debugging only, it does not matter. */ +#define MAX_NODES 100000 + static int len; -static void *datas[100000]; -static int depths[100000]; +static void *datas[MAX_NODES]; +static int depths[MAX_NODES]; /* Records the path represented by OCC, with depth incremented by DEPTH. */ @@ -228,6 +232,10 @@ record_path_before_1 (struct et_occ *occ, int depth) } fprintf (stderr, "%d (%d); ", ((basic_block) occ->of->data)->index, depth); + + if (len >= MAX_NODES) + abort (); + depths[len] = depth; datas[len] = occ->of; len++; -- cgit v1.1