Reducing value count. IVM could take advantage of this.

This commit is contained in:
Ben Vanik
2014-01-25 22:47:21 -08:00
parent 05432242ff
commit c4d6c7a526
9 changed files with 250 additions and 23 deletions

View File

@@ -50,6 +50,9 @@ PPCTranslator::PPCTranslator(PPCFrontend* frontend) :
//compiler_->AddPass(new passes::DeadStoreEliminationPass());
compiler_->AddPass(new passes::DeadCodeEliminationPass());
// Removes all unneeded variables. Try not to add new ones after this.
compiler_->AddPass(new passes::ValueReductionPass());
// Must come last. The HIR is not really HIR after this.
compiler_->AddPass(new passes::FinalizationPass());
}