The weak call-by-value λ-calculus is reasonable for both time and space
Yannick Forster, Fabian Kunze, Marc Roth
Abstract
We study the weak call-by-value -calculus as a model for computational complexity theory and establish the natural measures for time and space -- the number of beta-reductions and the size of the largest term in a computation -- as reasonable measures with respect to the invariance thesis of Slot and van Emde Boas [STOC 84]. More precisely, we show that, using those measures, Turing machines and the weak call-by-value -calculus can simulate each other within a polynomial overhead in time and a constant factor overhead in space for all computations that terminate in (encodings) of 'true' or 'false'. We consider this result as a solution to the long-standing open problem, explicitly posed by Accattoli [ENTCS 18], of whether the natural measures for time and space of the -calculus are reasonable, at least in case of weak call-by-value evaluation. Our proof relies on a hybrid of two simulation strategies of reductions in the weak call-by-value -calculus by Turing machines, both of which are insufficient if taken alone. The first strategy is the most naive one in the sense that a reduction sequence is simulated precisely as given by the reduction rules; in particular, all substitutions are executed immediately. This simulation runs within a constant overhead in space, but the overhead in time might be exponential. The second strategy is heap-based and relies on structure sharing, similar to existing compilers of eager functional languages. This strategy only has a polynomial overhead in time, but the space consumption might require an additional factor of , which is essentially due to the size of the pointers required for this strategy. Our main contribution is the construction and verification of a space-aware interleaving of the two strategies, which is shown to yield both a constant overhead in space and a polynomial overhead in time.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 4fc39fdb-dcd2-4031-b0e7-9e12cb02ff5eCited by top-tier papers5
- Strong Call-by-Value is Reasonable, ImplosivelyBeniamino Accattoli, Andrea Condoluci, Claudio Sacerdoti CoenLICS 2021 · 21 citations
- Reasonable Space for the λ-Calculus, LogarithmicallyBeniamino Accattoli, Ugo Dal Lago, Gabriele VanoniLICS 2022 · 8 citations
- The Space of InteractionBeniamino Accattoli, Ugo Dal Lago, Gabriele VanoniLICS 2021 · 4 citations
- A Machine-Independent, Log-Sensitive Space-Cost Measure for the Weak Lambda-CalculusThibaut BalabonskiLICS 2026 · 1 citation
- A Case for First-Class EnvironmentsJinhao Tan, Bruno C. d. S. OliveiraOOPSLA 2024
Related papers
- A Compositional Cost Model for the λ-calculusJames LairdLICS 2021
- The (In)Efficiency of interactionBeniamino Accattoli, Ugo Dal Lago, Gabriele VanoniPOPL 2021 · 13 citations
- Genericity Through StratificationVictor Arrial, Giulio Guerrieri, Delia KesnerLICS 2024 · 1 citation
- Taylor subsumes Scott, Berry, Kahn and PlotkinDavide Barbarossa, Giulio ManzonettoPOPL 2020 · 15 citations
- Interaction EquivalenceBeniamino Accattoli, Adrienne Lancelot, Giulio Manzonetto, Gabriele VanoniPOPL 2025 · 2 citations
