[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
I'm writing a profiler for Lisp programs and am trying to understand
what time information is available to the programmer in 4.1 final.
(Yes, I know about the fancy profiler under composer, but it isn't what
I want for my application.)
I've been using EXCL::GET-INTERNAL-RUN-TIMES, which returns 4 different
numbers. First, is this function documented anywhere? I can't find a
reference to it in the manuals.
Second, I have inferred intuitive meanings for the four values as
USER-TOTAL (total ticks in the user's process)
SYS-TOTAL (ticks in "system" code on behalf of user's process)
USER-GC (total "user" ticks in GC in this process)
SYS-GC (ticks in "system" code on behalf of gc in this process)
I believe that USER-TOTAL contains USER-GC, and SYS-TOTAL contains SYS-GC
but I'm not sure. Is this true? Also, it would appear that
USER-TOTAL and SYS-TOTAL are disjoint, while USER-GC and SYS-GC are also.
Is this also true?
Another question is: for each of the following types of event where do
its ticks get charged?
-- Waiting for a page fault, both within GC and without
-- Waiting for user i/o? Even when a different process gets to execute?
-- Any portions of context switching due to asynchronous interrupts?
-- Memory allocation (e.g. requesting page(s) from the )?
Have I left out any other sources of non-determinism in timing?
If I measure only (USER-TOTAL - USER-GC), should I get a repeatable value?
This could only be true if all the event types above are not charged to
the USER-TOTAL portion. That is, since system stuff and gc
is not included, running the same code on the same input should take exactly
(up to tick-coarseness problems) the same time.
Any help would be appreciated.
-- Bob Hall
p.s. I'm running Allegro CL v4.1 final on a SparcStation 2 under SunOS 4.1