Visualization of Large C and C++ Code Bases
The C and C++ programming languages are among the most used in the industry nowadays, having an estimated user base of several millions. However, C++ (in particular) is also one of the most complex programming languages in existence. Large-scale C++ programs can be hard to understand and maintain.
Within this theme, we research new methods to visualize all aspects of large C++ code bases in a compact and intuitive way. Such aspects include the code syntactic and semantic structure, and various code-level metrics related to maintainability.
Integrated Reverse-Engineering Environment
We aim at creating an Integrated Reverse-engineering Environment (IRE) for C and C++, much like the well-known IDEs for the same languages such as Visual C++ or Eclipse. The IRE should allow engineers to pose a wide range of static queries over the studied code base (such as detecting the instances of a given code pattern or code smell), compute static metrics, and visualize the results and the source code in a compact and intuitive way.
The core engine of our IRE is an efficient and effective static C/C++ analyzer, described here.
Below is a snapshot of the current development of the IRE. Queried code patterns are highlighted over the actual source code using a dense-pixel technique. Metrics can be interactively computed over selected constructs (such as functions or classes) and visualized with a table lens widget. UML diagrams and metrics can be extracted directly from source code. Finally, the results can be exported to a SQL database for third-party tools.
The C/C++ visual IRE is integrated with several third-party visualizations. The image below shows the function-level call graphs of two software systems. The call graphs are extracted using our IRE and visualized using an extended hierarchically bundled edge technique. We immediately see that the left system is more modular than the right one.