Detecting Multiphase Linear Ranking Functions for Single-Path Linear-Constraint Loops

Yuan Yue,Li Yi,Shi Wenchang
DOI: https://doi.org/10.1007/s10009-019-00527-1
2019-01-01
International Journal on Software Tools for Technology Transfer (STTT)
Abstract:Single-path linear-constraint loops are important since many analyses in different fields can be reduced to termination proof synthesis for such loops. In 2017, Ben-Amram and Genaim provided a complete polynomial-time solution to the problem of existence and of synthesis of multiphase linear ranking functions ( $$M\varPhi \hbox {RFs}$$ ) of bounded depth to prove the termination of a single-path linear-constraint loop. However, an open question whether one can precompute a bound on the depth of a $$M\varPhi \hbox {RF}$$ for a given loop is raised and the solution has not been accomplished so far. In this paper, we propose an approach to depth bound detection and synthesis of $$M\varPhi \hbox {RFs}$$ for rational single-path linear-constraint loops. We take a step further based on the work of Ben-Amram and Genaim, and detect the depth bound for a certain class of rational single-path linear-constraint loops. Furthermore, the effectiveness of our approach is presented with experimental evidence. The depth bound can be precomputed for loops where existing tools fail to infer a $$M\varPhi \hbox {RF}$$ or prove that none exists.
What problem does this paper attempt to address?