一句话:将动态分析数据注入 Infer 的 Erlang 组合静态分析,在 WhatsApp 代码上显著提升缺陷检出。
本文提出一种利用动态分析改进真实代码静态分析的新方法,目标是提升组合式静态分析在实际工业代码中的缺陷检测能力。作者将 FAUSTA 动态分析获得的数据补充到 Infer 的 Erlang 静态分析器中,并给出了结合静态与动态分析的具体算法。案例研究在 WhatsApp 的 Erlang 代码上评估该方法,结果表明:在使用动态分析数据的运行中,76% 的运行检测到更多缺陷;平均而言,动态分析为 1 个函数提供的数据可支持静态分析额外处理 2.1 个函数。此外,动态数据还使静态分析能够验证一个仅靠静态分析无法验证的性质。
In this paper we introduce a novel method for improving static analysis of real code by using dynamic analysis. We have implemented our technique to enhance the Infer static analyzer [6] for Erlang by supplementing its analysis with data obtained by FAUSTA [24] dynamic analysis. We present the technical details of the algorithm combining static and dynamic analysis and a case study on its evaluation on WhatsApp's Erlang code to detect software defects. Results show an increase in detected bugs in 76% of the runs when data from dynamic analysis is used. In particular, on average, data provided by dynamic analysis for 1 function enables static analysis of 2.1 additional functions. Moreover, dynamic data enabled analysis of a property not verifiable using static analysis alone.
@inproceedings{paperbot8285,
title = {Enhancing Compositional Static Analysis with Dynamic Analysis},
author = {Dino Distefano and Matteo Marescotti and Cons Ahs and Sopot Cela and Gabriela Cunha Sampaio and Radu Grigore and Akos Hajdu and Timotej Kapus and Ke Mao and Thibault Suzanne},
booktitle = {ASE},
year = {2024},
doi = {10.1145/3691620.3695599}
}