~ chicken-core (chicken-5) /tests/gobble.scm
Trap1;;;; gobble.scm2;3; usage: csi -s gobble.scm [COUNT]456(define (run n)7 (print "allocating " n " bytes ...")8 (let loop ((k 0))9 (when (< k n)10 (let ((x (make-string 1000)))11 (when (and (zero? (modulo k 100000)) (##sys#debug-mode?))12 (print* "."))13 (loop (+ k 1000))))))1415(run (string->number (optional (command-line-arguments) "1000000000")))16(newline)171819; time csi -s gobble.scm 100000000020; 5 secs21;22; csc goobble.scm -o a.out -O4 -b -d023; time a.out 100000000024; 3 secs25;26; (x86, Core2 Duo, 2.4Ghz, 2GB RAM)