Clone detection via structural abstraction

被引:0
|
作者
William S. Evans
Christopher W. Fraser
Fei Ma
机构
[1] University of British Columbia,Department of Computer Science
[2] Microsoft,undefined
[3] One Microsoft Way,undefined
来源
Software Quality Journal | 2009年 / 17卷
关键词
Clone detection; Procedural abstraction; Refactoring;
D O I
暂无
中图分类号
学科分类号
摘要
This paper describes the design, implementation, and application of a new algorithm to detect cloned code. It operates on the abstract syntax trees formed by many compilers as an intermediate representation. It extends prior work by identifying clones even when arbitrary subtrees have been changed. These subtrees may represent structural rather than simply lexical code differences. In several hundred thousand lines of Java and C# code, 20–50% of the clones that we find involve these structural changes, which are not accounted for by previous methods. Our method also identifies cloning in declarations, so it is somewhat more general than conventional procedural abstraction.
引用
收藏
页码:309 / 330
页数:21
相关论文
共 50 条
  • [1] Clone detection via structural abstraction
    Evans, William S.
    Fraser, Christopher W.
    Ma, Fei
    SOFTWARE QUALITY JOURNAL, 2009, 17 (04) : 309 - 330
  • [2] Clone detection via structural abstraction
    Evans, William S.
    Fraser, Christopher W.
    Ma, Fei
    14TH WORKING CONFERENCE ON REVERSE ENGINEERING, PROCEEDINGS, 2007, : 150 - 159
  • [3] StoneDetector: Structural and Sub-Clone Detection
    Schaefer, Andre
    Amme, Wolfram
    Heinze, Thomas S.
    2023 IEEE 17TH INTERNATIONAL WORKSHOP ON SOFTWARE CLONES, IWSC 2023, 2023, : 33 - 36
  • [4] Structural and Nominal Cross-Language Clone Detection
    Nichols, Lawton
    Emre, Mehmet
    Hardekopf, Ben
    FUNDAMENTAL APPROACHES TO SOFTWARE ENGINEERING (FASE 2019), 2019, 11424 : 247 - 263
  • [5] Semantic Clone Detection via Probabilistic Software Modeling
    Thaller, Hannes
    Linsbauer, Lukas
    Egyed, Alexander
    FUNDAMENTAL APPROACHES TO SOFTWARE ENGINEERING, FASE 2022, 2022, 13241 : 288 - 309
  • [6] Modular Heap Abstraction-based Code Clone Detection for Heap-manipulating Programs
    Dong, Longming
    Wang, Ji
    Chen, Liqian
    2012 12TH INTERNATIONAL CONFERENCE ON QUALITY SOFTWARE (QSIC), 2012, : 197 - 200
  • [7] Clone-Hunter: Accelerated Bound Checks Elimination via Binary Code Clone Detection
    Xue, Hongfa
    Venkataramani, Guru
    Lan, Tian
    MAPL'18: PROCEEDINGS OF THE 2ND ACM SIGPLAN INTERNATIONAL WORKSHOP ON MACHINE LEARNING AND PROGRAMMING LANGUAGES, 2018, : 11 - 19
  • [8] Accurate and Efficient Structural Characteristic Feature Extraction for Clone Detection
    Nguyen, Hoan Anh
    Nguyen, Tung Thanh
    Pham, Nam H.
    Al-Kofahi, Jafar M.
    Nguyen, Tien N.
    FUNDAMENTAL APPROACHES TO SOFTWARE ENGINEERING, PROCEEDINGS, 2009, 5503 : 440 - 455
  • [9] Structural Code Clone Detection Methodology Using Software Metrics
    Aktas, Mehmet S.
    Kapdan, Mustafa
    INTERNATIONAL JOURNAL OF SOFTWARE ENGINEERING AND KNOWLEDGE ENGINEERING, 2016, 26 (02) : 307 - 332
  • [10] Towards Semantic Clone Detection via Probabilistic Software Modeling
    Thaller, Hannes
    Linsbauer, Lukas
    Egyed, Alexander
    PROCEEDINGS OF THE 2020 IEEE 14TH INTERNATIONAL WORKSHOP ON SOFTWARE CLONES (IWSC '20), 2020, : 64 - 69