Automated Amortised Resource Analysis for Term Rewrite Systems

Based on earlier work on amortised resource analysis, we establish a novel automated amortised resource analysis for term rewrite systems. The method is presented in an inference system akin to a type system and gives rise to polynomial bounds on the innermost runtime complexity of the analysed term rewrite system. Our analysis does not restrict the input rewrite system in any way. This facilitates integration in a general framework for resource analysis of programs. In particular, we have implemented the method and integrated it into our tool Open image in new window .

[1]  Robert E. Tarjan,et al.  Self-adjusting binary trees , 1983, STOC.

[2]  Jan Hoffmann,et al.  Types with potential: polynomial resource bounds via automatic amortized analysis , 2011 .

[3]  Arne John Glenstrup,et al.  Terminator II - stopping partial evaluatin of fully recursive programs , 1999, Technical report / University of Copenhagen / Datalogisk institut.

[4]  Terese Term rewriting systems , 2003, Cambridge tracts in theoretical computer science.

[5]  Ugo Dal Lago,et al.  Analysing the complexity of functional programs: higher-order meets first-order , 2015, ICFP.

[6]  Martin Hofmann,et al.  Multivariate Amortised Resource Analysis for Term Rewrite Systems , 2015, TLCA.

[7]  Helmut Veith,et al.  A simple and scalable static analysis for bound analysis and amortized complexity analysis , 2014, Software Engineering.

[8]  Ugo Dal Lago,et al.  Automating sized-type inference for complexity analysis , 2017, Proc. ACM Program. Lang..

[9]  Georg Moser,et al.  TcT: Tyrolean Complexity Tool , 2016, TACAS.

[10]  Chris Okasaki,et al.  Purely functional data structures , 1998 .

[11]  R. Tarjan Amortized Computational Complexity , 1985 .

[12]  Georg Moser,et al.  Automated amortised resource analysis for term rewrite systems , 2020, Sci. Comput. Program..

[13]  J. Farkas Theorie der einfachen Ungleichungen. , 1902 .

[14]  Tobias Nipkow Amortized Complexity Verified , 2015, ITP.

[15]  Martin Hofmann,et al.  Multivariate amortized resource analysis , 2011, POPL '11.

[16]  Jürgen Giesl,et al.  Analyzing Program Termination and Complexity Automatically with AProVE , 2016, Journal of Automated Reasoning.

[17]  Georg Moser,et al.  Complexity Analysis of Term Rewriting Based on Matrix and Context Dependent Interpretations , 2008, FSTTCS.

[18]  René Thiemann,et al.  The DP framework for proving termination of term rewriting , 2007 .

[19]  Antonio Flores-Montoya,et al.  Upper and Lower Amortized Cost Bounds of Programs Expressed as Cost Relations , 2016, FM.

[20]  Martin Hofmann,et al.  Resource Aware ML , 2012, CAV.

[21]  Georg Moser Uniform Resource Analysis by Rewriting: Strenghts and Weaknesses (Invited Talk) , 2017, FSCD.

[22]  Elvira Albert,et al.  Closed-Form Upper Bounds in Static Cost Analysis , 2011, Journal of Automated Reasoning.

[23]  Carl Christian Frederiksen Automatic Runtime Analysis for First Order Functional Programs , 2002 .

[24]  Ankush Das,et al.  Towards automatic resource bound analysis for OCaml , 2016, POPL.

[25]  Martin Hofmann,et al.  Amortised Resource Analysis and Typed Polynomial Interpretations , 2014, RTA-TLCA.

[26]  Clark W. Barrett,et al.  The SMT-LIB Standard Version 2.0 , 2010 .

[27]  Jürgen Giesl,et al.  Termination of term rewriting using dependency pairs , 2000, Theor. Comput. Sci..

[28]  Georg Moser,et al.  Automated Complexity Analysis Based on the Dependency Pair Method , 2008, IJCAR.

[29]  Jürgen Giesl,et al.  Complexity Analysis for Term Rewriting by Integer Transition Systems , 2017, FroCoS.

[30]  Tobias Nipkow,et al.  Term rewriting and all that , 1998 .