A METHOD FOR DOCUMENTING CODE COMPONENTS

Citation
Vr. Basili et Sk. Abdelhafiz, A METHOD FOR DOCUMENTING CODE COMPONENTS, The Journal of systems and software, 34(2), 1996, pp. 89-104
Citations number
44
Categorie Soggetti
System Science","Computer Science Theory & Methods","Computer Science Software Graphycs Programming
ISSN journal
01641212
Volume
34
Issue
2
Year of publication
1996
Pages
89 - 104
Database
ISI
SICI code
0164-1212(1996)34:2<89:AMFDCC>2.0.ZU;2-8
Abstract
We propose a set of criteria for facilitating the rigorous understandi ng of code components via documentation and evaluate existing notation s and approaches with respect to these criteria. We present an overvie w of an analysis approach designed to generate program documentation t hat satisfies these criteria. Because of the inherent difficulty and i mportance of reasoning about loops, we focus on understanding and docu menting loops. We decompose loops into their component parts and obtai n formal specifications of the resulting loop fragments by use of a kn owledge base. We build this knowledge base for a specific application domain by designing plans that allow us to recognize stereotyped code patterns and associate them with their formal specifications. Finally, we synthesize a consistent and accurate specification of the whole lo op construct from the specifications of its fragments. To evaluate our loop analysis approach, a case study was performed on a preexisting p rogram of reasonable size. Results concerning the analyzed loops and t he plans designed for them are given. To generate formal documentation of complete program modules, we briefly describe how to integrate our loop analysis approach with an existing program analysis tool, FSQ(2) , which uses user-supplied loop specifications.