Strongly typed flow-directed representation transformations (extended abstract)

  • Authors:
  • Allyn Dimock;Robert Muller;Franklyn Turbak;J. B. Wells

  • Affiliations:
  • Harvard University;Boston College;Wellesley College;Glasgow University

  • Venue:
  • ICFP '97 Proceedings of the second ACM SIGPLAN international conference on Functional programming
  • Year:
  • 1997

Quantified Score

Hi-index 0.00

Visualization

Abstract

We present a new framework for transforming data representations in a strongly typed intermediate language. Our method allows both value producers (sources) and value consumers (sinks) to support multiple representations, automatically inserting any required code. Specialized representations can be easily chosen for particular source/sink pairs.The framework is based on these techniques:1. Flow annotated types encode the "flows-from" (source) and "flows-to" (sink) information of a flow graph.2. Intersection and union types support (a) encoding precise flow information, (b) separating flow information so that transformations can be well typed, (c) automatically reorganizing flow paths to enable multiple representations.As an instance of our framework, we provide a function representation transformation that encompasses both closure conversion and inlining. Our framework is adaptable to data other than functions.