Commit Graph

7330 Commits

Author SHA1 Message Date
mstarzinger@chromium.org
ac712f13c3 Fix evaluation order of GT and LTE operators.
According to the ES5 spec all ">" and "<=" expressions should be be
evaluated left-to-right. This obsoletes old hacks for reversing the
order to be ES3 compliant.

R=lrn@chromium.org
BUG=v8:1752

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9641 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-17 07:43:40 +00:00
svenpanne@chromium.org
a8bb36f87b Revert r9612, it hits an assertion under special circumstances.
Problematic code is e.g.:

   function typeofViaVariable() {
     var foo = typeof({})
     return foo === "undefined";
   }
Review URL: http://codereview.chromium.org/8283036

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9640 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 15:02:19 +00:00
svenpanne@chromium.org
8856b62331 Fixed printing of HTypeofIsAndBranch instruction for non-ASCII type literals.
Review URL: http://codereview.chromium.org/8291004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9639 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 13:16:23 +00:00
fschneider@chromium.org
948a323819 Revert r9619.
It causes an assertion with deoptimizing from inlined code.
Review URL: http://codereview.chromium.org/8277034

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9636 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 12:26:29 +00:00
fschneider@chromium.org
c68fc4126f Revert last revert.
TBR=whesse@chromium.org
Review URL: http://codereview.chromium.org/8286023

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9635 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 12:03:53 +00:00
fschneider@chromium.org
85ab75df50 Revert r9619.
TBR=whesse@chromium.org
Review URL: http://codereview.chromium.org/8286022

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9633 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 11:56:07 +00:00
erik.corry@gmail.com
c808a6449e Avoid extra GCs when deserializing during incremental marking.
Review URL: http://codereview.chromium.org/8276030

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9626 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 10:52:30 +00:00
ricow@chromium.org
2a4245e0c0 Fix available new space memory statistics reporting.
We currently report how much memory is available without changing page, i.e., the actual amount of available memory is not correctly stated for new space when doing --trace-gc.
Review URL: http://codereview.chromium.org/8275026

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9624 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 09:25:10 +00:00
erik.corry@gmail.com
1959359ab2 Speed up cloning objects by avoiding a write barrier check.
Review URL: http://codereview.chromium.org/8274032

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9622 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 09:20:19 +00:00
ricow@chromium.org
fe74726099 Remove timeout test expectation for OutOfMemoryNested
This has already been fixed, we not actually use the constraints.
Review URL: http://codereview.chromium.org/8276029

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9620 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 09:10:29 +00:00
fschneider@chromium.org
34534588fb Fix a number of bugs with inlining calls as function.
1. Record AST id for CallFunctionStub.

2. Correctly extract cached target from CallFunctionStub inline cache.

3. Fix a bug when inling call as a function in effect or value context:
   Handle abnormal exits correcty.

4. Fix a bug when inlining call as a function in test context: drop function
   correctly from true and false block.

5. Avoid inlining mutually recursive functions by checking the stack of function
   states before inlining. This was not a bug, but is just a more general
   check to avoid recursive inlining.
Review URL: http://codereview.chromium.org/8258012

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9619 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 08:43:27 +00:00
fschneider@chromium.org
212e4ae7d4 Eliminate write barrier for global stores at compile time if value stored is a smi.
Omit smi check inside write barriers if the value is known to be a heap object.

Refine inferred types of some instructions.
Review URL: http://codereview.chromium.org/8256016

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9618 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 07:45:18 +00:00
ulan@chromium.org
168b13b6d9 Ignore flags with arguments in preparser-process.
Currently, preparser-process crashes when given flags with arguments (e.g. --gc_interval 10). It can be fixed by ignoring everything in the command line except the "throws" command and its immediate arguments. This assumes that no flags appear between "throws" and its arguments.

TEST=make ia32.release.check TESTFLAGS="preparser --special-command=\"@ --gc_interval 10\""

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9617 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 07:34:45 +00:00
danno@chromium.org
b86db3d73e MIPS: fix build breakage due to r9607, faster slow asserts.
BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9616 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-14 07:08:20 +00:00
yangguo@chromium.org
b095a94b85 Adding missing hole check to FixedDoubleArray::Initialize
Review URL: http://codereview.chromium.org/8281001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9615 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 16:36:20 +00:00
vegorov@chromium.org
b182baf350 Return empty HeapStatistics for uninitialized isolate.
R=danno@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9614 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 16:11:18 +00:00
rossberg@chromium.org
4753976194 Fix handling of this in direct calls to function proxies.
Fix & tweak some proxy-related error messages.

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

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9613 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 15:55:57 +00:00
svenpanne@chromium.org
baa29ebafa Recognize special comparisons via pattern matching on the hydrogen graph.
Previously, comparisons against null/undefined and comparisons of the result of
typeof against a constant string were done syntactically. Now we do this via
pattern matching on the hydrogen graph, which opens up more opportunities for
better code generation, e.g. the following comparisons are now recognized to be
special:

   var bar = typeof foo;
   var baz = "undefined";
   if (bar == baz) ...

   var blah = undefined;
   if (hurz == blah) ...

