Commit Graph

7077 Commits

Author SHA1 Message Date
jkummerow@chromium.org
fcc2e65aad Change global const handling to silently ignore redeclarations
and make window.{Infinity,NaN,undefined} read-only as per ES5

BUG=89490
TEST=mjsunit/const-redecl.js, mjsunit/undeletable-functions.js, es5conform, sputnik

Review URL: http://codereview.chromium.org/7811015

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9299 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 12:00:30 +00:00
jkummerow@chromium.org
c7d2903fae Convert "BUG=foo" to "(issue foo)" in push-to-trunk.sh
Review URL: http://codereview.chromium.org/7903005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9298 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 11:45:06 +00:00
erik.corry@gmail.com
44d931c9d5 Add asserts to ensure that we:
1) Don't make a call to C without having a valid frame on the stack.
2) Don't generate a call to a stub while generating a stub, unless we can be
sure that the stub we are calling has already been generated (the stub
generation code is not reentrant wrt. GC).
Review URL: http://codereview.chromium.org/7891042

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9297 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 11:30:45 +00:00
yangguo@chromium.org
327eb48ce6 Enable slices of external strings (in the tentative implementation).
TEST=cctest test-strings/SliceFromExternal, mjsunit/string-slices.js

Review URL: http://codereview.chromium.org/7832002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9295 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 11:10:01 +00:00
fschneider@chromium.org
9e4663a8d9 Enable inlining of functions that reference context slots.
Review URL: http://codereview.chromium.org/7887038

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9294 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 10:57:47 +00:00
svenpanne@chromium.org
8c744768e2 Nuke CompareToNull AST node.
The Great Master Plan is to move the recognition of special cases for
comparisons further down the compilation pipeline where more information is
available. This is a first step into this direction: The special handling of
equality comparisons involving null is pushed from the parser to the code
generators, removing the need for a special AST node. (There are rumors from
usually well-informed sources that this node type is actually a relic of ancient
crankshaft days...)

The next steps will be the unification of null/undefined handling and pushing
the special case handling in crankshaft even further down the pipeline, enabling
the recognition of cases like "var foo=null; if (foo === bar) ...", but these
will be in separate CLs.
Review URL: http://codereview.chromium.org/7887037

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9293 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 09:09:40 +00:00
jkummerow@chromium.org
5ab7a66a49 Add "native" target to Makefile for the benefit of Linux distros
TEST=make native; make native.check; make native.clean

Review URL: http://codereview.chromium.org/7891045

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9292 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 08:16:07 +00:00
jkummerow@chromium.org
5a33daf643 Add solaris support to gyp build.
Patch by Ben Noordhuis <info@bnoordhuis.nl>. I don't have a Solaris box around to test this myself.

BUG=v8:1684

Review URL: http://codereview.chromium.org/7889038

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9291 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 08:13:39 +00:00
yangguo@chromium.org
48b5328bde Fixing issue 1639, debugger stops stepping outside evaluate.
BUG=v8:1639

Review URL: http://codereview.chromium.org/7889039

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9287 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 07:23:31 +00:00
lrn@chromium.org
2ac387c28c Prepare push to trunk. Now working on version 3.6.5.
R=ricow@chromium.org

Review URL: http://codereview.chromium.org/7905001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9286 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-15 07:22:07 +00:00
vegorov@chromium.org
af03e40cbb Force lazy deoptimization and remove optimized code on deopt inside a recursively invoked function.
R=fschneider@chromium.org,sgjesse@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7890028

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9285 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 16:14:26 +00:00
yangguo@chromium.org
e53841104d Fixing d8's broken readline history.
Review URL: http://codereview.chromium.org/7885026

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9282 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 14:39:56 +00:00
keuchel@chromium.org
96de832c89 Mark variables as being accessed from any inner scope, not only function scopes
BUG=96523
TEST=mjsunit/regress/regress-96523.js

Review URL: http://codereview.chromium.org/7890031

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9281 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 13:51:29 +00:00
lrn@chromium.org
724962846c Make built-in functions not call .apply on functions.
Uses the new %Apply runtime function instead.
Removes last(?) dependency on user-mungable infrastructure.

Review URL: http://codereview.chromium.org/7887031

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9277 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 12:33:57 +00:00
lrn@chromium.org
e292eddf90 Cleanup of include comments
Review URL: http://codereview.chromium.org/7892025

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9276 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 12:23:52 +00:00
mikhail.naganov@gmail.com
b706cfce94 Eliminate the need for code delete events in CPU profiler.
Events are still generated for tick processor on performance testing
server to work, as soon as scripts will be updated, it will be safe
to remove code delete events emitting code.

R=erik.corry@gmail.com
BUG=v8:1466
TEST=existing tests in test-profile-generator,test-cpu-profiler and mjsunit/tools

