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

Issue 10876067: Introduce global contexts to represent lexical global scope(s). (Closed)

Created:
8 years, 4 months ago by rossberg
Modified:
8 years, 3 months ago
Reviewers:
Sven Panne
CC:
v8-dev
Visibility:
Public.

Description

Introduce global contexts to represent lexical global scope(s). They are yet unused; actual allocation of global lexical bindings in these contexts is implemented in a separate follow-up CL. R=svenpanne@chromium.org BUG= Committed: https://code.google.com/p/v8/source/detail?r=12384

Patch Set 1 #

Total comments: 14

Patch Set 2 : Addressed Sven's comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+117 lines, -44 lines) Patch
M include/v8.h View 1 chunk +1 line, -1 line 0 comments Download
M src/arm/full-codegen-arm.cc View 1 1 chunk +6 lines, -3 lines 0 comments Download
M src/contexts.h View 2 chunks +6 lines, -1 line 0 comments Download
M src/contexts.cc View 1 chunk +2 lines, -2 lines 0 comments Download
M src/factory.h View 1 chunk +4 lines, -0 lines 0 comments Download
M src/factory.cc View 1 chunk +9 lines, -0 lines 0 comments Download
M src/heap.h View 2 chunks +5 lines, -0 lines 0 comments Download
M src/heap.cc View 2 chunks +23 lines, -0 lines 0 comments Download
M src/ia32/full-codegen-ia32.cc View 1 1 chunk +5 lines, -2 lines 0 comments Download
M src/mips/full-codegen-mips.cc View 1 1 chunk +6 lines, -3 lines 0 comments Download
M src/objects.h View 1 chunk +0 lines, -1 line 0 comments Download
M src/objects-debug.cc View 1 chunk +2 lines, -1 line 0 comments Download
M src/objects-inl.h View 1 2 chunks +10 lines, -18 lines 0 comments Download
M src/runtime.h View 1 chunk +1 line, -0 lines 0 comments Download
M src/runtime.cc View 1 1 chunk +22 lines, -6 lines 0 comments Download
M src/scopes.h View 1 chunk +1 line, -1 line 0 comments Download
M src/scopes.cc View 3 chunks +9 lines, -3 lines 0 comments Download
M src/x64/full-codegen-x64.cc View 1 1 chunk +5 lines, -2 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
rossberg
8 years, 4 months ago (2012-08-24 15:06:10 UTC) #1
Sven Panne
LGTM with a few nits. http://codereview.chromium.org/10876067/diff/1/src/arm/full-codegen-arm.cc File src/arm/full-codegen-arm.cc (right): http://codereview.chromium.org/10876067/diff/1/src/arm/full-codegen-arm.cc#newcode189 src/arm/full-codegen-arm.cc:189: // Argument to NewContext ...
8 years, 3 months ago (2012-08-27 06:24:54 UTC) #2
rossberg
8 years, 3 months ago (2012-08-27 09:07:16 UTC) #3
http://codereview.chromium.org/10876067/diff/1/src/arm/full-codegen-arm.cc
File src/arm/full-codegen-arm.cc (right):

http://codereview.chromium.org/10876067/diff/1/src/arm/full-codegen-arm.cc#ne...
src/arm/full-codegen-arm.cc:189: // Argument to NewContext is the function,
which is still in edi.
On 2012/08/27 06:24:54, Sven Panne wrote:
> copy-n-paste typo: should be r1. Consider moving the push before the if.

Done.

http://codereview.chromium.org/10876067/diff/1/src/heap.cc
File src/heap.cc (right):

http://codereview.chromium.org/10876067/diff/1/src/heap.cc#newcode2442
src/heap.cc:2442: if (!maybe_obj->ToObject(&obj)) return false;
On 2012/08/27 06:24:54, Sven Panne wrote:
> Consider templatized 'To'

Yeah, none of the other functions around here does, so I'd thought I'd rather be
consistent. Cleaning all that up is a separate gardening todo.

http://codereview.chromium.org/10876067/diff/1/src/ia32/full-codegen-ia32.cc
File src/ia32/full-codegen-ia32.cc (right):

http://codereview.chromium.org/10876067/diff/1/src/ia32/full-codegen-ia32.cc#...
src/ia32/full-codegen-ia32.cc:184: __ push(edi);
On 2012/08/27 06:24:54, Sven Panne wrote:
> Consider moving the push before the if.

Done.

http://codereview.chromium.org/10876067/diff/1/src/mips/full-codegen-mips.cc
File src/mips/full-codegen-mips.cc (right):

http://codereview.chromium.org/10876067/diff/1/src/mips/full-codegen-mips.cc#...
src/mips/full-codegen-mips.cc:197: // Argument to NewContext is the function,
which is still in edi.
On 2012/08/27 06:24:54, Sven Panne wrote:
> copy-n-paste typo: should be a1. Consider moving the push before the if.

Done.

http://codereview.chromium.org/10876067/diff/1/src/objects-inl.h
File src/objects-inl.h (right):

http://codereview.chromium.org/10876067/diff/1/src/objects-inl.h#newcode571
src/objects-inl.h:571: if (Object::IsHeapObject()) {
On 2012/08/27 06:24:54, Sven Panne wrote:
> Using 'if (!Object::IsHeapObject()) return false;' and having straight-line
code
> would be clearer IMHO.

Done.

http://codereview.chromium.org/10876067/diff/1/src/runtime.cc
File src/runtime.cc (right):

http://codereview.chromium.org/10876067/diff/1/src/runtime.cc#newcode8750
src/runtime.cc:8750: if (!maybe_result->ToObject(&result)) return maybe_result;
On 2012/08/27 06:24:54, Sven Panne wrote:
> Make result a Context*, use "...->To(&result)" and remove the cast below.

Done (here and for NewFunctionContext below).

http://codereview.chromium.org/10876067/diff/1/src/x64/full-codegen-x64.cc
File src/x64/full-codegen-x64.cc (right):

http://codereview.chromium.org/10876067/diff/1/src/x64/full-codegen-x64.cc#ne...
src/x64/full-codegen-x64.cc:179: // Argument to NewContext is the function,
which is still in edi.
On 2012/08/27 06:24:54, Sven Panne wrote:
> copy-n-paste typo: should be rdi. Consider moving the push before the if.

Done.

Powered by Google App Engine
This is Rietveld 408576698