If we did this handling of special cases even later at lithium generation time,
even more cases could be recognized, but this would involve bigger changes and
this CL handles most common cases.
Review URL: http://codereview.chromium.org/8242002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9612 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 15:07:28 +00:00
fschneider@chromium.org
ba981deab0 Always limit inlining depth to avoid taking too much time for --stress-opt runs.
We run with --nolimit-inlining when --stress-opt is on.
Review URL: http://codereview.chromium.org/8267007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9610 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 13:41:47 +00:00
mstarzinger@chromium.org
a68a57d51b Put store buffer verification behind a flag.
R=erik.corry@gmail.com

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9609 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 12:44:52 +00:00
yangguo@chromium.org
00a5287d2f Fixing test failures in arm and x64 due to missing implementation introduced in r9605.
Review URL: http://codereview.chromium.org/8261007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9608 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 12:03:33 +00:00
erik.corry@gmail.com
6f6d744115 Faster slow asserts.
Review URL: http://codereview.chromium.org/8267004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9607 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 11:54:19 +00:00
erik.corry@gmail.com
1cca5468aa Remove some asserts to speed up debug mode.
Review URL: http://codereview.chromium.org/8256012

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9606 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 11:50:00 +00:00
yangguo@chromium.org
fae807b3bb Elements kind conversion in generated code (ia32).
BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9605 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 10:53:31 +00:00
rossberg@chromium.org
87f3ff1ea0 Preparing push to trunk for 3.7.0
Review URL: http://codereview.chromium.org/8262010

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9602 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 09:40:55 +00:00
danno@chromium.org
16a89e8246 MIPS: port all relevant commits since the new-gc was landed.
This ports the following list of commits to mips. It is provided in this form
so that the mips port of the new-gc can be easily tested on your end.

This must be downloaded or landed after http://codereview.chromium.org/8106002
This is based on r9585. With these two mips commits, all tests are passing.

9319    Fix a harmless assert and a genuine bug in the GC-safety of stub generation ...
9329    ARM: Pregenerate some stubs that we call from other stubs.
9335    Initialize pre-allocated fields of JSObject with undefined.
9344    Put back the asserts in RememberedSetHelper, but correct this time
9370    Reorganize object type enum, such that proxies are no longer in the middle...
9392    Basic support for tracking smi-only arrays on ia32.
9402    Notify collector about lazily deoptimized code objects.
9411    Porting r9392 to arm (smi-only arrays).
9418    Small refactor to KeyedStoreIC::GenerateGeneric to make it slightly faster.
9447    Tighten up assertions checking GC-safety of stub calls.
9449    Record function call targets, use them for inlining.
9459    Make sure we don't flush the pregenerated stubs, since they need to b
9461    Fix the build on ARM
9466    Move the is_pregenerated flag so it does not overlap other flags....
9468    Fix the no-VFP3 build on ARM.
9475    Pass correct anchor_slot for EMBEDDED_OBJECT pointers from
9490    Adjust assertions in UpdateSlot to match UpdatePointer in PointersUpdatingVisitor.
9511    Clean list of external references from internal objects like the hole value.

9514    Simplify compares in KeyedStoreIC::GenerateGeneric.
9531    Porting r9456 to arm (Optimize KeyedStoreGeneric for Smi arrays).
9541    Fix load of potentially eval-shadowed let bindings.
9542    Fast allocation of block contexts.
9553    Activate smi-only optimizations for large array literals.

9575    Move declaration of SerializedScopeInfo from variables.h to objects.h
9577    Track elements_kind transitions in KeyedStoreICs.
9583    Fixing a bug in arm as pointed out in issue 1759.
9584    Refactor and fix polymorphic KeyedStoreIC creation.

BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9601 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 08:00:10 +00:00
danno@chromium.org
4f7d11f963 MIPS: port Merge experimental/gc branch to the bleeding_edge.
Simplified based on Michael's change Refactor how embedded pointers are visited. (9597)

Ported r9328 (bdc13b7)

BUG=
TEST=

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9600 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 07:35:38 +00:00
jkummerow@chromium.org
6112eb9bda Change type=settings to type=none for gyp targets
TEST=Compiling Chromium with -Duse_system_v8 no longer prints a GYP warning about "invalid type 'settings'".

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9599 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-13 07:30:54 +00:00
yangguo@chromium.org
34c6ab82ea Fixing bug caused by missing smi-tag.
Review URL: http://codereview.chromium.org/8240007

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9598 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-12 16:00:59 +00:00
mstarzinger@chromium.org
1da890af54 Refactor how embedded pointers are visited.
This refactoring (almost) gets rid of the requirement to get the target
object address for an object pointer embedded in code objects. This is
not possible on MIPS as pointers are encoded using two instructions. All
usages of RelocInfo::target_object_address() are (almost) obsoleted by
this change. The serializer still uses it, so MIPS will not yet work
with snapshots turned on.

