{"has_accepted_license":"1","article_type":"original","project":[{"name":"Formal Methods for Stochastic Models: Algorithms and Applications","_id":"0599E47C-7A3F-11EA-A408-12923DDC885E","grant_number":"863818","call_identifier":"H2020"}],"volume":8,"acknowledgement":"This work was supported in part by the European Research Council (ERC) under Grant No. 863818\r\n(ForM-SMArt) and the Hong Kong Research Grants Council under ECS Project No. 26208122.","ec_funded":1,"abstract":[{"lang":"eng","text":"Cost analysis, also known as resource usage analysis, is the task of finding bounds on the total cost of a program and is a well-studied problem in static analysis. In this work, we consider two classical quantitative problems in cost analysis for probabilistic programs. The first problem is to find a bound on the expected total cost of the program. This is a natural measure for the resource usage of the program and can also be directly applied to average-case runtime analysis. The second problem asks for a tail bound, i.e. ‍given a threshold t the goal is to find a probability bound p such that ℙ[total cost ≥ t] ≤ p. Intuitively, given a threshold t on the resource, the problem is to find the likelihood that the total cost exceeds this threshold.\r\nFirst, for expectation bounds, a major obstacle in previous works on cost analysis is that they can handle only non-negative costs or bounded variable updates. In contrast, we provide a new variant of the standard notion of cost martingales, that allows us to find expectation bounds for a class of programs with general positive or negative costs and no restriction on the variable updates. More specifically, our approach is applicable as long as there is a lower bound on the total cost incurred along every path.\r\nSecond, for tail bounds, all previous methods are limited to programs in which the expected total cost is finite. In contrast, we present a novel approach, based on a combination of our martingale-based method for expectation bounds with a quantitative safety analysis, to obtain a solution to the tail bound problem that is applicable even to programs with infinite expected cost. Specifically, this allows us to obtain runtime tail bounds for programs that do not terminate almost-surely.\r\nIn summary, we provide a novel combination of martingale-based cost analysis and quantitative safety analysis that is able to find expectation and tail cost bounds for probabilistic programs, without the restrictions of non-negative costs, bounded updates, or finiteness of the expected total cost. Finally, we provide experimental results showcasing that our approach can solve instances that were beyond the reach of previous methods."}],"status":"public","date_updated":"2024-06-27T07:49:04Z","tmp":{"name":"Creative Commons Attribution 4.0 International Public License (CC-BY 4.0)","short":"CC BY (4.0)","legal_code_url":"https://creativecommons.org/licenses/by/4.0/legalcode","image":"/images/cc_by.png"},"intvolume":" 8","quality_controlled":"1","day":"29","title":"Quantitative bounds on resource usage of probabilistic programs","issue":"OOPSLA1","month":"04","publication_identifier":{"eissn":["2475-1421"]},"doi":"10.1145/3649824","_id":"17162","citation":{"mla":"Chatterjee, Krishnendu, et al. “Quantitative Bounds on Resource Usage of Probabilistic Programs.” Proceedings of the ACM on Programming Languages, vol. 8, no. OOPSLA1, 107, Association for Computing Machinery, 2024, doi:10.1145/3649824.","chicago":"Chatterjee, Krishnendu, Amir Kafshdar Goharshady, Tobias Meggendorfer, and Dorde Zikelic. “Quantitative Bounds on Resource Usage of Probabilistic Programs.” Proceedings of the ACM on Programming Languages. Association for Computing Machinery, 2024. https://doi.org/10.1145/3649824.","ieee":"K. Chatterjee, A. K. Goharshady, T. Meggendorfer, and D. Zikelic, “Quantitative bounds on resource usage of probabilistic programs,” Proceedings of the ACM on Programming Languages, vol. 8, no. OOPSLA1. Association for Computing Machinery, 2024.","ista":"Chatterjee K, Goharshady AK, Meggendorfer T, Zikelic D. 2024. Quantitative bounds on resource usage of probabilistic programs. Proceedings of the ACM on Programming Languages. 8(OOPSLA1), 107.","ama":"Chatterjee K, Goharshady AK, Meggendorfer T, Zikelic D. Quantitative bounds on resource usage of probabilistic programs. Proceedings of the ACM on Programming Languages. 2024;8(OOPSLA1). doi:10.1145/3649824","apa":"Chatterjee, K., Goharshady, A. K., Meggendorfer, T., & Zikelic, D. (2024). Quantitative bounds on resource usage of probabilistic programs. Proceedings of the ACM on Programming Languages. Association for Computing Machinery. https://doi.org/10.1145/3649824","short":"K. Chatterjee, A.K. Goharshady, T. Meggendorfer, D. Zikelic, Proceedings of the ACM on Programming Languages 8 (2024)."},"type":"journal_article","oa_version":"Published Version","oa":1,"scopus_import":"1","publisher":"Association for Computing Machinery","publication_status":"published","author":[{"first_name":"Krishnendu","orcid":"0000-0002-4561-241X","full_name":"Chatterjee, Krishnendu","id":"2E5DCA20-F248-11E8-B48F-1D18A9856A87","last_name":"Chatterjee"},{"full_name":"Goharshady, Amir Kafshdar","first_name":"Amir Kafshdar","orcid":"0000-0003-1702-6584","id":"391365CE-F248-11E8-B48F-1D18A9856A87","last_name":"Goharshady"},{"orcid":"0000-0002-1712-2165","first_name":"Tobias","full_name":"Meggendorfer, Tobias","last_name":"Meggendorfer","id":"b21b0c15-30a2-11eb-80dc-f13ca25802e1"},{"full_name":"Zikelic, Dorde","first_name":"Dorde","orcid":"0000-0002-4681-1699","id":"294AA7A6-F248-11E8-B48F-1D18A9856A87","last_name":"Zikelic"}],"language":[{"iso":"eng"}],"file_date_updated":"2024-06-27T07:48:16Z","department":[{"_id":"KrCh"}],"user_id":"2DF688A6-F248-11E8-B48F-1D18A9856A87","date_created":"2024-06-23T22:01:02Z","article_number":"107","publication":"Proceedings of the ACM on Programming Languages","date_published":"2024-04-29T00:00:00Z","article_processing_charge":"Yes (in subscription journal)","ddc":["000"],"file":[{"file_id":"17182","success":1,"access_level":"open_access","checksum":"9243ded966f71df1572be5466019be5c","creator":"dernst","date_updated":"2024-06-27T07:48:16Z","content_type":"application/pdf","file_size":413096,"file_name":"2024_ProcACMProgLanguage_Chatterjee.pdf","date_created":"2024-06-27T07:48:16Z","relation":"main_file"}],"year":"2024"}