Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(295)

Unified Diff: src/compiler.cc

Issue 131102: Eliminate double offsetting of line numbers in profiler. (Closed)
Patch Set: Created 11 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/log.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.cc
diff --git a/src/compiler.cc b/src/compiler.cc
index 73d200226e3c6bb349c79ff2482070f2a299a6d5..8ab126accf32b5024d12aa819bc7f90d203cd70b 100644
--- a/src/compiler.cc
+++ b/src/compiler.cc
@@ -380,10 +380,7 @@ bool Compiler::CompileLazy(Handle<SharedFunctionInfo> shared,
Handle<String> func_name(name->length() > 0 ?
*name : shared->inferred_name());
if (script->name()->IsString()) {
- int line_num = GetScriptLineNumber(script, start_position);
- if (line_num > 0) {
- line_num += script->line_offset()->value() + 1;
- }
+ int line_num = GetScriptLineNumber(script, start_position) + 1;
LOG(CodeCreateEvent(Logger::LAZY_COMPILE_TAG, *code, *func_name,
String::cast(script->name()), line_num));
OProfileAgent::CreateNativeCodeRegion(*func_name,
« no previous file with comments | « no previous file | src/log.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698