Table of Contents

ACDC Algorithm

History

Developed by Vassilios Tzerpos.

Algorithm Intent

ACDC produces flat or nested decompositions of a software system. The algorithm assigns meaningful names to the clusters it creates.

Factbase Properties

The factbase includes only dependencies between entities.

Clustering Objectives

The produced decomposition has the following properties:

  1. Effective cluster names
  2. Bounded cluster cardinality
  3. File-level granularity

Process Description

ACDC creates clusters by detecting established subsystem patterns in the given software system. Software entities that are not clustered this way are assigned to the subsystem that depends the most on them.

Decomposition Properties

  1. The cluster name is one of the following options:
    • Directory name
    • Module name with large out-degree
    • “Support” for the cluster that contains all utilities
    • Module name of dominator node
  2. All utilities modules belong to one cluster
  3. A large number of clusters contain a dominator node

Algorithm Restrictions

The algorithm is not suitable for systems with less than 100 source files.

Failed Assumptions

Detailed Algorithm Description

ACDC produces a software decomposition from a software system into stages:

  1. Skeleton construction
  2. Orphan Adoption

The Skeleton construction phase creates a skeleton of the final decomposition by identifying subsystems using a pattern-driven approach. Depending on the pattern used, the subsystems are given names. In the second stage, the algorithm completes the decomposition by using the Orphan Adoption algorithm.

Skeleton construction

The skeleton construction phase has seven steps:

  1. Apply the source file pattern
  2. Apply the body-header pattern
  3. Create the potential dominator list
  4. Create a support library and dispatcher list
  5. Create initial skeleton
  6. Iterate the sub-graph dominator pattern including modules from the support library and dispatcher list
  7. Apply both the support library pattern and the dispatch pattern to modules from corresponding list

All apply pattern steps are straight forward grouping entities according to the pattern rule. The other steps are described below.

Create the potential dominator list

Algorithm creates a list of all modules in the systems. The list is sorted in order of ascending out-degree, i.e. the first element in the list is the one with smallest number of outgoing edges.

Create a support library and dispatcher list

ACDC removes from the potential dominator list, all modules that have an in- or out-degree larger than 20. These nodes are placed in two listed:

Create initial skeleton

The ACDC goes through each module n in the potential dominator list and examines whether n is dominator node of a subsystem, according to the sub-graph dominator pattern.

When dominator node is found then ACDC creates a subsystem containing the dominator node and dominator set. Nodes in the dominator set are removed from the potential dominator list, unless the cardinality of the dominated set was larger than 20.

After all modules from the potential dominator list have been examined, ACDC organizes the obtained subsystems, so that the containment hierarchy is a tree.

Iterate the sub-graph dominator pattern including modules from the support library and dispatcher list

Orphan Adoption

In the previous phase, the skeleton of a software decomposition was constructed. Some modules are left unassigned from the first phase. In this phase, the algorithm assigns all non-clustered modules to an already created subsystem, in particular the subsystem that depends the most on the unassigned module.

Implementation

The official implementation of ACDC can be downloaded here.