Abstract
We present an automatic method for computing tight upper bounds on the iteration number of special classes of program loops. These upper bounds are further used in the WCET analysis of programs. To do so, we refine program flows using SMT reasoning and rewrite multi-path loops into single-path ones. Single-path loops are further translated into a set of recurrence relations over program variables. Recurrence relations are solved and iteration bounds of program loops are derived from the computed closed forms. For solving recurrences we deploy a pattern-based recurrence solving algorithm and compute closed forms only for a restricted class of recurrence equations. However, in practice, these recurrences describe the behavior of a large set of program loops. Our technique is implemented in the r-TuBound tool and was successfully tried out on a number of challenging WCET benchmarks.
This is a preview of subscription content, log in via an institution.
Buying options
Tax calculation will be finalised at checkout
Purchases are for personal use only
Learn about institutional subscriptionsPreview
Unable to display preview. Download preview PDF.
References
Albert, E., Arenas, P., Genaim, S., Puebla, G.: Closed-Form Upper Bounds in Static Cost Analysis. J. Automated Reasoning 46(2), 161–203 (2011)
Ammarguellat, Z., Harrison III., W.L.: Automatic Recognition of Induction Variables and Recurrence Relations by Abstract Interpretation. In: Proc. of PLDI, pp. 283–295 (1990)
Blanc, R., Henzinger, T.A., Hottelier, T., Kovács, L.: ABC: Algebraic Bound Computation for Loops. In: Clarke, E.M., Voronkov, A. (eds.) LPAR-16 2010. LNCS, vol. 6355, pp. 103–118. Springer, Heidelberg (2010)
Brummayer, R., Biere, A.: Boolector: An Efficient SMT Solver for Bit-Vectors and Arrays. In: Kowalewski, S., Philippou, A. (eds.) TACAS 2009. LNCS, vol. 5505, pp. 174–177. Springer, Heidelberg (2009)
Everest, G., van der Poorten, A., Shparlinski, I., Ward, T.: Recurrence Sequences. Mathematical Surveys and Monographs, vol. 104. American Mathematical Society (2003)
Gulwani, S., Mehra, K.K., Chilimbi, T.M.: SPEED: Precise and Efficient Static Estimation of Program Computational Complexity. In: Proc. of POPL, pp. 127–139 (2009)
Gulwani, S., Zuleger, F.: The Reachability-Bound Problem. In: Proc. of PLDI, pp. 292–304 (2010)
Gustafsson, J., Ermedahl, A., Sandberg, C., Lisper, B.: Automatic Derivation of Loop Bounds and Infeasible Paths for WCET Analysis Using Abstract Execution. In: Proc. of RTSS, pp. 57–66 (2006)
Henzinger, T., Hottelier, T., Kovács, L.: Valigator: A Verification Tool with Bound and Invariant Generation. In: Proc. of LPAR-15, pp. 333–342 (2008)
Holsti, N., Gustafsson, J., Bernat, G., Ballabriga, C., Bonenfant, A., Bourgade, R., Cassé, H., Cordes, D., Kadlec, A., Kirner, R., Knoop, J., Lokuciejewski, P., Merriam, N., de Michiel, M., Prantl, A., Rieder, B., Rochange, C., Sainrat, P., Schordan, M.: WCET 2008 - Report from the Tool Challenge 2008 - 8th Intl. Workshop on Worst-Case Execution Time (WCET) Analysis. In: Proc. of WCET (2008)
Kauers, M.: SumCracker: A Package for Manipulating Symbolic Sums and Related Objects. J. of Symbolic Computation 41(9), 1039–1057 (2006)
Kirner, R., Knoop, J., Prantl, A., Schordan, M., Kadlec, A.: Beyond Loop Bounds: Comparing Annotation Languages for Worst-Case Execution Time Analysis. J. of Software and System Modeling (2010); Online edition
de Moura, L., Bjørner, N.: Z3: An Efficient SMT Solver. In: Ramakrishnan, C.R., Rehof, J. (eds.) TACAS 2008. LNCS, vol. 4963, pp. 337–340. Springer, Heidelberg (2008)
Lisper, B.: Fully Automatic, Parametric Worst-Case Execution Time Analysis. In: Proc. of WCET, pp. 99–102 (2003)
Michiel, M.D., Bonenfant, A., Cassé, H., Sainrat, P.: Static Loop Bound Analysis of C Programs Based on Flow Analysis and Abstract Interpretation. In: Proc. of RTCSA, pp. 161–166 (2008)
Paule, P., Schorn, M.: A Mathematica Version of Zeilberger’s Algorithm for Proving Binomial Coefficient Identities. J. of Symbolic Computation 20(5-6), 673–698 (1995)
Prantl, A.: High-level Compiler Support for Timing-Analysis. PhD thesis, Vienna University of Technology (2010)
Prantl, A., Knoop, J., Kirner, R., Kadlec, A., Schordan, M.: From Trusted Annotations to Verified Knowledge. In: Proc. of WCET, pp. 39–49 (2009)
Prantl, A., Knoop, J., Schordan, M., Triska, M.: Constraint Solving for High-Level WCET Analysis. In: Proc. of WLPE, pp. 77–89 (2008)
Prantl, A., Schordan, M., Knoop, J.: TuBound - A Conceptually New Tool for WCET Analysis. In: Proc. of WCET, pp. 141–148 (2008)
Riazanov, A., Voronkov, A.: The Design and Implementation of Vampire. AI Communications 15(2-3), 91–110 (2002)
Schneider, C.: Symbolic Summation with Single-Nested Sum Extensions. In: Proc. of ISSAC, pp. 282–289 (2004)
Wolfram, S.: The Mathematica Book. Version 5.0. Wolfram Media (2003)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2012 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Knoop, J., Kovács, L., Zwirchmayr, J. (2012). Symbolic Loop Bound Computation for WCET Analysis. In: Clarke, E., Virbitskaite, I., Voronkov, A. (eds) Perspectives of Systems Informatics. PSI 2011. Lecture Notes in Computer Science, vol 7162. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-29709-0_20
Download citation
DOI: https://doi.org/10.1007/978-3-642-29709-0_20
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-29708-3
Online ISBN: 978-3-642-29709-0
eBook Packages: Computer ScienceComputer Science (R0)