Review URL: http://codereview.chromium.org/7864017

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9275 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 11:47:03 +00:00
yangguo@chromium.org
b910f4317e Reverting r9272.
Review URL: http://codereview.chromium.org/7889033

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9274 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 11:27:14 +00:00
keuchel@chromium.org
a392f5bf70 Fix scope iteration when debugging global code.
TEST=mjsunit/debug-scopes.js

Review URL: http://codereview.chromium.org/7890007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9273 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 11:20:31 +00:00
yangguo@chromium.org
9d235c9dd7 Fixed broken readline console history.
Review URL: http://codereview.chromium.org/7888035

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9272 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 11:05:07 +00:00
kmillikin@chromium.org
7f28e975e5 MIPS: port Remove in-loop tracking for call ICs.
port r9260 (af9cfd83).

Original commit message:
We passed this flag around in a lot of places and had differenc call
ICs based on it, but never did any real specialization based on its
value.

BUG=
TEST=

Committed: http://code.google.com/p/v8/source/detail?r=9269

Review URL: http://codereview.chromium.org/7886028
Patch from Paul Lind <plind44@gmail.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9271 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 08:11:16 +00:00
kmillikin@chromium.org
63bec78428 Revert "MIPS: port Remove in-loop tracking for call ICs."
Committed incorrectly.

TBR=ricow@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7890026

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9270 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 08:08:16 +00:00
kmillikin@chromium.org
f9e2922b12 MIPS: port Remove in-loop tracking for call ICs.
port r9260 (af9cfd83).

Original commit message:
We passed this flag around in a lot of places and had differenc call
ICs based on it, but never did any real specialization based on its
value.

BUG=
TEST=

Review URL: http://codereview.chromium.org/7886028
Patch from Paul Lind <plind44@gmail.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9269 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 08:04:47 +00:00
rossberg@chromium.org
40880d3206 Fixed spurious character in test case, plus presubmit issues.
Also addressed Slava's complaint about the personalized comment.

R=jkummerow@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7886032

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9268 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-14 07:30:51 +00:00
rossberg@chromium.org
28f7136ced Fix for .bind regression.
R=jkummerow@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7892013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9267 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 17:14:39 +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
9ca9cdfbf6 Debugger: fix stepping next with trycatch recursion
Added depth check to StepNextContinue. Do step out and queue actual StepNext if check failed.

R=yangguo@chromium.org,danno@chromium.org,vegorov@chromium.org
BUG=v8:1639
TEST=

Review URL: http://codereview.chromium.org/7780033
Patch from Fedor Indutny <fedor@indutny.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9264 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 14:38:39 +00:00
yangguo@chromium.org
8a4a737aef Fixing r9262 for shared library build.
Review URL: http://codereview.chromium.org/7888013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9263 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 14:31:54 +00:00
yangguo@chromium.org
113434a6e6 Fixing parallel execution in d8 (with -p) and some memory leaks.
Review URL: http://codereview.chromium.org/7891005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9262 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 13:16:13 +00:00
rossberg@chromium.org
ff5c242a47 Test (and fix) all exception paths that can occur with proxies.
R=kmillikin@chromium.org
BUG=v8:1543
TEST=

Review URL: http://codereview.chromium.org/7623013

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9261 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 13:07:20 +00:00
kmillikin@chromium.org
40cd59f238 Remove in-loop tracking for call ICs.
We passed this flag around in a lot of places and had differenc call
ICs based on it, but never did any real specialization based on its
value.

R=fschneider@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7869009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9260 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 12:53:28 +00:00
danno@chromium.org
aa00dbdc40 MIPS: pre-crankshaft updates to assembler and related files. (1/3)
Highlights:
- assembler.h adds FPU definitions used for Crankshaft.
- Support optimization of mips call: jalr->jal
    - includes changes to  set_target_address_at(), support routines.
    - Add 2nd use of Apply() to update target addresses.
- Minor debugging improvement in simulator.

BUG=
TEST=

Review URL: http://codereview.chromium.org/7888003
Patch from Paul Lind <plind44@gmail.com>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9259 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 12:12:25 +00:00
rossberg@chromium.org
e645597aa7 Implement function proxies (except for their use as constructors).
Introduce new %Apply native.

Extend Execution::Call to optionally handle receiver rewriting (needed for %Apply).

Fix Function.prototype.bind for functions that have .apply modified.

R=kmillikin@chromium.org
BUG=v8:1543
TEST=

