Systems Research and Architecture Group (SRA)

cHash: Avoid redundant build operations by AST-based hashing

During the lifetime of a software project, the compiler is invoked thousands if not hundred-thousands of times. However, the actual source base is only gradually changing. In combination, the a high number of compilations is redundant and could be avoided. A lower number of compiler invocations will not only speed up the development process, since the developer has not to wait for the compiler, but it also saves resources in terms of precious joules.

The cHash project consists of several components:

  • Compiler plugins that detect redundant builds precisely via the mechanism of AST hashing. The result of the AST hash operation is a semantic fingerprint of a single compilation unit. If the fingerprint does not change, the resulting object file will be semantically equivalent.
  • An extension to the build system to further propagate the has-not-changed predicate along the build system dependencies.

People

Publications

USENIX Conference Best Paper Award
cHash: Detection of Redundant Compilations via AST Hashing
Christian Dietrich, Valentin Rothberg, Ludwig Füracker, Andreas Ziegler, Daniel LohmannProceedings of the 2017 USENIX Annual Technical ConferenceUSENIX Association2017Best Paper Award.
PDF Slides Raw Data [BibTex]

Theses

Open Theses Topics

Currently Running Work

Finished Theses

Avoidance of Redundant Recompilations by Propagation of Semantic Fingerprints

Status: abgeschlossen
Supervisors: Christian Dietrich, Daniel Lohmann
Redundant-compile propagation in the make dependency graph

Integration of AST Hashing into the GCC compiler

Status: abgeschlossen
Supervisors: Christian Dietrich, Daniel Lohmann
Implementation and Analysis of a GCC Plugin to calculate an hash value over the abstract syntax tree of a compilation unit.