基于GCC关键变量数据流分析算法的程序切片技术
发布时间:2018-05-02 21:27
本文选题:程序切片 + 目标函数 ; 参考:《计算机工程与应用》2017年24期
【摘要】:随着程序的规模的扩大和复杂度的提高,通过直接分析源码进行程序切片,变得十分困难。在现有的利用编译优化技术来优化程序切片的方法中,存在无法有效利用程序的编译时信息和编译器的优化技术,以及对语言的支持不完善的问题。为此,分析了GCC编译器在编译时的中间表示,首次提出了基于GCC关键变量数据流分析算法的程序切片技术,以程序的GIMPLE中间表示为基础,以程序基本块为单位,通过迭代求解数据流方程,分析程序基本块内和不同基本块间的关键变量数据流信息。该程序切片技术可以获取源程序中仅与预设目标函数相关的关键变量和关键语句,缩减程序规模。最后通过实验,证明了该算法的可行性。
[Abstract]:With the expansion of program size and the increase of complexity, it becomes very difficult to slice the program directly by analyzing the source code. In the existing methods of optimizing program slicing by compiling and optimizing techniques, there are some problems such as the unavailability of compile-time information and compiler optimization techniques, and the imperfection of language support. In this paper, the intermediate representation of GCC compiler at compile time is analyzed, and the program slicing technology based on the GCC key variable data flow analysis algorithm is proposed for the first time. It is based on the GIMPLE intermediate representation of the program and takes the basic block of the program as the unit. The data flow information of key variables in and between the basic blocks of the program is analyzed by iterative solution of the data flow equations. The program slicing technique can obtain the key variables and key statements related only to the preset objective function in the source program and reduce the program size. Finally, the feasibility of the algorithm is proved by experiments.
【作者单位】: 江南计算技术研究所;
【基金】:国家“863”计划基金资助项目(No.2012AA010903)
【分类号】:TP314
【相似文献】
相关期刊论文 前10条
1 吴静;侯国照;顾国昌;;基于GCC的公共子表达式删除优化机理的研究[J];中国高新技术企业;2008年17期
2 黄春;孔凡金;;GCC中基于值剖视的代码特例化[J];计算机与数字工程;2012年02期
3 张勇翔;李必信;郑国梁;;程序切片技术的研究与应用[J];计算机科学;2000年01期
4 杨e,
本文编号:1835564
本文链接:https://www.wllwen.com/kejilunwen/ruanjiangongchenglunwen/1835564.html