## A Calculus for Boxing Analysis of Polymorphically Typed Languages (1996)

Citations: | 1 - 0 self |

### BibTeX

@MISC{Jørgensen96acalculus,

author = {Jesper Jørgensen},

title = {A Calculus for Boxing Analysis of Polymorphically Typed Languages},

year = {1996}

}

### OpenURL

### Abstract

An important decision when implementing languages with polymorphic types, such as Standard ML or Haskell, is whether to represent data in boxed or unboxed form and when to transform them from one representation to the other. Using a language with explicit representation types and boxing/unboxing operations we axiomatize equationally the set of all explicitly boxed versions, called completions , of a given source program. In a two-stage process we give some of the equations a rewriting interpretation that captures eliminating boxing/unboxing operations without relying on a specific implementation or even the semantics of the underlying language. The resulting reduction systems operate on equivalence classes of completions defined by the remaining equations E, which can be understood as moving boxing/unboxing operations along data flow paths in the source program. We call a completion e opt formally optimal if every other completion for the same program (and at the same representation ty...