aboutsummaryrefslogtreecommitdiff
path: root/gcc/sched-vis.c
diff options
context:
space:
mode:
authorGraham Stott <grahams@redhat.com>2001-08-09 13:32:57 +0000
committerGraham Stott <grahams@gcc.gnu.org>2001-08-09 13:32:57 +0000
commitb1b6b0cb9c651d78f260abb00b2b60cad32527fb (patch)
tree64e38a2c3b0b34101c4af023c3cec5fed41639ee /gcc/sched-vis.c
parenta4e11a5c69afda7c977793e952e6bbd4210735f1 (diff)
downloadgcc-b1b6b0cb9c651d78f260abb00b2b60cad32527fb.zip
gcc-b1b6b0cb9c651d78f260abb00b2b60cad32527fb.tar.gz
gcc-b1b6b0cb9c651d78f260abb00b2b60cad32527fb.tar.bz2
sched-vis.c (MAX_VISUAL_NO_UNIT): Define.
* sched-vis.c (MAX_VISUAL_NO_UNIT): Define. (vis_no_unit): Use it. (visualize_no_unit): Add the insn only if room exists. From-SVN: r44739
Diffstat (limited to 'gcc/sched-vis.c')
-rw-r--r--gcc/sched-vis.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/gcc/sched-vis.c b/gcc/sched-vis.c
index 4aad9f9..ecd6fbd 100644
--- a/gcc/sched-vis.c
+++ b/gcc/sched-vis.c
@@ -87,7 +87,8 @@ int n_visual_lines;
static unsigned visual_tbl_line_length;
char *visual_tbl;
int n_vis_no_unit;
-rtx vis_no_unit[10];
+#define MAX_VISUAL_NO_UNIT 20
+rtx vis_no_unit[MAX_VISUAL_NO_UNIT];
/* Finds units that are in use in this fuction. Required only
for visualization. */
@@ -844,8 +845,11 @@ void
visualize_no_unit (insn)
rtx insn;
{
- vis_no_unit[n_vis_no_unit] = insn;
- n_vis_no_unit++;
+ if (n_vis_no_unit < MAX_VISUAL_NO_UNIT)
+ {
+ vis_no_unit[n_vis_no_unit] = insn;
+ n_vis_no_unit++;
+ }
}
/* Print insns scheduled in clock, for visualization. */