Control Localization in Domain Specific Translation

  • Authors:
  • Ted J. Biggerstaff

  • Affiliations:
  • -

  • Venue:
  • ICSR-7 Proceedings of the 7th International Conference on Software Reuse: Methods, Techniques, and Tools
  • Year:
  • 2002

Quantified Score

Hi-index 0.00

Visualization

Abstract

Domain specific languages (DSLs) excel at programming productivity because they provide large-grain composite data structures (e.g., a graphics image) and large-grain operators for composition (e.g., image addition or convolution). As a result, extensive computations can be written as APL-like one-liners that are equivalent to tens or hundreds of lines of code (LOC) when written in a conventional language like Java. The problem with DSL specifications is that they de-localize the code components making un-optimized machine translations significantly slower than for the human optimized equivalent. Specifically, operations on DSL composites imply multiple control structures (e.g., loops) that process the individual elements of large-grain composites and those multiple, implicit control structures are distributed (i.e., de-localized) across the expression of operators and operands. Human programmers recognize the relation among these distributed control structures and merge them to minimize the redundancy of control. For example, merged control structures may perform several operations on several large-grain data structures in a single pass. This merging is the process of control localization. This paper discusses strategies for automating localization without large search spaces and outlines a domain specific example of transformation rules for localizing control. The example is based on the localization method in the Anticipatory Optimization Generator (AOG) system [3-8].