Any large project accumulates dead code: there’s always some module that is no longer needed, or a program that was used during early development but hasn’t been run in years. Indeed, entire projects are created, function for a time, and then stop being useful. Sometimes they are cleaned up, but cleanups require time and effort, and it’s not always easy to justify the investment.
However, while this dead code sits around undeleted, it’s still incurring a cost: the automated testing system doesn’t know it should stop running dead tests; people running large-scale cleanups aren’t aware that there’s no point migrating this code, as it is never run anyway.
So what if we could clean up dead code automatically? That was exactly what people started thinking several years ago, during the Zürich Engineering Productivity team’s annual hackathon. The Sensenmann project, named after the German word for the embodiment of Death, has been highly successful. It submits over 1000 deletion changelists per week, and has so far deleted nearly 5% of all C++ at Google.
Its goal is simple (at least, in principle): automatically identify dead code, and send code review requests (‘changelists’) to delete it.