Back to Search Start Over

An Efficient Composition of Bidirectional Programs by Memoization and Lazy Update

Authors :
Zhenjiang Hu
Robert Glück
Bach Nguyen Trong
Kanae Tsushima
Source :
Functional and Logic Programming ISBN: 9783030590246, FLOPS
Publication Year :
2020
Publisher :
Springer International Publishing, 2020.

Abstract

Bidirectional transformations (BX) are a solution to the view update problem and widely used for synchronizing data. The semantics and correctness of bidirectional programs have been investigated intensively during the past years, but their efficiency and optimization are not yet fully understood. In this paper, as a first step, we study different evaluation methods to optimize their evaluation. We focus on the interpretive evaluation of BX compositions because we found that these compositions are an important cause of redundant computations if the compositions are not right associative. For evaluating BX compositions efficiently, we investigate two memoization methods. The first method, minBiGUL\(_m\), uses memoization, which improves the runtime of many BX programs by keeping intermediate results for later reuse. A disadvantage is the familiar tradeoff for keeping and searching values in a table. When inputs become large, the overhead increases and the effectiveness decreases. To deal with large inputs, we introduce the second method, xpg, that uses tupling, lazy update and lazy evaluation as optimizations. Lazy updates delay updates in closures and enables them to use them later. Both evaluation methods were fully implemented for minBiGUL. The experimental results show that our methods are faster than the original method of BiGUL for the non-right associative compositions.

Details

ISBN :
978-3-030-59024-6
ISBNs :
9783030590246
Database :
OpenAIRE
Journal :
Functional and Logic Programming ISBN: 9783030590246, FLOPS
Accession number :
edsair.doi...........c01566699734b293723e77ec6b66bc45
Full Text :
https://doi.org/10.1007/978-3-030-59025-3_10