X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scm%2Fmemory-trace.scm;h=345d1327f0f47f4ca4cdebe350b577f2fa077172;hb=c924aab690820bb69bec043608b4a7b46023bafb;hp=9da1c30eda14a24963163f0bb24c694787ccc79a;hpb=aefdac39be0a80af1e08e7994b88eab4afc8da04;p=lilypond.git diff --git a/scm/memory-trace.scm b/scm/memory-trace.scm index 9da1c30eda..345d1327f0 100644 --- a/scm/memory-trace.scm +++ b/scm/memory-trace.scm @@ -34,7 +34,7 @@ (if (eq? (current-thread) trace-thread) #t ;; do nothing. (let* - ((cells (cdr (assoc 'total-cells-allocated (gc-stats)))) + ((cells (assoc-get 'total-cells-allocated (gc-stats))) (proc (arg-procedure args)) (time (tms:utime (times))) (stack (extract-trace continuation))) @@ -67,7 +67,7 @@ (set! trace-points '()) (set! continue-tracing #t) (set! trace-count 0) - (set! start-memory (cdr (assoc 'total-cells-allocated (gc-stats)))) + (set! start-memory (assoc-get 'total-cells-allocated (gc-stats))) (set! start-time (tms:utime (times))) (install-tracepoint)) @@ -100,10 +100,10 @@ (for-each (lambda (r) (let* - ((mem (- (cdr (assoc 'cells r)) start-memory)) - (proc (cdr (assoc 'proc r))) - (stack (cdr (assoc 'stack r))) - (time (- (cdr (assoc 'time r)) start-time))) + ((mem (- (assoc-get 'cells r) start-memory)) + (proc (assoc-get 'proc r)) + (stack (assoc-get 'stack r)) + (time (- (assoc-get 'time r) start-time))) (format graph-out "~a ~a\n" time mem) (if stack @@ -113,7 +113,7 @@ (- mem last-mem) proc) (do ((j 0 (1+ j)) - (stack (cdr (assoc 'stack r)) stack)) + (stack (assoc-get 'stack r) stack)) ((>= j (vector-length stack))) (format stacks-out "\t~a\n"