Loading...
Please wait, while we are loading the content...
Similar Documents
A monadic approach for avoiding code duplication when staging memoized functions (2006).
| Content Provider | CiteSeerX |
|---|---|
| Author | Swadi, Kedar Taha, Walid Kiselyov, Oleg Pasalic, Emir |
| Abstract | Building program generators that do not duplicate generated code can be challenging. At the same time, code duplication can easily increase both generation time and runtime of generated programs by an exponential factor. We identify an instance of this problem that can arise when memoized functions are staged. Without addressing this problem, it would be impossible to effectively stage dynamic programming algorithms. Intuitively, direct staging undoes the effect of memoization. To solve this problem once and for all, and for any function that uses memoization, we propose a staged monadic combinator library. Experimental results confirm that the library works as expected. Preliminary results also indicate that the library is useful even when memoization is not used. |
| File Format | |
| Publisher Date | 2006-01-01 |
| Access Restriction | Open |
| Subject Keyword | Memoized Function Avoiding Code Duplication Monadic Approach Generated Code Dynamic Programming Algorithm Preliminary Result Library Work Exponential Factor Program Generator Direct Staging Experimental Result Code Duplication Generation Time Staged Monadic Combinator Library |
| Content Type | Text |