Transition EstimateCost() AST traversal to WalkAST() as well.

This commit is contained in:
Matt Pharr
2011-12-16 12:16:11 -08:00
parent 701334ccf2
commit f23d030e43
5 changed files with 61 additions and 69 deletions

View File

@@ -277,7 +277,7 @@ Function::emitCode(FunctionEmitContext *ctx, llvm::Function *function,
ctx->SetDebugPos(code->pos);
ctx->AddInstrumentationPoint("function entry");
int costEstimate = code->EstimateCost();
int costEstimate = EstimateCost(code);
Debug(code->pos, "Estimated cost for function \"%s\" = %d\n",
sym->name.c_str(), costEstimate);