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

Issue 450034: Remove the last context dependent reference from the Script object... (Closed)

Created:
11 years ago by Søren Thygesen Gjesse
Modified:
11 years ago
CC:
v8-dev
Visibility:
Public.

Description

Remove the last context dependent reference from the Script object For scripts originating from a call to eval the Script object used to hold a reference to the function from where the eval was called together with the code offset within that function of the eval call. This is used by the stack trace and is part of the debugger protocol. In order to avoid storing the function the script, the position within the script and the name of the function calling eval is stored instead. This avoids holding context dependent objects in the script object. The calculation of the position of the eval in the script holding the eval is now done when the eval script is compiled as it is not possible to postpone this unless a reference is kept to the generated code for the function calling eval. BUG=http://code.google.com/p/v8/issues/detail?id=528 TEST=cctest/test-api/Regress528 Committed: http://code.google.com/p/v8/source/detail?r=3393

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+139 lines, -51 lines) Patch
M src/accessors.h View 2 chunks +6 lines, -4 lines 0 comments Download
M src/accessors.cc View 1 2 2 chunks +47 lines, -10 lines 0 comments Download
M src/bootstrapper.cc View 1 chunk +16 lines, -8 lines 0 comments Download
M src/compiler.cc View 1 2 1 chunk +3 lines, -1 line 1 comment Download
M src/factory.cc View 1 2 1 chunk +1 line, -1 line 0 comments Download
M src/messages.js View 3 chunks +35 lines, -6 lines 0 comments Download
M src/mirror-delay.js View 2 chunks +16 lines, -8 lines 0 comments Download
M src/objects.h View 1 2 2 chunks +5 lines, -5 lines 0 comments Download
M src/objects-debug.cc View 1 chunk +6 lines, -4 lines 0 comments Download
M src/objects-inl.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M test/cctest/test-api.cc View 2 chunks +3 lines, -3 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Søren Thygesen Gjesse
11 years ago (2009-12-01 13:41:40 UTC) #1
Mads Ager (chromium)
LGTM
11 years ago (2009-12-01 13:57:21 UTC) #2
Mads Ager (chromium)
Come to think of it I would prefer to point to the shared function info ...
11 years ago (2009-12-01 14:02:26 UTC) #3
Søren Thygesen Gjesse
On 2009/12/01 14:02:26, Mads Ager wrote: > Come to think of it I would prefer ...
11 years ago (2009-12-01 14:38:09 UTC) #4
Mads Ager (chromium)
11 years ago (2009-12-01 14:43:12 UTC) #5
LGTM with one comment.

http://codereview.chromium.org/450034/diff/2006/2010
File src/compiler.cc (right):

http://codereview.chromium.org/450034/diff/2006/2010#newcode182
src/compiler.cc:182: if (it.frame()->function()->IsJSFunction())
Is this conditional needed?  If it is indentation is off.

Powered by Google App Engine
This is Rietveld 408576698