CloneIRD:面向代码溯源的克隆代码继承关系判定方法  

CloneIRD:a Clone Code Inheritance Relationship Determination Method for Code Traceability

在线阅读下载全文

作  者:姜智文 任怡[1] 杨立明 管剑波[1] 李宝[1] 谭郁松[1] JIANG Zhiwen;REN Yi;YANG Liming;GUAN Jianbo;LI Bao;TAN Yusong(College of Computer,National University of Defense Techology,Changsha 410073,China)

机构地区:[1]国防科技大学计算机学院,湖南长沙410073

出  处:《郑州大学学报(理学版)》2024年第2期18-25,共8页Journal of Zhengzhou University:Natural Science Edition

基  金:国家自然科学基金项目(U19A2060,61872444)。

摘  要:随着开源软件的广泛使用,代码溯源成为管理软件源代码、降低潜在风险的重要技术手段。基于代码克隆检测的大规模代码溯源分析,从其检测结果中鉴别代码克隆对之间的继承关系,对代码来源追踪、组件依赖关系分析、软件脆弱性分析以及代码缺陷修复等具有重要意义。目前,已有方法在原始代码片段存在微小修改的情况下,会产生许多误判,并且检测克隆对的效率也有待提高。针对上述问题,提出了代码溯源中克隆代码继承关系的判定方法CloneIRD,包括一个基于自研快速分布式克隆检测工具FastDCF的代码溯源分析框架,以及该框架的核心算法——基于代码演化信息的克隆代码继承关系判定算法EIHR。为验证框架和算法的有效性,首先设计并实现了CloneIRD方法,并在Linux内核V4.9和V4.12的开源代码上进行了实验。实验结果表明,CloneIRD方法能够有效判定代码溯源结果中克隆对的继承关系,且基于FastDCF的溯源分析框架能够胜任大规模代码的溯源分析任务。With the widespread of open source software,code traceability has become an important technical to manage code and reduce potential risks.In large-scale code source traceability analysis based on code clone detection,identifying the inheritance relationship between code clone pairs from the detection results was of great significance for code source tracking,component dependency analysis,software vulnerability analysis,and code defect repair.The current method produced many misjudgments when the original code fragments had some minor modifications,and the efficiency of detecting clone pairs also needed to be improved.In response to the above problems,a method for determining the inheritance relationship of cloned code in code traceability,CloneIRD,was proposed,including a code traceability analysis framework based on the self-developed fast distributed clone detection tool FastDCF,and the core algorithm of the framework,a clone code inheritance relationship judgment algorithm based on code evolution information EIHR.In order to verify the effectiveness of the framework and algorithm,the CloneIRD method was first designed and implemented,and experiments were carried out on the open source code of Linux kernel V4.9 and V4.12.The experimental results showed that the CloneIRD method could effectively determine the inheritance relationship of clone pairs in the code traceability results,and the traceability analysis framework based on FastDCF was capable of large-scale code traceability analysis tasks.

关 键 词:代码溯源 克隆代码 克隆检测 代码继承关系 

分 类 号:TP311[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象