Tight Typings and Split Bounds

07/06/2018
by   Beniamino Accattoli, et al.
0

Multi types---aka non-idempotent intersection types---have been used to obtain quantitative bounds on higher-order programs, as pioneered by de Carvalho. Notably, they bound at the same time the number of evaluation steps and the size of the result. Recent results show that the number of steps can be taken as a reasonable time complexity measure. At the same time, however, these results suggest that multi types provide quite lax complexity bounds, because the size of the result can be exponentially bigger than the number of steps. Starting from this observation, we refine and generalise a technique introduced by Bernadet & Graham-Lengrand to provide exact bounds for the maximal strategy. Our typing judgements carry two counters, one measuring evaluation lengths and the other measuring result sizes. In order to emphasise the modularity of the approach, we provide exact bounds for four evaluation strategies, both in the lambda-calculus (head, leftmost-outermost, and maximal evaluation) and in the linear substitution calculus (linear head evaluation). Our work aims at both capturing the results in the literature and extending them with new outcomes. Concerning the literature, it unifies de Carvalho and Bernadet & Graham-Lengrand via a uniform technique and a complexity-based perspective. The two main novelties are exact split bounds for the leftmost strategy---the only known strategy that evaluates terms to full normal forms and provides a reasonable complexity measure---and the observation that the computing device hidden behind multi types is the notion of substitution at a distance, as implemented by the linear substitution calculus.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
02/15/2019

Types by Need (Extended Version)

A cornerstone of the theory of lambda-calculus is that intersection type...
research
11/28/2017

The Maximal MAM, a Reasonable Implementation of the Maximal Strategy

This note is about a reasonable abstract machine, called Maximal MAM, im...
research
08/30/2018

Types of Fireballs (Extended Version)

The good properties of Plotkin's call-by-value lambda-calculus crucially...
research
04/28/2021

The Space of Interaction (long version)

The space complexity of functional programs is not well understood. In p...
research
02/07/2022

Call-by-Value Solvability and Multi Types

This paper provides a characterization of call-by-value solvability usin...
research
12/04/2019

A Quantitative Understanding of Pattern Matching

This paper shows that the recent approach to quantitative typing systems...
research
09/21/2023

Strong Call-by-Value and Multi Types

This paper provides foundations for strong (that is, possibly under abst...

Please sign up or login with your details

Forgot password? Click here to reset