dslomov
aec46ca54a
Stack allocate lexical locals + hoist stack slots
...
Review URL: https://codereview.chromium.org/981203003
Cr-Commit-Position: refs/heads/master@{#28008}
2015-04-22 13:22:18 +00:00
dslomov
92138c73a7
Remove --harmony-scoping flag.
...
We have been shipping harmony scoping for 2 Chrome releases now (M41
and M42). Time to remove the flag.
R=rossberg@chromium.org
LOG=Y
Review URL: https://codereview.chromium.org/1007783002
Cr-Commit-Position: refs/heads/master@{#27187}
2015-03-13 15:15:57 +00:00
adamk@chromium.org
1386257c55
Correctly handle Array unshift/splices that move elements past the max length of an Array
...
BUG=v8:2615
LOG=n
R=verwaest@chromium.org
Review URL: https://codereview.chromium.org/679113003
Cr-Commit-Position: refs/heads/master@{#25270}
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@25270 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-11-11 19:08:14 +00:00
adamk@chromium.org
5f1ae66d56
Narrow cases where Sparse/Smart versions of Array methods are used
...
Added a new %HasComplexElements runtime function (meaning elements that are
non-writable, non-configurable, or have getters and setters) and use it
in UseSparseVariant to filter out cases where the sparse optimizations
can cause V8 to fall out of spec compliance.
Renamed SmartMove/SmartSlice to SparseMove/SparseSlice and guarded them
with the new and improved UseSparseVariant.
These two changes combine let us pass nearly every test in bug-2615.js,
as well as fixing reverse and join on sparse arrays.
Note that there are various test changes in this patch that correct existing
tests to match the correct-by-spec behavior.
This patch depends on https://codereview.chromium.org/666883009 , which
better-aligns the behavior of SmartMove with SimpleMove.
BUG=v8:2615,v8:3612,v8:3621
LOG=y
R=mstarzinger@chromium.org
Review URL: https://codereview.chromium.org/656423004
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24855 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-23 18:21:50 +00:00
adamk@chromium.org
ae7161e4cb
Revert "Remove SmartMove, bringing Array methods further into spec compliance"
...
This reverts https://code.google.com/p/v8/source/detail?r=24647
It caused test failures in Array methods in Linux64 OptimizeForSize.
BUG=v8:2615
TBR=verwaest@chromium.org
LOG=N
Review URL: https://codereview.chromium.org/656683003
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24648 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-15 23:53:02 +00:00
adamk@chromium.org
bb885a79db
Remove SmartMove, bringing Array methods further into spec compliance
...
This is one step towards a single codepath for each method in array.js.
This patch is based on rafaelw's https://codereview.chromium.org/349073002
BUG=v8:2615
LOG=Y
R=verwaest@chromium.org
Review URL: https://codereview.chromium.org/455933002
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24647 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-15 23:36:58 +00:00
adamk@chromium.org
9595c6104e
Add test case for SparseJoin misbehavior with getters
...
BUG=v8:3621
LOG=N
R=mstarzinger@chromium.org
Review URL: https://codereview.chromium.org/645703003
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24535 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-10 17:17:00 +00:00
adamk@chromium.org
a0f80eddde
Add test case demonstrating bug in SparseReverse when combined with getters/setters
...
BUG=v8:3612
LOG=N
R=mstarzinger@chromium.org
Review URL: https://codereview.chromium.org/628383002
git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24443 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-10-07 19:22:44 +00:00
wingo@igalia.com
e12ae547cf
Avoid exposing compiler-allocated temporaries to the debugger
...
R=yangguo@chromium.org
BUG=
Review URL: https://codereview.chromium.org/245963006
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@20899 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-04-23 08:58:41 +00:00
verwaest@chromium.org
f2245a9cf9
Make the strict-mode calling convention for contextual calls the default one.
...
BUG=
R=dcarney@chromium.org
Review URL: https://codereview.chromium.org/131663003
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18581 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-01-14 12:04:10 +00:00
yangguo@chromium.org
aa3518a0f3
Make sure files end with exactly one new line and police this in presubmit.
...
The changes are (excluding presubmit.py) mechanical. I added the following
lines after the check and iterated the presubmit script until all errors
went away:
f = open(name, "w");
if contents.endswith('\n\n'):
f.write(contents[0:-1])
else:
f.write(contents + '\n')
R=jkummerow@chromium.org
Review URL: https://codereview.chromium.org/82803005
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18017 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-11-22 13:50:39 +00:00
rossberg@chromium.org
929e193fc2
Tweak error message
...
R=yangguo@chromium.org
BUG=v8:2758
Review URL: https://codereview.chromium.org/18759002
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15503 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-07-05 08:34:31 +00:00
verwaest@chromium.org
5e8679beea
Remove the optimized construct stub.
...
R=mstarzinger@chromium.org
Review URL: https://chromiumcodereview.appspot.com/15993016
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14946 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-06-05 08:43:25 +00:00
rossberg@chromium.org
3cd9f6a40e
Add d8 functionality for switching between realms (a.k.a. contexts), 2nd try
...
The only difference to the previous implementation (https://codereview.chromium.org/14295011/ ) is in patch set 2.
R=yangguo@chromium.org
BUG=
Review URL: https://codereview.chromium.org/14404005
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14373 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-04-22 11:29:52 +00:00
yangguo@chromium.org
72a05845ec
Revert r14310 due to isolate tests failure.
...
R=mstarzinger@chromium.org
BUG=
Review URL: https://chromiumcodereview.appspot.com/14021004
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14334 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-04-18 14:41:24 +00:00
rossberg@chromium.org
2458a801f7
Add d8 functionality for switching between realms (a.k.a. contexts)
...
R=mstarzinger@chromium.org ,yangguo@chromium.org
BUG=
Review URL: https://codereview.chromium.org/14295011
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14310 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-04-17 15:07:31 +00:00
verwaest@chromium.org
c569d31ff5
Adding standard-compliance tests for array functions.
...
BUG=v8:2615
Review URL: https://chromiumcodereview.appspot.com/13601009
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14174 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2013-04-09 08:09:52 +00:00
erik.corry@gmail.com
bafcfe5427
Fix misplaced assert in heap.cc.
...
Bug=2336
Review URL: https://chromiumcodereview.appspot.com/10911334
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12528 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2012-09-17 11:38:24 +00:00
lrn@chromium.org
c7fccff9af
Clean up JavaScript files to better follow coding standard.
...
Multiline conditionals must use braces.
Semicolons are not optional.
Review URL: http://codereview.chromium.org/8701006
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@10074 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-11-28 12:11:00 +00:00
rossberg@chromium.org
1abf3ed0a4
Introduce collective --harmony flag.
...
Shorten --harmony-block-scoping to --harmony-scoping.
R=keuchel@chromium.org
BUG=
TEST=
Review URL: http://codereview.chromium.org/8226017
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9589 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-12 12:23:06 +00:00
lrn@chromium.org
b9d39c48b8
Make the RegExp.prototype object be a RegExp object.
...
BUG=v8:1217
TEST=mjsunit/regress/regress-1217
Review URL: http://codereview.chromium.org/8041015
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9419 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-26 08:42:01 +00:00
yangguo@chromium.org
7ab81a14fa
Reverting r9399.
...
Review URL: http://codereview.chromium.org/7989007
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9401 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-22 15:55:44 +00:00
yangguo@chromium.org
321bfc549f
Fixing r9265: moving test case into correct location.
...
Review URL: http://codereview.chromium.org/7889008
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9266 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 16:11:05 +00:00
yangguo@chromium.org
fc2c22dd2b
Adding test case for issue 1639, fixed by r9264.
...
BUG=v8:1639
Review URL: http://codereview.chromium.org/7889006
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9265 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 15:08:36 +00:00
yangguo@chromium.org
86a62d0da3
Added check for trailing whitespaces and corrected existing violations.
...
Review URL: http://codereview.chromium.org/7826007
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9094 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-01 11:28:10 +00:00
keuchel@chromium.org
c6c504f8b6
Parse harmony let declarations.
...
Implementation of the harmony block scoped let bindings as proposed here:
http://wiki.ecmascript.org/doku.php?id=harmony:block_scoped_bindings
Changes to the syntax are explained there. They are active under the
harmony_block_scoping_ flag in the parser.
Review URL: http://codereview.chromium.org/7616009
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8944 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-08-16 14:24:12 +00:00
karlklose@chromium.org
f4e4bc43a8
Merge arguments branch to bleeding edge (second try).
...
Review URL: http://codereview.chromium.org/7187007
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8315 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-16 14:12:58 +00:00
karlklose@chromium.org
cc19d1e278
Revert "Merge arguments branch to bleeding merge."
...
This reverts commit ceb31498b9d69edca3260820fb4047045891ce6d.
TBR=kmillikin@chromium.org
Review URL: http://codereview.chromium.org/7172030
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8308 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-16 06:37:49 +00:00
karlklose@chromium.org
6cfeb2d400
Merge arguments branch to bleeding merge.
...
Review URL: http://codereview.chromium.org/7167006
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8300 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-15 15:09:28 +00:00
whesse@chromium.org
c40aa827bf
Add boolean flag to HChange and LNumberUntagD to not convert undefined to NaN.
...
This is needed so that HCompare, optimized for double inputs, works correctly on undefined inputs.
BUG=v8:1434
TEST=mjsunit/bugs/bug-1434.js
Review URL: http://codereview.chromium.org/7044049
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8237 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-09 12:27:28 +00:00
danno@chromium.org
ad98d142cc
Add failing test case for bug 1434
...
BUG=1434
TEST=test/mjsunit/bugs/bug-1434.js
Review URL: http://codereview.chromium.org/7131006
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8213 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-06-08 07:45:37 +00:00
ager@chromium.org
544191e718
Update apply with arguments optimization for strict mode functions and builtins.
...
Do not convert to object for values for strict-mode functions and
builtins.
R=ricow@chromium.org
BUG=v8:1412
TEST=mjsunit/regress/regress-1412.js
Review URL: http://codereview.chromium.org/7096006
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8120 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-31 10:38:41 +00:00
ager@chromium.org
cc4a2d7e76
Fix a number of IC stubs to correctly set the call kind.
...
Make the call kind and call wrapper arguments explicit to force
developers to make a choice. This would have avoided the bug in the
first case.
R=fschneider@chromium.org
TEST=mjsunit/strict-mode-implicit-receiver.js
Review URL: http://codereview.chromium.org/7086029
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8109 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-05-30 13:23:17 +00:00
lrn@chromium.org
a50e69bda5
Avoid calling inherited setters when creating object literals and their boilerplates.
...
Fix issue 1015.
Review URL: http://codereview.chromium.org/6118001
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6205 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-01-06 14:00:50 +00:00
lrn@chromium.org
d8fb09a030
Fix tab in javascript file.
...
Review URL: http://codereview.chromium.org/6004009
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6156 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-01-04 13:14:39 +00:00
lrn@chromium.org
e7ecb74b8a
Don't let JSON parsed objects hit inherited setters.
...
Review URL: http://codereview.chromium.org/6101001
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6154 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-01-04 12:19:55 +00:00
erik.corry@gmail.com
0dcaac1939
Make Failure inherit from MaybeObject instead of Object.
...
Review URL: http://codereview.chromium.org/3970005
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5698 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-10-25 15:22:03 +00:00
ricow@chromium.org
de512af068
Add support for elements and array indices in Object.defineProperty
...
(fixes bug 619).
This also fixes a bug in GetOwnProperty in runtime.cc discovered by
the new test cases. That part of the code was not testable before
since we had no way of correctly defining properties on elements.
Review URL: http://codereview.chromium.org/2832001
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4862 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-06-14 13:55:38 +00:00
sgjesse@chromium.org
bc890ec279
Added tests for issue 618
...
Review URL: http://codereview.chromium.org/668055
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4025 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-03-04 15:04:04 +00:00
ricow@chromium.org
27eaf97350
Added test for bug 619 - we should move this to object-define-property when the bug has been corrected.
...
Review URL: http://codereview.chromium.org/651028
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3918 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-02-19 13:27:43 +00:00
sgjesse@chromium.org
17e80e76e7
Add a test case for issue 618
...
Review URL: http://codereview.chromium.org/647014
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3898 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-02-18 13:01:58 +00:00
sgjesse@chromium.org
562f90d375
Ensure correct boxing of values when calling functions on them
...
When a function is called with a value type as the receiver this is now boxed as an object.
This is a low-impact solution where the receiver is only boxed when required. For IC calls to the V8 builtins values are not boxed and as most of the functions on String.prototype, Number.prototype and Boolean.prototype are sitting there most IC calls on values will not need any boxing of the receiver.
For calls which are not IC calls but calls through the CallFunctionStub a flag is used to determine whether the receiver might be a value and only when that is the case will the receiver be boxed.
No changtes to Function.call and Function.apply - they already boxed values. According to the ES5 spec the receiver should not be boxed for these functions, but current browsers have not adopted that change yet.
BUG=223
TEST=test/mjsunit/value-wrapper.js
TEST=test/mjsunit/regress/regress-crbug-3184.js
Review URL: http://codereview.chromium.org/542087
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3617 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2010-01-15 13:42:32 +00:00
whesse@chromium.org
1ae8a7da3d
Fix bug 344: always keep attributes of existing properties.
...
Review URL: http://codereview.chromium.org/113197
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1931 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-05-13 10:46:28 +00:00
lrn@chromium.org
b11b61c4c0
Added test for issue 334.
...
Test for issue 334 (oveerwriting function erases attributes).
Review URL: http://codereview.chromium.org/109009
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1863 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-05-05 11:52:37 +00:00
sgjesse@chromium.org
a74fcf458c
Fixed the step in handling for function.apply.
...
The generic step-in mechanism floods the function called with break points to ensure a break is hit when entering the function. This generic mechanism was also used for function.apply. The code for function.apply contains a keyed load IC which was patched when stepping into function.apply. However function.apply enteres an internal frame not a JavaScript frame. This caused the logic for returning from the break in function.apply to fail as it forced a jump to the IC on the top JavaScript frame. The top JavaScript frame was the frame for the function calling function.apply not the frame for the apply function. Now returning from the break point in the keyed load IC in the apply code caused a jump to the code for the call IC for the function calling function.apply in the first place. Not a pretty sight.
Step-in now handles function.apply as a separate case where the actual JavaScript function called through apply is flodded with breakpoints instead of the function.apply function.
BUG=269
BUG=8210@chromium.org
Review URL: http://codereview.chromium.org/63055
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1683 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-04-07 09:54:53 +00:00
kmillikin@chromium.org
5e2f3adfd0
Fix issue 284.
...
The problem was continuing out of the body of a for/in (where we do
register allocation) to the loop update (where we do not). Variables
allocated to registers where not preserved.
Review URL: http://codereview.chromium.org/53002
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1585 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-03-24 08:29:24 +00:00
christian.plesner.hansen
cff1d2715e
Added test case for issue 284.
...
Review URL: http://codereview.chromium.org/52031
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1581 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-03-23 23:49:58 +00:00
ager@chromium.org
2fcad0aec1
Revert change 1509 that flush ICs when adding setters on an object or
...
when setting a __proto__ to an object that holds a setter.
This seems to cause a major page load regression, so we need to tune
the clearing.
Review URL: http://codereview.chromium.org/50011
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1548 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-03-19 15:06:00 +00:00
christian.plesner.hansen@gmail.com
8dffcb9efa
Flush ICs when adding setters to an object or setting a __proto__ to
...
an object that holds a setter. If there are no store ics then no
flushing is done. The implementation has been tweaked so that no ICs
are cleared during normal context creation.
This may cost us some performance but I'm submitting it as it is and
if there are problems we can either decide to be smarter about when,
what and/or how we clear, or back this change out altogether.
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1509 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-03-13 13:43:07 +00:00
sgjesse@chromium.org
c8f01466ff
See http://code.google.com/p/v8/issues/detail?id=269 .
...
BUG=269
Review URL: http://codereview.chromium.org/43023
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1484 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2009-03-11 07:34:48 +00:00