{'fraction_non_alphanumeric': 0.02453580901856764, 'fraction_numerical': 0.000663129973474801, 'mean_word_length': 5.340336134453781, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Incrementally Precise Quantitative Analysis

We consider the quantitative analysis of programs where executions are assigned real values to represent a quality measure. Such analyses cover important applications particularly for resource usage. The approach used is dominated by some form of Abstract Interpretation (AI) where abstract program properties are propagated through transitions induced by the program. Typical AI implementations are often efficient and scalable; however, their precision could be arbitrarily low, and perhaps more importantly, the level of (im)precision is unknown. An idealized algorithm should be efficient, i.e., generating answers quickly; but if the resource budget allows, should progressively produce better solutions via a number of refinement iterations. The result of each iteration remains sound, but importantly, must converge to the “exact analysis” when given (theoretically) infinite resource budget. A pioneering work in this direction is [6]. In this paper we argue that their algorithm, based on the CEGAR framework, does not scale well, and present an alternative approach to CEGAR using a form of symbolic execution. We produce a more scalable algorithm with several desirable properties and demonstrate it with real programs on two kinds of analyses: a timing analysis and a data flow analysis. We show that in many cases, our iterative method is in fact superior to both AI as well as algorithms designed to run continuously till an exact analysis is found.