TY - JOUR
T1 - More efficient bottom-up multi-pattern matching in trees
AU - Cai, J.
AU - Paige, R.
AU - Tarjan, R.
N1 - Funding Information:
* An earlier version of this paper appeared in [6]. ** The research of this author was partially supported by National Science Foundation grant CCR-9002428. *** Part of this work was done while this author was a summer faculty member at IBM T. J. Watson Research Center. The research of this author was partially supported by Office of Naval Research grant NOO014-90-J-1890. + The research of this author at Princeton University was partially supported by DIMACS (Center for Discrete Mathematics and Theoretical Computer Science), a National Science Foundation Science and Technology Center, grant NSF-STC88-09648 and by the Office of Naval Research contract N00014-87-K-0467.
PY - 1992/11/30
Y1 - 1992/11/30
N2 - Pattern matching in trees is fundamental to a variety of programming language systems. However, progress has been slow in satisfying a pressing need for general-purpose pattern-matching algorithms that are efficient in both time and space. We offer asymptotic improvements in both time and space to Chase's bottom-up algorithm for pattern preprocessing. A preliminary implementation of our algorithm runs ten times faster than Chase's (1987) implementation on the hardest problem instances. Our preprocessing algorithm has the advantage of being on-line with respect to pattern additions and deletions. It also adapts to favorable input instances, and on Hoffmann and O'Donnell's (1982) class of simple patterns, it performs better than their special-purpose algorithm tailored to this class. We show how to modify our algorithm using a new decomposition method to obtain a space/time tradeoff. Finally, we trade a log factor in time for a linear space bottom-up pattern-matching algorithm that handles a wide subclass of Hoffmann and O'Donnell's (1982) simple patterns.
AB - Pattern matching in trees is fundamental to a variety of programming language systems. However, progress has been slow in satisfying a pressing need for general-purpose pattern-matching algorithms that are efficient in both time and space. We offer asymptotic improvements in both time and space to Chase's bottom-up algorithm for pattern preprocessing. A preliminary implementation of our algorithm runs ten times faster than Chase's (1987) implementation on the hardest problem instances. Our preprocessing algorithm has the advantage of being on-line with respect to pattern additions and deletions. It also adapts to favorable input instances, and on Hoffmann and O'Donnell's (1982) class of simple patterns, it performs better than their special-purpose algorithm tailored to this class. We show how to modify our algorithm using a new decomposition method to obtain a space/time tradeoff. Finally, we trade a log factor in time for a linear space bottom-up pattern-matching algorithm that handles a wide subclass of Hoffmann and O'Donnell's (1982) simple patterns.
UR - http://www.scopus.com/inward/record.url?scp=0026946172&partnerID=8YFLogxK
UR - http://www.scopus.com/inward/citedby.url?scp=0026946172&partnerID=8YFLogxK
U2 - 10.1016/0304-3975(92)90277-M
DO - 10.1016/0304-3975(92)90277-M
M3 - Article
AN - SCOPUS:0026946172
SN - 0304-3975
VL - 106
SP - 21
EP - 60
JO - Theoretical Computer Science
JF - Theoretical Computer Science
IS - 1
ER -