Automated Expected Value Analysis of Recursive Programs - Inria - Institut national de recherche en sciences et technologies du numérique Access content directly
Journal Articles Proceedings of the ACM on Programming Languages Year : 2023

Automated Expected Value Analysis of Recursive Programs

Abstract

In this work, we study the fully automated inference of expected result values of probabilistic programs in the presence of natural programming constructs such as procedures, local variables and recursion. While crucial, capturing these constructs becomes highly non-trivial. The key contribution is the definition of a term representation, denoted as infer[.], translating a pre-expectation semantics into first-order constraints, susceptible to automation via standard methods. A crucial step is the use of logical variables, inspired by previous work on Hoare logics for recursive programs. Noteworthy, our methodology is not restricted to tail-recursion, which could unarguably be replaced by iteration and wouldn't need additional insights. We have implemented this analysis in our prototype ev-imp. We provide ample experimental evidence of the prototype's algorithmic expressibility.
Fichier principal
Vignette du fichier
paper.pdf (701.63 Ko) Télécharger le fichier
Origin : Publisher files allowed on an open archive

Dates and versions

hal-04345663 , version 1 (14-12-2023)

Licence

Attribution

Identifiers

Cite

Martin Avanzini, Georg Moser, Michael Schaper. Automated Expected Value Analysis of Recursive Programs. Proceedings of the ACM on Programming Languages, 2023, 7 (PLDI), pp.1050-1072. ⟨10.1145/3591263⟩. ⟨hal-04345663⟩
16 View
13 Download

Altmetric

Share

Gmail Facebook X LinkedIn More