Bounded expectations: Resource analysis for probabilistic programs

被引:12
|
作者
Ngo V.C. [1 ]
Carbonneaux Q. [2 ]
Hoffmann J. [1 ]
机构
[1] Ngo, Van Chan
[2] Carbonneaux, Quentin
[3] Hoffmann, Jan
来源
| 2018年 / Association for Computing Machinery, 2 Penn Plaza, Suite 701, New York, NY 10121-0701, United States卷 / 53期
关键词
Probabilistic programming; Resource bound analysis; Static analysis;
D O I
10.1145/3192366.3192394
中图分类号
学科分类号
摘要
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 in 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. An advantage of the technique is that it combines the clarity and compositionality of a weakest-precondition calculus with the efficient automation of AARA. 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 analysis is proved with respect to an operational semantics that is based on Markov decision processes. The effectiveness of the technique is demonstrated with a prototype implementation that is used to automatically analyze 39 challenging probabilistic programs and randomized algorithms. Experiments indicate that the derived constant factors in the bounds are very precise and even optimal for some programs. © 2018 ACM.
引用
收藏
页码:496 / 512
页数:16
相关论文
共 50 条
  • [1] Bounded Expectations: Resource Analysis for Probabilistic Programs
    Ngo, Van Chan
    Carbonneaux, Quentin
    Hoffmann, Jan
    PROCEEDINGS OF THE 39TH ACM SIGPLAN CONFERENCE ON PROGRAMMING LANGUAGE DESIGN AND IMPLEMENTATION, PLDI 2018, 2018, : 496 - 512
  • [2] Bounded Expectations: Resource Analysis for Probabilistic Programs
    Van Chan Ngo
    Carbonneaux, Quentin
    Hoffmann, Jan
    ACM SIGPLAN NOTICES, 2018, 53 (04) : 496 - 512
  • [3] Time-bounded termination analysis for probabilistic programs with delays
    Xu, Ming
    Deng, Yuxin
    INFORMATION AND COMPUTATION, 2020, 275 (275)
  • [4] Bounded Model Checking for Probabilistic Programs
    Jansen, Nils
    Dehnert, Christian
    Kaminski, Benjamin Lucien
    Katoen, Joost-Pieter
    Westhofen, Lukas
    AUTOMATED TECHNOLOGY FOR VERIFICATION AND ANALYSIS, ATVA 2016, 2016, 9938 : 68 - 85
  • [5] Resource-bounded measure on probabilistic classes
    Moser, Philippe
    INFORMATION PROCESSING LETTERS, 2008, 106 (06) : 241 - 245
  • [6] Formal Modelling and Verification of Probabilistic Resource Bounded Agents
    Nguyen, Hoang Nga
    Rakib, Abdur
    JOURNAL OF LOGIC LANGUAGE AND INFORMATION, 2023, 32 (05) : 829 - 859
  • [7] Formal Modelling and Verification of Probabilistic Resource Bounded Agents
    Hoang Nga Nguyen
    Abdur Rakib
    Journal of Logic, Language and Information, 2023, 32 : 829 - 859
  • [8] Quantitative Bounds on Resource Usage of Probabilistic Programs
    Chatterjee, Krishnendu
    Goharshady, Amir Kafshdar
    Meggendorfer, Tobias
    Zikelic, Dorde
    PROCEEDINGS OF THE ACM ON PROGRAMMING LANGUAGES-PACMPL, 2024, 8 (OOPSLA):
  • [9] A PROBABILISTIC ANALYSIS OF LOOP PROGRAMS
    SZABO, ME
    FARKAS, EJ
    COMPUTER LANGUAGES, 1989, 14 (02): : 125 - 136
  • [10] Incremental Analysis for Probabilistic Programs
    Zhang, Jieyuan
    Sui, Yulei
    Xue, Jingling
    STATIC ANALYSIS (SAS 2017), 2017, 10422 : 450 - 472