Type- and Flow-Directed Compilation for Specialized Data Representations (2002)
BibTeX
@MISC{Dimock02type-and,
author = {Allyn Dimock},
title = {Type- and Flow-Directed Compilation for Specialized Data Representations},
year = {2002}
}
OpenURL
Abstract
The combination of intersection and union types with ow types gives the compiler writer unprecedented exibility in choosing data representations in the context of a typed intermediate language. We present the design of such a language and the design of a framework for exploiting the type system to support multiple representations of the same data type in a single program. The framework can transform the input term, in a type-safe way, so that dierent data representations can be used in the transformed term | even if they share a use site in the pre-transformed term. We have implemented a compiler using the typed intermediate language and instantiated the framework to allow specialized function representations. We test the compiler on a set of benchmarks and show that the compile-time performance is reasonable. We further show that the compiled code does indeed bene t from specialized function representations.







