Static call graphs play a crucial role in program analysis, aiding in tasks such as security analysis, optimization, and performance profiling. However, dynamic language features, such as virtual functions and function pointers, may lead to missing edges in the call graph, which can affect the effectiveness of downstream analyses. Existing solutions rely on full program instrumentation to supplement static call graphs with dynamic information but incur significant runtime overhead, making them impractical for large-scale applications. In this work, we present , a call graph validation and patching tool for C++ applications, combining link-time points-to analysis with selective instrumentation to efficiently resolve indirect function calls while minimizing runtime overhead. During execution, a runtime component captures missing edges, which are then used to augment the static call graph. Evaluation on three representative HPC applications demonstrates that significantly reduces overhead compared to full program instrumentation while maintaining completeness, thus facilitating program analysis for large-scale applications.

错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

CGPatch: Streamlining Static Call Graph Validation Using Selective Instrumentation

  • Sebastian Kreutzer,
  • Silas Martens,
  • Peter Arzt,
  • Tim Heldmann,
  • Christian Bischof

摘要

Static call graphs play a crucial role in program analysis, aiding in tasks such as security analysis, optimization, and performance profiling. However, dynamic language features, such as virtual functions and function pointers, may lead to missing edges in the call graph, which can affect the effectiveness of downstream analyses. Existing solutions rely on full program instrumentation to supplement static call graphs with dynamic information but incur significant runtime overhead, making them impractical for large-scale applications. In this work, we present , a call graph validation and patching tool for C++ applications, combining link-time points-to analysis with selective instrumentation to efficiently resolve indirect function calls while minimizing runtime overhead. During execution, a runtime component captures missing edges, which are then used to augment the static call graph. Evaluation on three representative HPC applications demonstrates that significantly reduces overhead compared to full program instrumentation while maintaining completeness, thus facilitating program analysis for large-scale applications.