DDoop: 基于差分式Datalog求解的增量指针分析框架
作者:
作者单位:

作者简介:

沈天琪(1999-), 男, 硕士生, CCF学生会员, 主要研究领域为程序分析.
王熙灶(1995-) 男, 博士生, CCF学生会员, 主要研究领域为程序分析与验证, 程序设计语言.
宾向荣(2000-) 男, 博士生, CCF学生会员, 主要研究领域为程序分析.
卜磊(1983-), 男, 博士, 教授, 博士生导师, CCF杰出会员, 主要研究领域为模型检验, 形式化方法, 信息物理系统, 复杂软件分析与验证.

通讯作者:

卜磊, E-mail: bulei@nju.edu.cn

中图分类号:

基金项目:

国家自然科学基金(62232008, 62172200); 江苏省前沿引领技术基础研究专项(BK20202001); 中央高校基本科研业务费专项资金 (020214380101)


DDoop: Incremental Pointer Analysis Framework Based on Differential Datalog Evaluation
Author:
Affiliation:

Fund Project:

  • 摘要
  • |
  • 图/表
  • |
  • 访问统计
  • |
  • 参考文献
  • |
  • 相似文献
  • |
  • 引证文献
  • |
  • 资源附件
  • |
  • 文章评论
    摘要:

    指针分析是对软件进行编译优化、错误检测的核心基础技术之一. 现有经典指针分析框架, 如Doop, 会将待分析程序和分析算法转化成Datalog评估问题并进行求解, 如程序规模较大, 单次求解分析时间开销较大. 在程序频繁变更发布的情况下, 相关程序分析的开销更是难以负担. 近年来, 增量分析作为一种在代码频繁变更场景下有效复用已有分析结果提升分析效率的技术受到了越来越多的关注. 然而, 目前的增量指针分析技术通常针对特定算法设计, 支持的指针分析选项有限, 其可用性也受到较大限制. 针对上述问题, 设计并实现一种基于差分式Datalog求解的增量指针分析框架DDoop (Differential Doop). DDoop实现增量输入事实生成技术与增量分析规则自动化重写技术, 将多版本程序增量分析问题表达为差分Datalog评估问题, 从而可以充分利用成熟的差分式Datalog求解引擎, 如DDlog, 来实现端到端的增量指针分析, 并最大化兼容复用Doop中已有的指针分析实现, 提供透明的增量化支持. 在广泛应用的真实世界程序上对DDoop进行实验评估, 实验结果显示DDoop相较于非增量的Doop框架具有显著的性能优势, 同时高度兼容Doop中已有的各种指针分析规则.

    Abstract:

    Pointer analysis is a core and fundamental technology for software compiler optimization and bug detection. Existing classic pointer analysis frameworks such as Doop will transform the programs to be analyzed and analysis algorithms into Datalog evaluation problems like too large program size and solve them. As a result, the analysis time overhead of a single solution can be high, and the program analysis overhead can hardly be afforded especially in situations where programs are frequently changed and released. In recent years, as a technology that effectively reemploys existing analysis results and improves analysis efficiency under frequent code changes, incremental analysis has caught increasing attention. However, since current incremental pointer analysis techniques are often designed for specific algorithms, the supported pointer analysis options are limited and their usability is significantly restricted. To this end, this study designs and implements Differential Doop (DDoop), an incremental pointer analysis framework based on Differential Datalog evaluation. DDoop implements incremental input fact generation and automatic rewriting for incremental analysis rules, expressing incremental analysis problems of multi-version programs as Differential Datalog evaluation problems. Finally, a mature Differential Datalog solution engine like DDlog can be fully utilized to achieve end-to-end incremental pointer analysis, maximizing compatibility and reuse of existing pointer analysis implementations in Doop and providing transparent support for incrementalization. Additionally, experimental evaluation of DDoop is conducted on widely adopted real-world programs. The results show that compared to the non-incremental Doop framework, DDoop has a significant performance advantage while highly compatible with a variety of pointer analysis rules existing in Doop.

    参考文献
    相似文献
    引证文献
引用本文

沈天琪,王熙灶,宾向荣,卜磊. DDoop: 基于差分式Datalog求解的增量指针分析框架.软件学报,2024,35(6):2608-2630

复制
分享
文章指标
  • 点击次数:
  • 下载次数:
  • HTML阅读次数:
  • 引用次数:
历史
  • 收稿日期:2023-09-11
  • 最后修改日期:2023-10-30
  • 录用日期:
  • 在线发布日期: 2024-01-05
  • 出版日期:
您是第位访问者
版权所有:中国科学院软件研究所 京ICP备05046678号-3
地址:北京市海淀区中关村南四街4号,邮政编码:100190
电话:010-62562563 传真:010-62562533 Email:jos@iscas.ac.cn
技术支持:北京勤云科技发展有限公司

京公网安备 11040202500063号