Automatic derivation of loop termination conditions to support verification

  • Authors:
  • Daniel Powell

  • Affiliations:
  • Griffith University, Gold Coast, Queensland, Australia

  • Venue:
  • ACSC '04 Proceedings of the 27th Australasian conference on Computer science - Volume 26
  • Year:
  • 2004

Quantified Score

Hi-index 0.00

Visualization

Abstract

This paper introduces a repeatable and constructive approach to the analysis of loop progress and termination conditions in imperative programs. It is applicable to all loops for which a variant function can be defined using only loop guard variables. The approach involves the algorithmic derivation of loop progress and termination conditions directly from the code itself. The derivation of these conditions has been automated in a prototype tool. The conditions yielded by the automated algorithms are useful for reasoning about correctness in verification based code inspections as well as for the documentation and assessment of program preconditions. Unlike existing formal approaches to termination investigation, which are reliant on the presence of formal specifications, this approach is applicable to undocumented programs as well as formally specified programs. We present the algorithms and formal methods implemented in a prototype tool for deriving loop progress and termination conditions and use the output generated by the tool to illustrate its use in supporting verification and termination defect correction.