Subject: Re: Data structure size can o' worms
From: (Rob Warnock)
Date: Sat, 14 Jun 2003 06:45:58 -0500
Newsgroups: comp.lang.lisp
Message-ID: <>
Joe Marshall  <> wrote:
| Suppose that the system has done a full GC.  Now you SETQ *foo* to NIL
| and perform another full GC.  It seems to me that the storage
| reclaimed is *exactly* the `size' of *foo*.

Careful!! Don't forget the builtin "history" variables in the REPL.
You probably want to do something like this:

	> (gc :full t)
	> (room)		; size while *foo* still holds a reference
	> (setq *foo* nil)	; zap *foo* and * and /
	> (setq *foo* nil)	; zap ** and //
	> (setq *foo* nil)	; zap *** and ///
	> (gc :full t)
	> (room)		; size after *foo* is gone

[I know you know all of this, but CL newbies (such as myself!)
sometimes overlook it when trying to do GC measurements...]


Rob Warnock, PP-ASEL-IA		<>
627 26th Avenue			<URL:>
San Mateo, CA 94403		(650)572-2607