计算机工程与应用2018,Vol.54Issue(6):30-36,7.DOI:10.3778/j.issn.1002-8331.1610-0151
分支语句重构算法的研究与应用
Research and application of refactoring algorithm of branch statements
摘要
Abstract
Due to the multiple nested of conditional branch statements, logic structure of the code is not clear and the code is difficult to read,the efficiency of dividing basic block is reduced when generating basic path set.On this basis,a method is proposed for automatic code refactoring.It uses bottom-up analysis and reduction,following compiler syntax analysis method, can realize automatic adjustment to the nested if-else conditional statement, and is more clearer to the structure of code,the code will be more suitable for the tool of generating basic path set.This method improves the effi-ciency of the tool of generating basic path set.For the tool of generating basic path set based on the model algebraic,it im-proves the algorithm of generating model algebraic expressions, and can generate basic path set accurately. Finally, through the comparison of the experiment,it verifies the effectiveness of the refactoring and the improved algorithm.关键词
多重嵌套/自动化重构/自下而上分析/归约/模型代数表达式Key words
multiple nested/automated refactoring/bottom-up analysis/reduction/model algebraic expression分类
信息技术与安全科学引用本文复制引用
赵会群,孙雨..分支语句重构算法的研究与应用[J].计算机工程与应用,2018,54(6):30-36,7.基金项目
国家自然科学基金(No.61070030,No.61370051). (No.61070030,No.61370051)