计算机技术与发展
計算機技術與髮展
계산궤기술여발전
COMPUTER TECHNOLOGY AND DEVELOPMENT
2015年
8期
1-8
,共8页
PowerPC汇编程序%结构恢复%习语分析%反编译框架
PowerPC彙編程序%結構恢複%習語分析%反編譯框架
PowerPC회편정서%결구회복%습어분석%반편역광가
PowerPC assembly program%structure recovery%instruction idiom analysis%decompilation framework
反编译技术将二进制程序或汇编程序转换成可读性较好的高级语言代码,在代码理解、代码维护和代码安全验证等方面具有重要作用。文中介绍了一种基于PowerPC汇编程序的反编译软件框架及其关键技术。该软件框架主要包括由汇编程序加载、指令系统的语义描述和汇编指令的解码所组成的前端,由数据流分析、类型分析和控制流分析所组成的中间端以及负责代码生成的后端。采用的关键技术有switch语句翻译,代码复制消除goto语句和指令习语( instruction idi-om)翻译等。实验结果表明,反编译生成的高级语言程序在结构、可读性等方面都有所增强,对于辅助代码理解有指导意义。
反編譯技術將二進製程序或彙編程序轉換成可讀性較好的高級語言代碼,在代碼理解、代碼維護和代碼安全驗證等方麵具有重要作用。文中介紹瞭一種基于PowerPC彙編程序的反編譯軟件框架及其關鍵技術。該軟件框架主要包括由彙編程序加載、指令繫統的語義描述和彙編指令的解碼所組成的前耑,由數據流分析、類型分析和控製流分析所組成的中間耑以及負責代碼生成的後耑。採用的關鍵技術有switch語句翻譯,代碼複製消除goto語句和指令習語( instruction idi-om)翻譯等。實驗結果錶明,反編譯生成的高級語言程序在結構、可讀性等方麵都有所增彊,對于輔助代碼理解有指導意義。
반편역기술장이진제정서혹회편정서전환성가독성교호적고급어언대마,재대마리해、대마유호화대마안전험증등방면구유중요작용。문중개소료일충기우PowerPC회편정서적반편역연건광가급기관건기술。해연건광가주요포괄유회편정서가재、지령계통적어의묘술화회편지령적해마소조성적전단,유수거류분석、류형분석화공제류분석소조성적중간단이급부책대마생성적후단。채용적관건기술유switch어구번역,대마복제소제goto어구화지령습어( instruction idi-om)번역등。실험결과표명,반편역생성적고급어언정서재결구、가독성등방면도유소증강,대우보조대마리해유지도의의。
Decompilation is the process of converting binary program or assembly program into high level code with good readability, which plays a vital role in code understanding,code maintenance and code safety verification. In this paper,introduce a decompilation framework based on PowerPC assembly program and its main techniques. The framework consists of the frontend, which includes the loading of the assembly programs,the semantic description and the decoding of the instruction set,the middle end,which includes data flow analysis,type analysis and control flow analysis,and the back end,which is responsible for code generation. The main techniques consist of translation of switch sentence,goto sentence of elimination by code duplication and translation of instruction idiom. Experimen-tal results show that the generated high level code improves in both structure and readability,there’ s a guiding significance in code under-standing.