Term Rewriting with Sharing and Memoïzation
نویسنده
چکیده
Jungle evaluation is an approach to deene term rewriting with sharing based on graph grammars. This approach preserves important properties of term rewriting like termination, and connuence for terminating systems (under mild restrictions). In this paper, term rewriting with sharing is further accelerated, by memo zation known from functional programming languages: The result of evaluating a function with some arguments is tabulated so that it can be looked up later on when the function is reapplied to the same arguments. We show that term rewriting with sharing and memo zation is correct and complete w.r.t. jungle evaluation if the rules are non-overlapping and non-looping. Redundant re-evaluation of functions is avoided, independent of a particular strategy for applying evaluation rules.
منابع مشابه
Axiomatic Sharing-via-Labelling
A judicious use of labelled terms makes it possible to bring together the simplicity of term rewriting and the sharing power of graph rewriting: this has been known for twenty years in the particular case of orthogonal first-order systems. The present paper introduces a concise and easily usable axiomatic presentation of sharing-via-labelling techniques that applies to higher-order term rewriti...
متن کاملA Trully Concurrent Semantics for the K Framework Based on Graph Transformations
This paper gives a truly concurrent semantics with sharing of resources for the K semantic framework, an executable (term-)rewritingbased formalism for defining programming languages and calculi. Akin to graph rewriting rules, the K (rewrite) rules explicitly state what can be concurrently shared with other rules. The desired true concurrency is obtained by translating the K rules into a novel ...
متن کاملModular Properties of Constructor-Sharing Conditional Term Rewriting Systems
First, using a recent modularity result Ohl94b] for unconditional term rewriting systems (TRSs), it is shown that semi-completeness is a modular property of constructor-sharing join conditional term rewriting systems (CTRSs). Second, we do not only extend results of Middeldorp Mid93] on the modularity of termination for disjoint CTRSs to constructor-sharing systems but also simplify the proofs ...
متن کاملComplexity of Acyclic Term Graph Rewriting
Term rewriting has been used as a formal model to reason about the complexity of logic, functional, and imperative programs. In contrast to term rewriting, term graph rewriting permits sharing of common sub-expressions, and consequently is able to capture more closely reasonable implementations of rule based languages. However, the automated complexity analysis of term graph rewriting has recei...
متن کاملInfinitary Term Graph Rewriting
Term graph rewriting provides a formalism for implementing term rewriting in an efficient manner by avoiding duplication. Infinitary term rewriting has been introduced to study infinite term reduction sequences. Such infinite reductions can be used to reason about lazy evaluation. In this paper, we combine term graph rewriting and infinitary term rewriting thereby addressing both components of ...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 1992