Perpetual Testing Logo

Fanasci: Aids to Recovering Structure

Ideally we would begin with well-defined architectural models of a software system and proceed with full traceability through initial implementation and several generations of implementation. In practice,we must often bootstrap the evolutionary development cycle from existing software artifacts, which may or may not include suitable design representations, and which almost certainly do not include the rich web of relations we require between levels of design and implementation. While reverse engineering is not the central focus of the Perpetual Testing project, we do provide aids to recovering and reconstructing suitable models for analysis and testing of multi-threaded software systems. Current tools are targeted to Ada, but are built on a flexible framework for building a variety of aggregation and selection aids using flow analysis algorithms.

 

Extracting task call graphs

A first step in understanding and modeling the synchronization structure of a complex Ada program is to identify the tasks and their potential interactions. Interaction between tasks may be mediated by a chain of several intermediate procedures, so it is not always simple even to determine whether two tasks communicate, let alone how.

 

The task call graph extractor produces reduced call-graph representations of Ada 95 programs. Two output representations are possible. One is a graph consisting only of Ada tasks and their synchronizations (entry calls, either direct or through some chain of procedure calls). The second output representation includes procedures on a calling chain between tasks. Both views are produced from a cross-reference listing generated by the Gnat Ada compiler.

Aggregating modules in "uses" hierarchies

A second tool aids in aggregating components in a large system into an architecture of higher-level subsystems or design modules. The information provided by this view is essentially a reflexion model as described by Murphy and Notkin. Our tool provides a new kind of automation not found in the original reflexion models: When some implementation components (Ada packagess, in this case) are mapped to the design explicitly by the user, constraints on well-formed uses hierarchies are propogated through the implementation dependency graph to automatically map other components. The tool also implements some heuristics adapted from the Rigi reverse engineering tool.

Fanasci

The two tools above are built on a common core called Fanasci, constructed by Jeydev Rajamani at Purdue. Fanasci uses general flow analysis algorithms to efficiently propogate attributes in directed, labeled graph models. The core Fanasci tool is independent of the source of the input graph, and can be used to rapidly construct a variety of other application-specific aids to recovering particular views of gross structure from graph representations of software systems.

 

Contact: Michal Young