Merge pull request #1432 from ikifof/clean_dead_outputs

Adding a tool to remove dead outputs.