login

Mobile Haskell: Compiling lazy functional programs for the Java Virtual Machine

Lecture notes in computer sciencePublished 1 January 1998
David Wakeling
Citations9
SJR quartileQ2
SJR score0.35
SNIP0.55

TL;DR

This paper shows how lazy functional programs can be made mobile by compiling them for the Java Virtual Machine by using the Haskell compiler based on the 〈Ν,G〉-machine, which is designed for implementing lazy functional languages on parallel processors.

Abstract

This paper shows how lazy functional programs can be made mobile by compiling them for the Java Virtual Machine. The Haskell compiler it describes is based on the 〈Ν,G〉-machine, which is designed for implementing lazy functional languages on parallel processors. Although this is not the obvious thing to do, it leads to a particularly elegant set of translation rules. Sadly though, the speed of the resulting Java Virtual Machine code programs is disappointing due to the surprisingly high cost of memory allocation/reclamation in current implementations of the Java Virtual Machine. In future work, we intend to find out whether this high cost is a property of the Java Virtual Machine's design or its implementation.

Keywords

Computer Science