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

metering.lisp



I have obtained a file entitled "metering.lisp" via anonymous ftp from
CMU.  It contains lisp functions for execution profiling of other lisp
code.  It can track the time spent inside a function (using
get-internal-run-time) and the amount of memory used.  The latter is
a problem since I know no MACL routine which is memory's equivalent
of get-internal-run-time, that is, a "get-memory-used" routine.  I know
about (room) which prints memory usage statistics and returns nil.
What I want is a room which returns the memory usage stats rather than
printing them.

Another lisp-implementation dependent detail of this profiler is that
it determines the number of required arguments to a function and if
that same function takes any optional requirements.  This information
reduces the amount of consing done by the profiler "encapsulation" code,
that is, the code that is placed around a monitored function.  I know
Franz ACL has a routine (excl:arglist) that does what I need.  Is there
a similar routine in MACL.

I have read through my MACL binder but have found nothing that answers
my questions.  So I am turning to the MACL community to see if any knows
of any solutions to this problem.  If I am able to resolve the above
issues satisfactorially, I will send the MACL implementation of
metering.lisp to CMU where it will be incorporated with the anonymous
ftp version and available to everyone.

By-the-bye, what I meant by satisfactory resolution is that the
"get-memory-usage" routine must work quickly since it is executed every
time a monitored function is called.  The longer this routine runs, the
less accurate the profiling is and, hence, the less useful the
profile.

| Chuck Rapp    | If you're Bell Labs employees, then where are your |
| BALR, Inc.    | badges?  Badges?  Badges?!  We have no badges.  We |
| rapp@balr.com | don't need no stinking badges!                     |
+---------------+----------------------------------------------------+