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

&Rest Lists



In order to clarify the importance of optimized handling of &Rest
arguments, compared to the importance of specifying their semantics more
precisely I have collected some statistics.  The functions used to
collect these are included at the end of this message.  I encourage
others to use these functions to obtain measurements of their own
code.

Using APROPOS it is possible to measure how many functions take &Rest
arguments.  On an Explorer I got the following results:

PACKAGE	  with &Rest  Without Percent
------------------------------------
LISP        70           580    10.7
SI          73          3384     2.1
ZWEI        66          2324     2.7
TV          79          1177     6.2
FS          54           707     7.0
FORMAT      11           105     9.4
------------------------------------
Subtotal   283          7697     3.5

KEE        234          5120     4.3    (IntelliCorp's package)
------------------------------------
Total      517         12817     3.8

Unfortunately, since calls to APPLY are optimized they cannot be
analyzed with WHO-CALLS.  Instead I searched the source code of the NIL
compiler for lines containing the strings "(APPLY" and "&REST".  These
include comment lines, and parsing of argument lists.  (The paren in
"(APPLY" eliminates some of that.)