From 0c395c2bc06983e42deb5456c37299130e0cc2ad Mon Sep 17 00:00:00 2001 From: Stephen Adams Date: Wed, 2 Aug 1995 14:05:42 +0000 Subject: [PATCH] Added some statistics gathering to help figure out why dbg-reduce is slow on huge programs. --- v8/src/compiler/midend/dbgred.scm | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/v8/src/compiler/midend/dbgred.scm b/v8/src/compiler/midend/dbgred.scm index 01cf10d3e..d05d67fc9 100644 --- a/v8/src/compiler/midend/dbgred.scm +++ b/v8/src/compiler/midend/dbgred.scm @@ -1,6 +1,6 @@ #| -*-Scheme-*- -$Id: dbgred.scm,v 1.8 1995/07/21 14:28:53 adams Exp $ +$Id: dbgred.scm,v 1.9 1995/08/02 14:05:42 adams Exp $ Copyright (c) 1994-1995 Massachusetts Institute of Technology @@ -320,16 +320,18 @@ MIT in each case. |# (cond ((not entry) (vector (dbg-red/edge/make expr))) (else - (make-initialized-vector (1+ (vector-length entry)) - (lambda (i) - (if (< i (vector-length entry)) - (vector-ref entry i) - (dbg-red/edge/make expr))))))) + (vector-append entry + (vector (dbg-red/edge/make expr)))))) (if (and (not (scode-constant? key)) (not (%record? key)) (not entry)) (set! expressions (cons key expressions)))))) (cdr infos)) + (if compiler:enable-statistics? + (hash-table/for-each table + (lambda (key entry) + key + (sample/1 '(DBG-RED/OUT-DEGREE HISTOGRAM) (vector-length entry))))) (dbg-red/graph/make table expressions))) (define dbg-red/cache-sets 0) -- 2.25.1