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

Issue 11661008: Sync laziness between BuildFunctionInfo and MakeFunctionInfo. (Closed)

Created:
8 years ago by Yang
Modified:
7 years, 11 months ago
Reviewers:
Michael Starzinger
CC:
v8-dev
Visibility:
Public.

Description

Sync laziness between BuildFunctionInfo and MakeFunctionInfo. BuildFunctionInfo compiles the function eagerly when there are debug break points. However, the AST may have been parsed lazily since MakeFunctionInfo does not check for debug break points. This fixes a regression introduced in r11866. BUG=147497 Committed: https://code.google.com/p/v8/source/detail?r=13382

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+12 lines, -6 lines) Patch
M src/compiler.cc View 1 chunk +3 lines, -2 lines 1 comment Download
A + test/mjsunit/regress/regress-147497.js View 1 chunk +9 lines, -4 lines 1 comment Download

Messages

Total messages: 3 (0 generated)
Yang
please take a look.
8 years ago (2012-12-21 14:53:16 UTC) #1
Michael Starzinger
LGTM, with a suggestion. https://codereview.chromium.org/11661008/diff/1/src/compiler.cc File src/compiler.cc (right): https://codereview.chromium.org/11661008/diff/1/src/compiler.cc#newcode516 src/compiler.cc:516: !isolate->DebuggerHasBreakPoints()) { To make this ...
7 years, 11 months ago (2013-01-14 15:16:03 UTC) #2
Yang
7 years, 11 months ago (2013-01-15 10:16:42 UTC) #3
On 2013/01/14 15:16:03, Michael Starzinger wrote:
> LGTM, with a suggestion.
> 
> https://codereview.chromium.org/11661008/diff/1/src/compiler.cc
> File src/compiler.cc (right):
> 
> https://codereview.chromium.org/11661008/diff/1/src/compiler.cc#newcode516
> src/compiler.cc:516: !isolate->DebuggerHasBreakPoints()) {
> To make this completely consistent with the predicate for the compiler call in
> BuildFunctionInfo we would also need to check whether the
> LiveEditFunctionTracker is active.
> 
> How about we move this whole predicate into a static helper to avoid
> duplication? I was thinking of something like ...
> 
> static bool DebuggerWantsEagerCompilation(bool allow_lazy_without_ctx) {
>   return LiveEditFunctionTracker::IsActive(info.isolate()) ||
>          (info.isolate()->DebuggerHasBreakPoints() &&
!allow_lazy_without_ctx);
> }
> 
> Of course here we don't know whether lazy compilation without context is
> allowed, so that would be set to false here. But we would be able share this
> predicate with BuildFunctionInfo.
> 
>
https://codereview.chromium.org/11661008/diff/1/test/mjsunit/regress/regress-...
> File test/mjsunit/regress/regress-147497.js (right):
> 
>
https://codereview.chromium.org/11661008/diff/1/test/mjsunit/regress/regress-...
> test/mjsunit/regress/regress-147497.js:1: // Copyright 2012 the V8 project
> authors. All rights reserved.
> 2013, since it's a new file. Unless I misunderstood the current copyright
header
> policy, which might very well be possible.

Addressed comment. Landing.

Powered by Google App Engine
This is Rietveld 408576698