Back to Search Start Over

Implementing an embedded compiler using program transformation rules.

Authors :
Bissyandé, Tegawendé F.
Réveillère, Laurent
Lawall, Julia L.
Bromberg, Yérom‐David 
Muller, Gilles
Source :
Software: Practice & Experience; Feb2015, Vol. 45 Issue 2, p177-196, 20p
Publication Year :
2015

Abstract

SUMMARY Domain-specific languages (DSLs) are well-recognized to ease programming and improve robustness for a specific domain, by providing high-level domain-specific notations and checks of domain-specific properties. The compiler of a DSL, however, is often difficult to develop and maintain, because of the need to define a specific treatment for a large and potentially increasing number of language constructs. To address this issue, we propose an approach for specifying a DSL compiler using control-flow sensitive concrete-syntax based matching rules. These rules either collect information about the source code to carry out checks or perform transformations to carry out compilation. Because rules only mention the relevant constructs, using their concrete syntax, and hide the complexity of control-flow graph traversal, it is easy to understand the purpose of each rule. Furthermore, new compilation steps can be added using only a small number of lines of code. We explore this approach in the context of the z2z DSL for network gateway development and show that it is beneficial to implement the core of its compiler in this manner.Copyright © 2013 John Wiley & Sons, Ltd. [ABSTRACT FROM AUTHOR]

Details

Language :
English
ISSN :
00380644
Volume :
45
Issue :
2
Database :
Complementary Index
Journal :
Software: Practice & Experience
Publication Type :
Academic Journal
Accession number :
100273716
Full Text :
https://doi.org/10.1002/spe.2225