From: phk@data.fls.dk (Poul-Henning Kamp)
Newsgroups: comp.sources.hp48
Subject: v02i011:  timeeval - "Stopwatch" EVAL v1.0, Part01/01
Date: 1 Oct 91 02:38:36 GMT
Followup-To: comp.sys.hp48

Checksum:  227788406 (verify with brik -cv)
Submitted-by: Poul-Henning Kamp <phk@data.fls.dk>
Posting-number: Volume 2, Issue 11
Archive-name: timeeval/part01

TIMEEVAL          Size: 77.5 bytes,  Checksum: #A2C7h
by phk@data.fls.dk 26oct91

obj -> TIMEEVAL n(ticks) x_ms

Evaluates the object on top of the stack, and returns the time it took in
ticks of the internal clock and in milli-seconds.

Arguments for <obj> can put put on the stack above it, and results from the
evaluation will be available above the results of TIMEEVAL.

example:
         +----------------------+                  +----------------------+
         |4:                    |                  |4:                    |
         |3:                    |                  |3:       .908508177527|
         |2:                65.3|                  |2:                 247|
         |1:                 SIN|  -> TIMEEVAL ->  |1:           30.151_ms|
         +----------------------+                  +----------------------+


You cannot get SIN onto the stack ?  try this: { SIN } OBJ\-> DROP

The T0 offset is (on my calc, Rev E) 31 ticks, or 3.784_ms.  This is roughly
the time it takes to evaluate a data-object like "Hello".

WARNINGS:
=========

The EVAL employed is the "kernel-one", which does not evalute inside lists.

Programs relying on a specific local-env will fail if they use 1GETLAM &c &c.

There is no ERRTRAP built in.

-- 
phk@data.fls.dk		  ||  A host is a host from coast to coast,
Poul-Henning Kamp	  ||  & no one will talk to a host that's close,
FLS DATA A/S		  ||  Unless the host (that isn't close)
Phone: (+45) 36 18 12 35  ||  is busy, hung or dead.
Fax:   (+45) 36 18 12 18  || 				Anon (?) 

