Evaluating Call-By-Need on the Control Stack
Stephen Chang, David Van Horn, Matthias Felleisen

TL;DR
This paper presents an abstract machine implementation of call-by-need evaluation using the control stack to resolve variable references, bridging theoretical calculus and practical execution models.
Contribution
It introduces a novel translation of call-by-need semantics into an abstract machine that leverages the control stack for variable resolution.
Findings
The machine accurately models call-by-need evaluation semantics.
Variable references are resolved dynamically via the control stack.
The approach bridges theoretical calculus and practical implementation.
Abstract
Ariola and Felleisen's call-by-need {\lambda}-calculus replaces a variable occurrence with its value at the last possible moment. To support this gradual notion of substitution, function applications-once established-are never discharged. In this paper we show how to translate this notion of reduction into an abstract machine that resolves variable references via the control stack. In particular, the machine uses the static address of a variable occurrence to extract its current value from the dynamic control stack.
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsLogic, programming, and type systems · Advanced Database Systems and Queries · Logic, Reasoning, and Knowledge
