Bounded Expectations: Resource Analysis for Probabilistic Programs
Van Chan Ngo, Quentin Carbonneaux, Jan Hoffmann

TL;DR
This paper introduces a fully automatic static analysis technique for deriving upper bounds on the expected resource consumption of probabilistic programs, combining manual reasoning methods with automatic analysis.
Contribution
It extends automatic amortized resource analysis to probabilistic programs and automates manual reasoning using weakest preconditions, enabling efficient bound inference.
Findings
Successfully analyzed 39 probabilistic programs and randomized algorithms.
Derived bounds are very precise and often optimal.
Bound inference reduces to LP solving in many cases.
Abstract
This paper presents a new static analysis for deriving upper bounds on the expected resource consumption of probabilistic programs. The analysis is fully automatic and derives symbolic bounds that are multivariate polynomials of the inputs. The new technique combines manual state-of-the-art reasoning techniques for probabilistic programs with an effective method for automatic resource-bound analysis of deterministic programs. It can be seen as both, an extension of automatic amortized resource analysis (AARA) to probabilistic programs and an automation of manual reasoning for probabilistic programs that is based on weakest preconditions. As a result, bound inference can be reduced to off-the-shelf LP solving in many cases and automatically-derived bounds can be interactively extended with standard program logics if the automation fails. Building on existing work, the soundness of the…
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
TopicsBayesian Modeling and Causal Inference · Formal Methods in Verification · Machine Learning and Algorithms
