Tail recursion without space leaks

23Citations
Citations of this article
21Readers
Mendeley users who have this article in their library.

Abstract

The G-machine (Johnsson, 1987; Peyton Jones, 1987) is a compiled graph reduction machine for lazy functional languages. The G-machine compiler contains many optimizations to improve performance. One set of such optimizations is designed to improve the performance of tail recursive functions. Unfortunately, the abstract machine is subject to a space leak—objects are unnecessarily preserved by the garbage collector. This paper analyses why a particular form of space leak occurs in the G-machine, and presents some ideas for fixing this problem. This phenomena in other abstract machines is also examined briefly. © 1992, Cambridge University Press. All rights reserved.

Cite

CITATION STYLE

APA

Jones, R. (1992). Tail recursion without space leaks. Journal of Functional Programming, 2(1), 73–79. https://doi.org/10.1017/S0956796800000277

Register to see more suggestions

Mendeley helps you to discover research relevant for your work.

Already have an account?

Save time finding and organizing research with Mendeley

Sign up for free