[counters] Properly rename PreParse timers

BUG=

Review-Url: https://codereview.chromium.org/2504933002
Cr-Commit-Position: refs/heads/master@{#41030}
This commit is contained in:
cbruni 2016-11-16 04:33:36 -08:00 committed by Commit bot
parent 446d6a0678
commit d49cd5307b
2 changed files with 7 additions and 12 deletions

View File

@ -2698,6 +2698,7 @@ FunctionLiteral* Parser::ParseFunctionLiteral(
: (use_temp_zone ? "Preparse resolution" : "Full parse"), : (use_temp_zone ? "Preparse resolution" : "Full parse"),
scope->start_position(), scope->end_position(), scope->start_position(), scope->end_position(),
function_name->byte_length(), function_name->raw_data()); function_name->byte_length(), function_name->raw_data());
}
if (is_lazy_top_level_function) { if (is_lazy_top_level_function) {
CHANGE_CURRENT_RUNTIME_COUNTER(runtime_call_stats_, CHANGE_CURRENT_RUNTIME_COUNTER(runtime_call_stats_,
PreParseNoVariableResolution); PreParseNoVariableResolution);
@ -2705,7 +2706,6 @@ FunctionLiteral* Parser::ParseFunctionLiteral(
CHANGE_CURRENT_RUNTIME_COUNTER(runtime_call_stats_, CHANGE_CURRENT_RUNTIME_COUNTER(runtime_call_stats_,
PreParseWithVariableResolution); PreParseWithVariableResolution);
} }
}
// Validate function name. We can do this only after parsing the function, // Validate function name. We can do this only after parsing the function,
// since the function can declare itself strict. // since the function can declare itself strict.

View File

@ -86,11 +86,6 @@ PreParserIdentifier PreParser::GetSymbol() const {
PreParser::PreParseResult PreParser::PreParseFunction( PreParser::PreParseResult PreParser::PreParseFunction(
FunctionKind kind, DeclarationScope* function_scope, bool parsing_module, FunctionKind kind, DeclarationScope* function_scope, bool parsing_module,
bool is_inner_function, bool may_abort, int* use_counts) { bool is_inner_function, bool may_abort, int* use_counts) {
RuntimeCallTimerScope runtime_timer(
runtime_call_stats_,
track_unresolved_variables_
? &RuntimeCallStats::PreParseWithVariableResolution
: &RuntimeCallStats::PreParseNoVariableResolution);
DCHECK_EQ(FUNCTION_SCOPE, function_scope->scope_type()); DCHECK_EQ(FUNCTION_SCOPE, function_scope->scope_type());
parsing_module_ = parsing_module; parsing_module_ = parsing_module;
use_counts_ = use_counts; use_counts_ = use_counts;