Multiple Trace Composition and Its Uses
Adam Sah
Computer Science Division
Electrical Engineering and Computer Sciences
University of California, Berkeley, CA
Abstract
Traces are code attachments to variables that cause designated blocks
of code to be executed on reads or writes to the given
variable. Traces have numerous uses, including rules (\on
do" statements), autoloading and initialization based on data
access, trans- parent remote data access, paging and swapping, and
persistence. Traces are usually limited to ad-hoc, hard-coded
composition, making it difficult to place multiple traces on the same
variable. Multiple traces are useful for putting a rule on a
persistent variable, or several rules on a variable.
This paper presents a design for a low-level mechanism for reasoning
about and configuring multiple traces ona single variable. Although
the work is based on a prototype using a modified version of Tcl's
trace command, this mechanism easily applies to any language or
library capable of implementing traps. This includes systems such as
data breakpoints[WLG93] in C and overloadable get() and set() methods
in prototype-based object-oriented systems. The specifics of the
prototype are presented, including a facility for writing persistent
Tcl scripts.
Download the full text of this paper in
ASCII (34,434 bytes) and
POSTSCRIPT (102,537 bytes) form.
To Become a USENIX Member, please see our
Membership Information.