View on GitHub

DUPLICATE DETECTOR

Duplicated code inspection for IDE IntelliJ IDEA 2017+

Download this project as a .zip file Download this project as a tar.gz file

This plugin provides advanced on-the-fly duplicated code inspections for IntelliJ IDEA (aka clone detection).

See plugin on JetBrains repository: link

Main features

NB! The plugin requires an additional JVM memory of up to 500 Mb per 1

General usage instructions


Inspections

The plugin provides duplicated code inspection after the initial project indexing is complete: use Alt + Enter to see all duplicated fragments.

Settings

Use File | Settings to setup plugin.

NB! Changes to the settings may cause a full reindexing of the current project

Comparision with other tools


Tool Commercial On-the-fly Recall Scalability
IntelliJ IDEA Ultimate (action) yes no excellent acceptable
IntelliJ IDEA Ultimate (inspection) yes yes acceptable excellent
IDEA clone plugin no yes good good

Tested projects


The plugin has been used to analyze several popular Java projects.

Project Time Memory Clones found
JetBrains MPS 220 s 960 Mb 8109
Android Framework Base 145 s 666 Mb 5055
JetBrains IntelliJ IDEA 221 s 1279 Mb 5178
Apache Hadoop 54 s 400 Mb 1753
Spring Framework 35 s 284 Mb 746
Consulo 86 s 517 Mb 2275
Apache CloudStack 44 s 530 Mb 2875
Apache Camel 31 s 371 Mb 1992

Time - time required to do the initial indexing

Memory - total memory used by IntelliJ IDEA after full project indexing

Parameters used

Configuration

CPU i5-760 lynfield (4 core, 2.8 Ghz)

JVM options: -ea -Xms256m --Xmx4000m