Skip to main content Accessibility help
×
Home
Hostname: page-component-559fc8cf4f-q7jt5 Total loading time: 0.94 Render date: 2021-02-25T19:25:30.714Z Has data issue: true Feature Flags: { "shouldUseShareProductTool": true, "shouldUseHypothesis": true, "isUnsiloEnabled": true, "metricsAbstractViews": false, "figures": false, "newCiteModal": false, "newCitedByModal": true }

Promoting rewriting to a programming language: a compiler for non-deterministic rewrite programs in associative-commutative theories

Published online by Cambridge University Press:  12 April 2001

HÉLÈNE KIRCHNER
Affiliation:
LORIA-CNRS & INRIA, BP 239 54506 Vandœuvre-lès-Nancy Cedex, France (e-mail: Helene.Kirchner@loria.fr, moreau@loria.fr)
PIERRE-ETIENNE MOREAU
Affiliation:
LORIA-CNRS & INRIA, BP 239 54506 Vandœuvre-lès-Nancy Cedex, France (e-mail: Helene.Kirchner@loria.fr, moreau@loria.fr)

Abstract

First-order languages based on rewrite rules share many features with functional languages, but one difference is that matching and rewriting can be made much more expressive and powerful by incorporating some built-in equational theories. To provide reasonable programming environments, compilation techniques for such languages based on rewriting have to be designed. This is the topic addressed in this paper. The proposed techniques are independent from the rewriting language, and may be useful to build a compiler for any system using rewriting modulo Associative and Commutative (AC) theories. An algorithm for many-to-one AC matching is presented, that works efficiently for a restricted class of patterns. Other patterns are transformed to fit into this class. A refined data structure, namely compact bipartite graph, allows encoding of all matching problems relative to a set of rewrite rules. A few optimisations concerning the construction of the substitution and of the reduced term are described. We also address the problem of non-determinism related to AC rewriting, and show how to handle it through the concept of strategies. We explain how an analysis of the determinism can be performed at compile time, and we illustrate the benefits of this analysis for the performance of the compiled evaluation process. Then we briefly introduce the ELAN system and its compiler, in order to give some experimental results and comparisons with other languages or rewrite engines.

Type
Research Article
Copyright
© 2001 Cambridge University Press

Access options

Get access to the full version of this content by using one of the access options below.
Submit a response

Discussions

No Discussions have been published for this article.

Full text views

Full text views reflects PDF downloads, PDFs sent to Google Drive, Dropbox and Kindle and HTML full text views.

Total number of HTML views: 0
Total number of PDF views: 36 *
View data table for this chart

* Views captured on Cambridge Core between September 2016 - 25th February 2021. This data will be updated every 24 hours.

Send article to Kindle

To send this article to your Kindle, first ensure no-reply@cambridge.org is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about sending to your Kindle. Find out more about sending to your Kindle.

Note you can select to send to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be sent to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

Promoting rewriting to a programming language: a compiler for non-deterministic rewrite programs in associative-commutative theories
Available formats
×

Send article to Dropbox

To send this article to your Dropbox account, please select one or more formats and confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your <service> account. Find out more about sending content to Dropbox.

Promoting rewriting to a programming language: a compiler for non-deterministic rewrite programs in associative-commutative theories
Available formats
×

Send article to Google Drive

To send this article to your Google Drive account, please select one or more formats and confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your <service> account. Find out more about sending content to Google Drive.

Promoting rewriting to a programming language: a compiler for non-deterministic rewrite programs in associative-commutative theories
Available formats
×
×

Reply to: Submit a response


Your details


Conflicting interests

Do you have any conflicting interests? *