郑州大学学报(理学版)2024,Vol.56Issue(2):18-25,8.DOI:10.13705/j.issn.1671-6841.2022238
CloneIRD:面向代码溯源的克隆代码继承关系判定方法
CloneIRD:a Clone Code Inheritance Relationship Determination Method for Code Traceability
摘要
Abstract
With the widespread of open source software,code traceability has become an important tech-nical 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 vul-nerability analysis,and code defect repair.The current method produced many misjudgments when the o-riginal code fragments had some minor modifications,and the efficiency of detecting clone pairs also nee-ded to be improved.In response to the above problems,a method for determining the inheritance rela-tionship of cloned code in code traceability,CloneIRD,was proposed,including a code traceability anal-ysis framework based on the self-developed fast distributed clone detection tool FastDCF,and the core al-gorithm of the framework,a clone code inheritance relationship judgment algorithm based on code evolu-tion 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 effec-tively determine the inheritance relationship of clone pairs in the code traceability results,and the tracea-bility analysis framework based on FastDCF was capable of large-scale code traceability analysis tasks.关键词
代码溯源/克隆代码/克隆检测/代码继承关系Key words
code traceability/clone code/clone detection/code inheritance relationship分类
信息技术与安全科学引用本文复制引用
姜智文,任怡,杨立明,管剑波,李宝,谭郁松..CloneIRD:面向代码溯源的克隆代码继承关系判定方法[J].郑州大学学报(理学版),2024,56(2):18-25,8.基金项目
国家自然科学基金项目(U19A2060,61872444). (U19A2060,61872444)