kirancodes.me
To Proof Maintenance & Beyond!

Static determination of quantitative resource usage for higher-order programs

Steffen Jost, Kevin Hammond, Hans-Wolfgang Loidl, Martin Hofmann

Abstract

We describe a new automatic static analysis for determining upper-bound functions on the use of quantitative resources for strict, higher-order, polymorphic, recursive programs dealing with possibly-aliased data. Our analysis is a variant of Tarjan's manual amortised cost analysis technique. We use a type-based approach, exploiting linearity to allow inference, and place a new emphasis on the number of references to a data object. The bounds we infer depend on the sizes of the various inputs to a program. They thus expose the impact of specific inputs on the overall cost behaviour.

Related papers