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

Issue 469006: The toplevel code generator assumed that declarations did not shadow... (Closed)

Created:
11 years ago by Kevin Millikin (Chromium)
Modified:
9 years, 7 months ago
CC:
v8-dev
Visibility:
Public.

Description

The toplevel code generator assumed that declarations did not shadow parameters. This could case the initial value to be lost or worse, a crash. Fix by handling the case of a declaration shadowing both stack-allocated parameters and those in the arguments object. This is related to V8 issue 540. http://code.google.com/p/v8/issues/detail?id=540 BUG=29565 Committed: http://code.google.com/p/v8/source/detail?r=3429

Patch Set 1 #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+270 lines, -179 lines) Patch
M src/arm/fast-codegen-arm.cc View 1 chunk +83 lines, -63 lines 0 comments Download
M src/compiler.cc View 1 chunk +12 lines, -0 lines 0 comments Download
M src/ia32/fast-codegen-ia32.cc View 2 chunks +78 lines, -56 lines 3 comments Download
M src/x64/fast-codegen-x64.cc View 1 chunk +82 lines, -58 lines 0 comments Download
M test/mjsunit/regress/regress-540.js View 1 chunk +15 lines, -2 lines 1 comment Download

Messages

Total messages: 4 (0 generated)
Kevin Millikin (Chromium)
11 years ago (2009-12-07 12:34:52 UTC) #1
Mads Ager (chromium)
LGTM
11 years ago (2009-12-07 12:56:48 UTC) #2
fschneider
http://codereview.chromium.org/469006/diff/1/3 File src/ia32/fast-codegen-ia32.cc (right): http://codereview.chromium.org/469006/diff/1/3#newcode416 src/ia32/fast-codegen-ia32.cc:416: I'm confused by the variable rewrites again :) And ...
11 years ago (2009-12-07 13:09:01 UTC) #3
Kevin Millikin (Chromium)
11 years ago (2009-12-07 13:29:59 UTC) #4
http://codereview.chromium.org/469006/diff/1/3
File src/ia32/fast-codegen-ia32.cc (right):

http://codereview.chromium.org/469006/diff/1/3#newcode495
src/ia32/fast-codegen-ia32.cc:495: Handle<Code>
ic(Builtins::builtin(Builtins::KeyedLoadIC_Initialize));
On 2009/12/07 13:09:01, fschneider wrote:
> KeyedStore instead of load?

Good catch.  Fixed and added test coverage.

Powered by Google App Engine
This is Rietveld 408576698