Automatic generation of path covers based on the control flow analysis of computer programs
- 1 December 1994
- journal article
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Transactions on Software Engineering
- Vol. 20 (12) , 885-899
- https://doi.org/10.1109/32.368137
Abstract
Branch testing a program involves generating a set of paths that will cover every arc in the program flowgraph, called a path cover, and finding a set of program inputs that will execute every path in the path cover. This paper presents a generalized algorithm that finds a path cover for a given program flowgraph. The analysis is conducted on a reduced flowgraph, called a ddgraph, and uses graph theoretic principles differently than previous approaches. In particular, the relations of dominance and implication which form two trees of the arcs of the ddgraph are exploited. These relations make it possible to identify a subset of ddgraph arcs, called unconstrained arcs, having the property that a set of paths exercising all the unconstrained arcs also cover all the arcs in the ddgraph. In fact, the algorithm has been designed to cover all the unconstrained arcs of a given ddgraph: the paths are derived one at a time, each path covering at least one as yet uncovered unconstrained arc. The greatest merits of the algorithm are its simplicity and its flexibility. It consists in just visiting recursively in combination the dominator and the implied trees, and is flexible in the sense that it can derive a path cover to satisfy different requirements, according to the strategy adopted for the selection of the unconstrained arc to be covered at each recursive iteration. This feature of the algorithm can be employed to address the problem of infeasible paths, by adopting the most suitable selection strategy for the problem at hand. Embedding of the algorithm into a software analysis and testing tool is recommended.<>Keywords
This publication has 15 references indexed in Scilit:
- A meaningful bound for branch testingPublished by Association for Computing Machinery (ACM) ,1994
- Ct coverage ? initial resultsSoftware Quality Journal, 1993
- Unconstrained edges and their application to branch analysis and testing of programsJournal of Systems and Software, 1993
- A generalized optimal path-selection model for structural program testingJournal of Systems and Software, 1989
- Test Data Selection and Quality Estimation Based on the Concept of Essential Branches for Path TestingIEEE Transactions on Software Engineering, 1987
- A Comparison of Measures of Control Flow ComplexityIEEE Transactions on Software Engineering, 1980
- On Path Cover Problems in Digraphs and Applications to Program TestingIEEE Transactions on Software Engineering, 1979
- A fast algorithm for finding dominators in a flowgraphACM Transactions on Programming Languages and Systems, 1979
- A Complexity MeasureIEEE Transactions on Software Engineering, 1976
- A Decomposition Theorem for Partially Ordered SetsAnnals of Mathematics, 1950