R=danno@chromium.org,vegorov@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9597 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-12 15:43:41 +00:00
mstarzinger@chromium.org
d32c330ecf Fix special handling of DefineOwnProperty on arrays.
According to the ES5 spec the implementation of DefineOwnProperty() has
to special case handling of arrays. This is a preliminary implementation
correctly handling definition of array index properties, defining length
properties is not completely covered yet.

R=rossberg@chromium.org
TEST=test262

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9596 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-12 14:47:13 +00:00
yangguo@chromium.org
298e0a9862 Tentatively enabling string slices.
Review URL: http://codereview.chromium.org/8229009

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9590 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-12 12:30:30 +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
vegorov@chromium.org
819323f29f Runtime_NotifyDeoptimized should search for function activation in all thread stacks.
R=fschneider@chromium.org
BUG=v8:1763

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9588 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-12 10:35:42 +00:00
mstarzinger@chromium.org
554a12fbbc Fix free list node ending up on evacuation candidate.
This is a temporary fix which avoids compaction when incremental marking
is restarted during an old-space-step. That could turn the page that
holds the chosen free list node into an evacuation candidate. It could
also cause several other inconsistencies if it happens during scavenge.

R=vegorov@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9585 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 16:50:58 +00:00
jkummerow@chromium.org
312c534a6c Refactor and fix polymorphic KeyedStoreIC creation
Review URL: http://codereview.chromium.org/8233011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9584 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 16:02:45 +00:00
yangguo@chromium.org
cef39a6657 Fixing a bug in arm as pointed out in issue 1759.
BUG=v8:1759

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9583 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 15:56:06 +00:00
erik.corry@gmail.com
3ce33aacc6 New flag --stress-compaction
Review URL: http://codereview.chromium.org/8234002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9582 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 15:52:15 +00:00
erik.corry@gmail.com
95efb334ac Revert inadvertent changes to the spinning balls tool.
Review URL: http://codereview.chromium.org/8230010

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9581 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 11:43:48 +00:00
vegorov@chromium.org
4deaad3ccc Adjust assertions in the incremental marking.
Now we are completely transfering marks when shifting arrays in-place.

This might lead to white free space objects in the marking deque.

R=mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9580 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 11:38:00 +00:00
erik.corry@gmail.com
ba8a7f374e Add --noclever-optimizations to disable some things that have
caused trouble in the past.
Review URL: http://codereview.chromium.org/8229005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9579 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 11:35:04 +00:00
jkummerow@chromium.org
ddacdf847b Make elements_kind map transition test conditional on smi element support
TEST=mjsunit/element-kind passes even without --smi-only-arrays

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9578 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 10:02:42 +00:00
jkummerow@chromium.org
184fdcf28b Track elements_kind transitions in KeyedStoreICs.
Review URL: http://codereview.chromium.org/8166017

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9577 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 09:33:00 +00:00
erik.corry@gmail.com
f900fc9d80 Remove some unused and unneeded flags.
Review URL: http://codereview.chromium.org/8228004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9576 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 09:28:06 +00:00
fschneider@chromium.org
876fa09feb Move declaration of SerializedScopeInfo from variables.h to objects.h
This eliminates compile-errors when assigning Handle<SerializedScopeInfo> to
Handle<Object> in a place where the declaration was not available because
variables.h was not included.

As a result I had to also move the enum Variable::Mode to v8globals.h and
rename it to VariableMode.
Review URL: http://codereview.chromium.org/8221004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9575 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-11 08:41:19 +00:00
yangguo@chromium.org
17a68e1cfb Fixing assertion.
R=mstarzinger@chromium.org

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9574 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-10 16:18:20 +00:00
yangguo@chromium.org
3249530ef0 Fixing issue 1757 (string slices of external strings).
BUG=v8:1757
TEST=regress-1757.js

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

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9573 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-10 16:09:03 +00:00
vegorov@chromium.org
fd46247039 Add hinting to improve ASLR for macos (all allocations) and linux (newly added allocation types).
TEST=N/A
BUG=1749

Review URL: http://codereview.chromium.org/8115014
Patch from Cris Neckar <cdn@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9572 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-10 14:17:42 +00:00
svenpanne@chromium.org
2d691d4cdd Prepare push to trunk. We are now working on 3.6.7.
Review URL: http://codereview.chromium.org/8220002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9569 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-10 13:14:49 +00:00
yangguo@chromium.org
6792016261 Disabling string slices.
Review URL: http://codereview.chromium.org/8217006

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9568 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2011-10-10 12:17:50 +00:00