[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: size-of instance?



>Try "time": I am not sure how the memory allocation reported compares
>to that actually used by the instance but it in my experience it has
>always seemed to be about right.
>


It *does* seem to give meaningful results. Thanks. But I was getting some
funny results, so there *is* at least one minor caveat: do the measurement
twice!

Your example came out at 4648. I got the same result the first time. The
second time it comes out 40!

I also note that changing a class causes a big hit the first time I
measure, so a second measure is needed.

So I guess the good news is #'time may serve the purpose, and the bad news
is, it (naturally) is not directly measuring the object, soo...?

Anyway, my little objects don't look too big (if the second answer is
correct!) so on I go with CLOS.

But I think I will pass on mixing in simple-view for each character (my
original concern) because of the *code* (and thus performance) overhead!

Thanks again.

To Digitool--how about a size-of function?