Freedom251 › Code Duplication Detection Tools
Deckard

What Deckard is
Deckard is an open-source code clone detection tool for analyzing application source code. It builds vectors from parse trees and clusters them to find code clones, using an abstract syntax tree approach. The documented release supports C, Java 7, PHP 5, and Solidity syntax. Deckard runs batch workflows through shell scripts for clone detection, vector generation, and vector clustering; it can also generate vectors for selected portions of a source file. Its clone detection components can run in parallel, with the maximum process count set through the MAX_PROCS configuration value. Bug detection for clone-related issues is available, but batch clone detection does not enable it by default. Clone and bug reports can be converted to HTML for browser inspection. The README also describes code interfaces for retrieving clone subtrees, vectors, and reports programmatically, including parse trees and vectors from clone reports. Deckard is available for Linux, macOS, and Windows, as well as API use and self-hosting. The repository README identifies its license as three-clause BSD. It warns that Windows Vista and Windows 7 may block compiled executables because of UAC false alarms.
Who it suits
Deckard suits developers and researchers who want to scan application source code for clones using parse-tree analysis and batch scripts. Its programmable interfaces and configurable parallel processing may also suit users who want to work with clone data in their own workflows.
What it does well
- Uses parse trees and vector clustering to identify code clones.
- Supports C, Java 7, PHP 5, and Solidity syntax.
- Clone detection components can run in parallel.
- Converts clone and bug reports into HTML.
- Offers programmable access to clone subtrees, vectors, and reports.
- Open source under a three-clause BSD license.
What to know first
- Clone-related bug detection is not enabled by default in batch scans.
- No CI or IDE integration is listed.
- Windows Vista and 7 may block compiled executables due to UAC false alarms.
Limits
Batch clone detection does not enable clone-related bug detection by default. The documented syntax support covers C, Java 7, PHP 5, and Solidity.
Getting started
- Open the Deckard repository on GitHub.
- Build Deckard with the shell script in its src/main directory.
- Point Deckard at application source code and configure the programming language and paths.
- Run the batch scripts for clone detection, vector generation, or vector clustering.
- Set MAX_PROCS in the configuration file to control the maximum process count.
Verdict
Choose Deckard if you need an open-source, script-driven tool for finding code clones and accessing clone data programmatically. Its workflow centers on batch scripts and configuration, and clone-related bug detection must be enabled separately from default batch clone detection.
Questions
How much does Deckard cost?
Deckard is free and open source.
Which languages does Deckard support?
The release notes describe support for C, Java 7, PHP 5, and Solidity syntax.
Can Deckard detect clone-related bugs?
Yes. Bug detection is available, but it is not enabled by default in batch clone detection.
Which platforms are listed for Deckard?
Deckard lists API use, Linux, macOS, self-hosting, and Windows.
Who maintains Deckard?
The GitHub account associated with the repository identifies its user as Lingxiao Jiang and lists Singapore Management University and Singapore.
Facts from Deckard's own pages
- Analysis
- The README describes semantic clone analysis as a use of Deckard. · github.com, 7 Oct 2026
- Approach
- Deckard uses parse trees, vector generation, and vector clustering for clone detection. · github.com, 7 Oct 2026
- Batch processing
- The README provides scripts for batch-mode clone detection, vector generation, and vector clustering. · github.com, 7 Oct 2026
- Bug detection
- Clone-related bug detection is available but is not enabled by default in batch clone detection. · github.com, 7 Oct 2026
- Detection method
- It generates vectors from parse trees and clusters them to detect code clones. · github.com, 7 Oct 2026
- Installation
- The README instructs users to build Deckard with a shell script in its src/main directory. · github.com, 7 Oct 2026
- Integration
- The README describes a programmable interface for retrieving vectors and parse trees from clone reports. · github.com, 7 Oct 2026
- Intended users
- The documented workflow is for users who point Deckard at application source code and configure the programming language and paths. · github.com, 7 Oct 2026
- Languages
- The release notes describe support for C, Java 7, PHP 5, and Solidity syntax. · github.com, 7 Oct 2026
- License
- The repository README identifies the license as a three-clause BSD license. · github.com, 7 Oct 2026
- Maintainer
- The GitHub account associated with the repository identifies its user as Lingxiao Jiang and lists Singapore Management University and Singapore. · github.com, 7 Oct 2026
- Parallel processing
- Clone detection components can run in parallel, with the maximum process count configured in the config file. · github.com, 7 Oct 2026
- Performance
- Version 2.0 supports parallel execution, with the maximum process count set through the MAX_PROCS configuration value. · github.com, 7 Oct 2026
- Platforms
- Installation instructions use bash or Cygwin; the release notes mention Mac OS compatibility, and the README notes Cygwin can run tens of times slower than Linux. · github.com, 7 Oct 2026
- Programmability
- The README describes retrieving clone subtrees, vectors, and clone reports programmatically through Deckard’s code interfaces. · github.com, 7 Oct 2026
- Purpose
- Deckard is a tree-based code clone detection tool that can also report clone-related bugs. · github.com, 7 Oct 2026
- Reports
- The tool can convert clone or bug reports into HTML for inspection in a browser. · github.com, 7 Oct 2026
- Usage
- Deckard runs through shell scripts in batch mode and can generate vectors for selected portions of a source file. · github.com, 7 Oct 2026
- Windows limitation
- The README warns that Windows Vista and 7 may block compiled executables because of UAC false alarms. · github.com, 7 Oct 2026
Where Deckard stands on Freedom251
- Code Duplication Detection Tools#6 of 18
- Code Clone Detection Tools#10 of 23