Paper
27 January 2021 A control flow diagram generation algorithm based on clang static analyzer
Zhoukai Wang, Jiong Zhang, Weigang Ma, Huajun Wang
Author Affiliations +
Proceedings Volume 11720, Twelfth International Conference on Graphics and Image Processing (ICGIP 2020); 117201X (2021) https://doi.org/10.1117/12.2589382
Event: Twelfth International Conference on Graphics and Image Processing, 2020, Xi'an, China
Abstract
The traditional control flow diagram (CFG) only displays the overall framework of the program, but ignores its detailed control information and the complex inner structure. Programmers can hardly comprehend the whole program through traditional CFG. Therefore, an algorithm is proposed to generate a new kind of CFG with abundant details and inner structure. After parsing the compilation results of Clang static analyzer, the algorithm firstly extracts the key control information of a program, and then uses the control information to build up the basic display units. Secondly, the algorithm orders and packs these basic display units to form an intermediate XML file. Finally, the Jgraphx graphics library is introduced to parse the intermediate XML file and render the new CFG. Experiment shows that when comparing with the conventional CFG, the new CFG that drawn by the proposed algorithm can demonstrate more details, states, and data flows. The CFG drawn by the proposed algorithm can also offer strong support for complex software maintenance and testing.
© (2021) COPYRIGHT Society of Photo-Optical Instrumentation Engineers (SPIE). Downloading of the abstract is permitted for personal use only.
Zhoukai Wang, Jiong Zhang, Weigang Ma, and Huajun Wang "A control flow diagram generation algorithm based on clang static analyzer", Proc. SPIE 11720, Twelfth International Conference on Graphics and Image Processing (ICGIP 2020), 117201X (27 January 2021); https://doi.org/10.1117/12.2589382
Advertisement
Advertisement
RIGHTS & PERMISSIONS
Get copyright permission  Get copyright permission on Copyright Marketplace
Back to Top