Skip to main content

An efficient parallel algorithm for term matching

  • Session 8 Parallel Algorithms
  • Conference paper
  • First Online:
Foundations of Software Technology and Theoretical Computer Science (FSTTCS 1986)

Abstract

Term matching is a compute-intensive problem that often arises in symbolic manipulation systems like term rewriting, and in functional and equational programming. A parallel algorithm for term matching on the CREW PRAM model was recently described by Dwork, Kanellakis and Stockmeyer. This algorithm requires O(n 2) processors and takes either O(logn) or O(log2 n) time. In this paper we describe a new parallel algorithm that performs term matching in O(log2 n) time using O(n) processors. In our algorithm, we represent the two terms as labeled directed trees. We then construct equivalence classes of nodes in these two trees such that two nodes are in the same class iff they have the same sequence of edge-labels on the path to their respective roots. This is the basis of our parallel algorithm for term matching.

Research supported in part by the NSF under grant number ECS-84-04399 and in part by ONR under contract N00014-84-K-0530.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

6. References

  1. C. Dwork, P. Kanellakis and J. C. Mitchell, “On The Sequential Nature Of Unification”, J. Logic Programming, 1, (1984), 35–50.

    Google Scholar 

  2. C. Dwork, P. Kanellakis and L. Stockmeyer, “Parallel Algorithms for Term Matching”, 8th Intl. Conf. on Automatic Deduction; Springer Verlag LNCS 230, July 1986, 416–430.

    Google Scholar 

  3. S. Fortune and J. Wyllie, “Parallelism In Random Access Machines”, Proc 10th ACM Annual ACM Symp. on Theory of Computing, 1978, 114–118.

    Google Scholar 

  4. D. S. Hirschberg, “Fast Parallel Sorting Algorithms”, Comm. ACM, 21, 8 (Aug. 1978), 657–661.

    Google Scholar 

  5. J. Maluszynski and H. J. Komorowski, “Unifcation-free Execution Of Logic Programs”, Symposium on Logic Programming, July 1985, 78–86.

    Google Scholar 

  6. M. S. Paterson and M. N. Wegman, “Linear Unification”, J. Computer and System Sciences, 16, (1978), 158–167.

    Google Scholar 

  7. J. A. Robinson, “A Machine Oriented Logic Based On The Resolution Principle”, J. ACM, 12, (1965), 23–41.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Kesav V. Nori

Rights and permissions

Reprints and permissions

Copyright information

© 1986 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Verma, R.M., Krishnaprasad, T., Ramakrishnan, I.V. (1986). An efficient parallel algorithm for term matching. In: Nori, K.V. (eds) Foundations of Software Technology and Theoretical Computer Science. FSTTCS 1986. Lecture Notes in Computer Science, vol 241. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-17179-7_31

Download citation

  • DOI: https://doi.org/10.1007/3-540-17179-7_31

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-17179-9

  • Online ISBN: 978-3-540-47239-1

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics