基于GCC關(guān)鍵變量數(shù)據(jù)流分析算法的程序切片技術(shù)
發(fā)布時(shí)間:2018-05-02 21:27
本文選題:程序切片 + 目標(biāo)函數(shù); 參考:《計(jì)算機(jī)工程與應(yīng)用》2017年24期
【摘要】:隨著程序的規(guī)模的擴(kuò)大和復(fù)雜度的提高,通過(guò)直接分析源碼進(jìn)行程序切片,變得十分困難。在現(xiàn)有的利用編譯優(yōu)化技術(shù)來(lái)優(yōu)化程序切片的方法中,存在無(wú)法有效利用程序的編譯時(shí)信息和編譯器的優(yōu)化技術(shù),以及對(duì)語(yǔ)言的支持不完善的問(wèn)題。為此,分析了GCC編譯器在編譯時(shí)的中間表示,首次提出了基于GCC關(guān)鍵變量數(shù)據(jù)流分析算法的程序切片技術(shù),以程序的GIMPLE中間表示為基礎(chǔ),以程序基本塊為單位,通過(guò)迭代求解數(shù)據(jù)流方程,分析程序基本塊內(nèi)和不同基本塊間的關(guān)鍵變量數(shù)據(jù)流信息。該程序切片技術(shù)可以獲取源程序中僅與預(yù)設(shè)目標(biāo)函數(shù)相關(guān)的關(guān)鍵變量和關(guān)鍵語(yǔ)句,縮減程序規(guī)模。最后通過(guò)實(shí)驗(yàn),證明了該算法的可行性。
[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.
【作者單位】: 江南計(jì)算技術(shù)研究所;
【基金】:國(guó)家“863”計(jì)劃基金資助項(xiàng)目(No.2012AA010903)
【分類號(hào)】:TP314
【相似文獻(xiàn)】
相關(guān)期刊論文 前10條
1 吳靜;侯國(guó)照;顧國(guó)昌;;基于GCC的公共子表達(dá)式刪除優(yōu)化機(jī)理的研究[J];中國(guó)高新技術(shù)企業(yè);2008年17期
2 黃春;孔凡金;;GCC中基于值剖視的代碼特例化[J];計(jì)算機(jī)與數(shù)字工程;2012年02期
3 張勇翔;李必信;鄭國(guó)梁;;程序切片技術(shù)的研究與應(yīng)用[J];計(jì)算機(jī)科學(xué);2000年01期
4 楊e,
本文編號(hào):1835564
本文鏈接:http://sikaile.net/kejilunwen/ruanjiangongchenglunwen/1835564.html
最近更新
教材專著