Simulating TRSs by minimal TRSs : a simple, efficient, and correct compilation technique

A simple, efficient, and correct compilation technique for left-linear Term Rewriting Systems (TRSs) is presented. TRSs are compiled into Minimal Term Rewriting Systems (MTRSs), a subclass of TRSs, presented in [KW95d]. In MTRSs, the rules have such a simple form that they can be seen as instructions for an easily implementable abstract machine, the Abstract Rewriting Machine (ARM). In the correctness proof, it is shown that the MTRS resulting from compilation of a TRS simulates neither too much (soundness) nor too little (completeness), nor does it introduce unwarranted infinite sequences (termination conservation). The compiler and its correctness proof are largely independent of the reduction strategy.

[1]  Rafael Dueire Lins,et al.  Benchmarking implementations of functional languages with ‘Pseudoknot’, a float-intensive benchmark , 1996, Journal of Functional Programming.

[2]  Jan Willem Klop,et al.  Term Rewriting Systems: From Church-Rosser to Knuth-Bendix and Beyond , 1990, ICALP.

[3]  Mikael Pettersson,et al.  A Term Pattern-Match Compiler Inspired by Finite Automata Theory , 1992, CC.

[4]  Alfred V. Aho,et al.  Compilers: Principles, Techniques, and Tools , 1986, Addison-Wesley series in computer science / World student series edition.

[5]  H. R. Walters,et al.  Minimal Term Rewriting Systems , 1995, COMPASS/ADT.

[6]  Jan A. Bergstra,et al.  Term-Rewriting Systems with Rule Priorities , 1989, Theor. Comput. Sci..

[7]  Jean-Pierre Jouannaud,et al.  Rewrite Systems , 1991, Handbook of Theoretical Computer Science, Volume B: Formal Models and Sematics.

[8]  Joseph A. Goguen,et al.  Towards a Provably Correct Compiler for OBJ3 , 1994, PLILP.

[9]  H. R. Walters On Equal Terms. Implementing Algebraic Specifications , 1991 .

[10]  H. R. Walters,et al.  Lazy Rewriting and Eager Machinery , 1995, RTA.

[11]  Christoph M. Hoffmann,et al.  Pattern Matching in Trees , 1982, JACM.