Review URL: http://codereview.chromium.org/7623011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9258 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 11:42:57 +00:00
fschneider@chromium.org
19b5f44712 Fix presubmit.
TBR=whesse@chromium.org
Review URL: http://codereview.chromium.org/7888008

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9257 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 10:29:11 +00:00
jkummerow@chromium.org
9ae5798562 push-to-trunk.sh: correctly detect existing branches, git-rm deleted files
Review URL: http://codereview.chromium.org/7886004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9256 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 10:08:45 +00:00
mstarzinger@chromium.org
aae949ba10 Fix parent of the WeakMap prototype.
R=rossberg@chromium.org
BUG=v8:1565
TEST=mjsunit/harmony/weakmaps

Review URL: http://codereview.chromium.org/7890003

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9254 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 09:45:10 +00:00
fschneider@chromium.org
e74033d9cc Fix some valgrind errors in d8 shell.
This fixes 3 possibly lost warnings occurring when running unit tests under d8:

 28 bytes in 1 blocks are possibly lost in loss record 40 of 68
  at 0x67FB8DB: operator new[](unsigned int)
  by 0x83865CC: v8::Shell::SetOptions(int, char**) (d8.cc:1200)
  by 0x83869A5: v8::Shell::Main(int, char**) (d8.cc:1276)
  by 0x8386B31: main (d8.cc:1333)
Review URL: http://codereview.chromium.org/7780032

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9252 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 09:31:41 +00:00
sgjesse@chromium.org
81df4a42e4 Support for precise stepping in functions compiled before debugging was started (step 1)
This change will ensure that all non-optimized code will be compiled
with debug break slots when debugging is initiated. This is handled by
scanning the heap for non-optimized functions without debug break slots and setting their code to be lazy recomplied. When the lazy recompilation happens the code will ge generated with debug break slots (if debugging is still active at that point in time).

R=svenpanne@chromium.org
Currently this is only implemented for functions which do not have activations on the stack.

BUG=
TEST=

Review URL: http://codereview.chromium.org//7839030

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9250 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 08:31:21 +00:00
kmillikin@chromium.org
f6887702fb Prepare push to trunk. Now working on version 3.6.4.
R=jkummerow@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7892002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9247 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 08:06:55 +00:00
kmillikin@chromium.org
e9c6a554fc Revert "Clean up Context::Lookup and its uses."
This reverts commit 9241.  This change shows failures on Mac and Win
for the threading tests.  Reverting while I investigate.

R=fschneider@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7886002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9246 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-13 07:51:22 +00:00
svenpanne@chromium.org
130b9d7858 Improved pretty printing of VAR PROXY and some control flow AST nodes.
Review URL: http://codereview.chromium.org/7866041

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9245 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 14:00:16 +00:00
jkummerow@chromium.org
db2bac3847 d8 external array c'tors: fix double-to-uint32 semantics
TEST=mjsunit/external-array

Review URL: http://codereview.chromium.org/7866040

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9244 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 13:36:43 +00:00
jkummerow@chromium.org
3ec371690c d8 external array c'tors: allow parameters that can be converted to numbers
BUG=v8:1681
TEST=d8 accepts: var a = new Int32Array("2");

Review URL: http://codereview.chromium.org/7867036

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9243 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 12:42:05 +00:00
kmillikin@chromium.org
2ebe8039ac Add an explicit cast for an integral promotion that MSVC warns about.
I don't think the warning is valid, but it's a good sign that MSVC is
fixin' to generate the wrong code no matter what I think.

R=ricow@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7869008

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9242 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 12:16:30 +00:00
kmillikin@chromium.org
c0491e712d Reapply "Clean up Context::Lookup and its uses."
With a fix for a context lookup bug in the original change.

R=fschneider@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7862032

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9241 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 12:13:00 +00:00
kmillikin@chromium.org
636991a0b3 Use the BitField class for Code::Flags.
Use the BitField helper class for the code flags, so that we do not have to
define both a shift and a mask explicitly.  This makes changing the flags
layout simpler.

Also, make the 'mask' and 'max' members of BitField into constants, because
they are constant and so that they can be used as constant expressions.
E.g., so they can be used in declaring other const members or in static
asserts.

R=fschneider@chromium.org
BUG=
TEST=

Review URL: http://codereview.chromium.org/7787028

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9232 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 10:50:50 +00:00
mikhail.naganov@gmail.com
57b9e9d968 Revert accidental r9229 and r9230
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9231 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 10:50:40 +00:00
mikhail.naganov@gmail.com
03d325da08 add test
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9230 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 10:42:25 +00:00
mikhail.naganov@gmail.com
81ebd86817 do not use code deletions
git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9229 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 10:42:15 +00:00
mikhail.naganov@gmail.com
4d89e379bb Fix the include guard from circular-queue-inl.h
R=mnaganov@chromium.org

Review URL: http://codereview.chromium.org/7864028
Patch from Thiago Farina <tfarina@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9228 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-09-12 10:24:18 +00:00