Commit Graph

23176 Commits

Author SHA1 Message Date
sergiyb
9088719ee5 Converted V8 CQ config to proto-format
This will land with https://chromereviews.googleplex.com/202967013

R=akuegel@chromium.org, machenbach@chromium.org
BUG=471767
NOTRY=true
LOG=N

Review URL: https://codereview.chromium.org/1161873004

Cr-Commit-Position: refs/heads/master@{#28684}
2015-05-28 15:02:53 +00:00
mvstanton
3a1d7335cf Make KeyedStores from a sloppy arguments array use a handler.
This finishes up work begun by CL (https://codereview.chromium.org/546683003/) some months ago.

BUG=

Review URL: https://codereview.chromium.org/1149053004

Cr-Commit-Position: refs/heads/master@{#28683}
2015-05-28 14:56:15 +00:00
bmeurer
dd430071e2 [turbofan] Simplify graph construction for for-in.
This is an initial step towards a faster and less incorrect
implementation of for-in in TurboFan.

R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1153403002

Cr-Commit-Position: refs/heads/master@{#28682}
2015-05-28 14:01:31 +00:00
mstarzinger
d8b94f34cc [turbofan] Introduce prediction for exception handlers.
This introduces a conservative prediction for each exception handler
whether it will locally catch an exception or re-throw it to outside
the code bondaries. It will allow for a more intuitive prediction of
whether an exception is considered "caught" or "uncaught".

R=bmeurer@chromium.org,yangguo@chromium.org
BUG=chromium:492522
LOG=N

Review URL: https://codereview.chromium.org/1158563008

Cr-Commit-Position: refs/heads/master@{#28681}
2015-05-28 13:23:03 +00:00
erikcorry
9079b99ad4 grokdump.py: work around int size limits on xrange
R=hpayer@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1158933007

Cr-Commit-Position: refs/heads/master@{#28680}
2015-05-28 13:12:17 +00:00
machenbach
5effc7131a [test] Fix assert for predictable mode in test runner.
NOTRY=true

Review URL: https://codereview.chromium.org/1156663009

Cr-Commit-Position: refs/heads/master@{#28679}
2015-05-28 13:06:49 +00:00
jochen
5df3b4ab5c Update all callsites of the TryCatch ctor to pass an Isolate
BUG=4134
R=vogelheim@chromium.org
LOG=n

Review URL: https://codereview.chromium.org/1154423004

Cr-Commit-Position: refs/heads/master@{#28678}
2015-05-28 12:49:41 +00:00
bmeurer
ce2b39f2f2 [turbofan] Record SharedFunctionInfo of inlined functions.
We need the shared function info of inlined functions to prevent code
flushing for their unoptimized code, and also to make sure that liveedit
can find the proper functions to deoptimize.

R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1156403002

Cr-Commit-Position: refs/heads/master@{#28677}
2015-05-28 12:12:52 +00:00
machenbach
77b7b39b4e [test] Use instrumented libc++ for asan and tsan builds.
BUG=chromium:489254
LOG=n

Review URL: https://codereview.chromium.org/1143173005

Cr-Commit-Position: refs/heads/master@{#28676}
2015-05-28 11:50:55 +00:00
bmeurer
b1e2d1e4c7 [deoptimizer] Materialize double values as smis whenever possible.
R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1156393002

Cr-Commit-Position: refs/heads/master@{#28675}
2015-05-28 10:31:03 +00:00
bmeurer
b77df02713 [turbofan] Remove the JSGraph dependency from the ControlFlowOptimizer.
The control flow optimization should work independent of the JSGraph. We
used the JSGraph there because it was convinient, not because it was
necessary.

R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1160863003

Cr-Commit-Position: refs/heads/master@{#28674}
2015-05-28 09:13:05 +00:00
bmeurer
19482d29e5 [turbofan] Remove the useless SimplifiedOperatorReducer.
The SimplifiedOperatorReducer is (mostly) unused, except for the very
rough store elimination, and just eats compilation time.

R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1162563002

Cr-Commit-Position: refs/heads/master@{#28673}
2015-05-28 08:38:13 +00:00
bmeurer
388e791df9 [crankshaft] Record inlined shared function infos instead of closures.
The list of inlined functions is used in exactly two places - for live
edit and to prevent code flushing for inlined functions - and those are
fine with SharedFunctionInfo and don't require a closure.

This is one additional step towards inlining based on SharedFunctionInfo
instead of JSFunction.

R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1145893003

Cr-Commit-Position: refs/heads/master@{#28672}
2015-05-28 07:12:04 +00:00
yangguo
dc9f0d4642 Throw illegal exception when formatting with invalid template index.
R=arv@chromium.org
BUG=chromium:492526
LOG=N

Review URL: https://codereview.chromium.org/1146923004

Cr-Commit-Position: refs/heads/master@{#28671}
2015-05-28 07:05:12 +00:00
yangguo
36d8363c1c Do not eagerly convert exception to string when creating a message object
R=mstarzinger@chromium.org
BUG=chromium:490680
LOG=Y

Review URL: https://codereview.chromium.org/1157563005

Cr-Commit-Position: refs/heads/master@{#28670}
2015-05-28 06:30:14 +00:00
bmeurer
a06631e9eb [turbofan] Remove frame state TODOs from VisitForInBody.
Neither the increment nor the comparison can deoptimize, so we don't
need proper frame states there.

R=jarin@chromium.org

Review URL: https://codereview.chromium.org/1148323003

Cr-Commit-Position: refs/heads/master@{#28669}
2015-05-28 04:10:52 +00:00
v8-autoroll
3503d1ef07 Update V8 DEPS.
Rolling v8/build/gyp to 29e94a3285ee899d14d5e56a6001682620d3778f

Rolling v8/tools/clang to dc8f173e7fe10badbd9e29cd6eadc32ec552e691

TBR=machenbach@chromium.org

Review URL: https://codereview.chromium.org/1156373003

Cr-Commit-Position: refs/heads/master@{#28668}
2015-05-28 03:28:41 +00:00
akos.palfi
79eb72c648 Skip simdjs/shell_test_runner on big-endian platforms.
This test is little-endian specific and therefore it can't run
correctly on big-endian platforms.

BUG=

Review URL: https://codereview.chromium.org/1155113008

Cr-Commit-Position: refs/heads/master@{#28667}
2015-05-27 18:55:55 +00:00
mbrandy
e95a225646 PPC: VectorICs: allocating slots for store ics in ast nodes.
Port 5450fc07ba

Original commit message:
Also adapt code generation to pass the slot to the
store/keyed-store ic. AST nodes ObjectLiteral, Assignment,
ForEach, Call and CountOperation now include one or more
feedback vector ic slot ids.

R=mvstanton@chromium.org, dstence@us.ibm.com, michael_dawson@ca.ibm.com
BUG=

Review URL: https://codereview.chromium.org/1156503003

Cr-Commit-Position: refs/heads/master@{#28666}
2015-05-27 17:26:27 +00:00
mbrandy
4070b20aee PPC: [es6] Support super.property in eval and arrow functions
Port 44e9810345

Original commit message:
When we enter a method that needs access to the [[HomeObject]]
we allocate a local variable `.home_object` and assign it the
value from the [[HomeObject]] private symbol. Something along
the lines of:

  method() {
    var .home_object = %ThisFunction()[home_object_symbol];
    ...
  }

R=arv@chromium.org, dstence@us.ibm.com, michael_dawson@ca.ibm.com
BUG=

Review URL: https://codereview.chromium.org/1161603004

Cr-Commit-Position: refs/heads/master@{#28665}
2015-05-27 17:22:05 +00:00
conradw
629d275073 [strong] Implement per-object restrictions behaviour for prototype setting
Implements the strong mode proposal's restrictions on the ability of user code
to modify the prototype of strong objects.

Setting the strong bit is still wip, so this change will only affect those
objects that have the bit correctly set. The tests reflect this, and will be
expanded as more objects can be marked as strong.

BUG=v8:3956
LOG=N

Review URL: https://codereview.chromium.org/1143623002

Cr-Commit-Position: refs/heads/master@{#28664}
2015-05-27 17:06:43 +00:00
machenbach
a814516a08 [test] Add sanitizer coverage to gyp configs.
BUG=chromium:489254
LOG=n

Review URL: https://codereview.chromium.org/1158903002

Cr-Commit-Position: refs/heads/master@{#28663}
2015-05-27 16:18:33 +00:00
ulan
92855aed25 Fix cctest/test-unboxed-doubles/IncrementalWriteBarrierObjectShiftFieldsRight after 5e87a0.
Make sure that when manual evacuation candidate selection is enabled we do not select more pages than requested.
BUG=

TBR=hpayer@chromium.org

Review URL: https://codereview.chromium.org/1157293002

Cr-Commit-Position: refs/heads/master@{#28662}
2015-05-27 16:09:13 +00:00
vogelheim
21e6831ee0 Fix DCHECK on SetBookmark.
The DCHECK was a lie. The idea was that - when a bookmark is set -
the scanner must clearly be at a character boundary and hence the
bookmark does not need to save a 'partial' UTF-8 code point. The
first part is true - the Scanner is always at a character boundary -
but the 'partial' UTF-8 code point is at the end of a block, not at
the current character position of the Scanner.
Hence, the 'partial' character needs to be saved as well.

jkummerow: Thanks for noticing.

BUG=chromium:470930
R=jochen@chromium.org, jkummerow@chromium.org
LOG=N

Review URL: https://codereview.chromium.org/1154773004

Cr-Commit-Position: refs/heads/master@{#28661}
2015-05-27 15:43:42 +00:00
jochen
2a058de88f Introduce v8::Object::CreateDataProperty
Also deprecate ForceSet

BUG=chromium:475206
R=adamk@chromium.org,verwaest@chromium.org
LOG=y

Review URL: https://codereview.chromium.org/1154233003

Cr-Commit-Position: refs/heads/master@{#28660}
2015-05-27 15:03:35 +00:00
mvstanton
5450fc07ba VectorICs: allocating slots for store ics in ast nodes.
Also adapt code generation to pass the slot to the
store/keyed-store ic. AST nodes ObjectLiteral, Assignment,
ForEach, Call and CountOperation now include one or more
feedback vector ic slot ids.

BUG=

Review URL: https://codereview.chromium.org/1161623002

Cr-Commit-Position: refs/heads/master@{#28659}
2015-05-27 14:26:25 +00:00
hpayer
42fc431078 Treat weak references in context weakly in write barrier.
BUG=

Review URL: https://codereview.chromium.org/1152153004

Cr-Commit-Position: refs/heads/master@{#28658}
2015-05-27 14:13:08 +00:00
v8-autoroll
dd75b607d9 Update V8 DEPS.
Rolling v8/buildtools to a85661f97e83c620a8a1d0255829eb7a674e12cc

TBR=machenbach@chromium.org

Review URL: https://codereview.chromium.org/1145043004

Cr-Commit-Position: refs/heads/master@{#28657}
2015-05-27 14:10:30 +00:00
machenbach
9cc183d899 Revert of Use CLOCK_REALTIME_COARSE when available. (patchset #1 id:1 of https://codereview.chromium.org/1151283005/)
Reason for revert:
[Sheriff] This leads to several failures in chromium and blocks our roll:
https://codereview.chromium.org/1154363002/

Bisect (https://codereview.chromium.org/1152553004/) points to this CL.

Please add the failing chromium trybot on a reland of this CL.

Original issue's description:
> Use CLOCK_REALTIME_COARSE when available.
>
> On systems that have CLOCK_REALTIME_COARSE with good enough resolution,
> we can avoid making a system call to get the current time; it's serviced
> from the vDSO.
>
> This is v2 of the patch.  v1 can be found at [0] but was reverted in [1]
> because of Chromium sandbox restrictions.  The necessary changes have
> been applied upstream in [2].
>
> [0] https://codereview.chromium.org/1125003002
> [1] https://codereview.chromium.org/1130083003
> [2] https://codereview.chromium.org/1133653002
>
> BUG=
> LOG=N
>
> Committed: https://crrev.com/28cea2b749f24ba33e6e0c8e343dd0d6258ee302
> Cr-Commit-Position: refs/heads/master@{#28639}

TBR=jochen@chromium.org,bmeurer@chromium.org,ben@strongloop.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/1154783003

Cr-Commit-Position: refs/heads/master@{#28656}
2015-05-27 14:06:00 +00:00
conradw
092acb2b96 [strong] fix strong array, object prototypes
Strong Object/Array literals are currently being created with incorrect
internal prototypes. This CL fixes this and extends the test suite to check.

BUG=
LOG=N

Review URL: https://codereview.chromium.org/1158933002

Cr-Commit-Position: refs/heads/master@{#28655}
2015-05-27 13:55:14 +00:00
machenbach
4d6f1abbdb [test] Remove default for zero test cases.
BUG=

Review URL: https://codereview.chromium.org/1153103003

Cr-Commit-Position: refs/heads/master@{#28654}
2015-05-27 13:50:48 +00:00
vegorov
e85f979ed3 gdb-v8-support.py: add FindAnywhere helper.
R=jkummerow@chromium.org
NOTRY=true

Review URL: https://codereview.chromium.org/1157683007

Cr-Commit-Position: refs/heads/master@{#28653}
2015-05-27 13:49:10 +00:00
hpayer
d8a82ed74c Scale old generation growing strategy based on allocation rate.
Before we used to scale the growing factor based on freed global handles (which may have caused jank when many global handles got freed on site navigation).

BUG=

Review URL: https://codereview.chromium.org/1158433003

Cr-Commit-Position: refs/heads/master@{#28652}
2015-05-27 13:09:20 +00:00
ulan
5e87a0997b New algorithm for selecting evacuation candidates
This lifts the sqrt(n) limit on number of evacuation candidates,
replaces O(n * sqrt(n)) algorithm with O(n*log(n)) algorithm, and
removes hard-coded constants.

Evacuation candidates are selected as follows:

1) Sort pages from the most free to the least free.

2) Select the first m pages as evacuation candidates such that m is as
large as possible under the two conditions:

- The total size of live objects in the first m pages does not exceed
the given limit. This is based on the assumption that the evacuation cost is
proportional to the total size of moved objects.

- The fragmentation of the (m+1)-th page does not exceed the given
limit.

Review URL: https://codereview.chromium.org/1038313003

Cr-Commit-Position: refs/heads/master@{#28651}
2015-05-27 13:07:52 +00:00
jkummerow
1fb83a2f02 [turbofan] Fix type feedback for JSStoreNamed
And delete remnants of non-vectorized LoadICs from the type feedback oracle

Review URL: https://codereview.chromium.org/1147253004

Cr-Commit-Position: refs/heads/master@{#28650}
2015-05-27 12:30:47 +00:00
bmeurer
7483dbd5fc [turbofan] Use Start as sentinel for frame states.
This simplifies inlining, in that we only need to update uses of Start
and inputs of End instead of walking the whole inlinee to update all
outer frame states.

R=mstarzinger@chromium.org

Review URL: https://codereview.chromium.org/1146403008

Cr-Commit-Position: refs/heads/master@{#28649}
2015-05-27 11:02:01 +00:00
bmeurer
cc2d376f11 [turbofan] Optimize && and || in test context.
R=mstarzinger@chromium.org

Review URL: https://codereview.chromium.org/1160683003

Cr-Commit-Position: refs/heads/master@{#28648}
2015-05-27 08:35:36 +00:00
vogelheim
dea59184cc Mark class as exported to fix win build.
TBR=machenbach@chromium.org
BUG=chromium:470930
LOG=N

Review URL: https://codereview.chromium.org/1149923006

Cr-Commit-Position: refs/heads/master@{#28647}
2015-05-27 07:10:45 +00:00
bmeurer
b66226a9d9 [turbofan] Optimize strict equality of unique values.
If both inputs to JSStrictEqual/JSStrictNotEqual are unique values (i.e.
values with a canonical representation), we can lower the comparison to
ReferenceEqual instead of StringEqual or CompareIC.

Review URL: https://codereview.chromium.org/1154303002

Cr-Commit-Position: refs/heads/master@{#28646}
2015-05-27 04:23:41 +00:00
v8-autoroll
496d3827ad Update V8 DEPS.
Rolling v8/third_party/icu to f1ad7f9ba957571dc692ea3e187612c685615e19

Rolling v8/tools/clang to dbc958e1b51949ca815ca31a8f9bf4a760ca1d35

TBR=machenbach@chromium.org

Review URL: https://codereview.chromium.org/1160693002

Cr-Commit-Position: refs/heads/master@{#28645}
2015-05-27 03:27:25 +00:00
arv
44e9810345 [es6] Support super.property in eval and arrow functions
When we enter a method that needs access to the [[HomeObject]]
we allocate a local variable `.home_object` and assign it the
value from the [[HomeObject]] private symbol. Something along
the lines of:

  method() {
    var .home_object = %ThisFunction()[home_object_symbol];
    ...
  }

BUG=v8:3867, v8:4031
LOG=N

Review URL: https://codereview.chromium.org/1135243004

Cr-Commit-Position: refs/heads/master@{#28644}
2015-05-26 20:29:54 +00:00
machenbach
2dda8c3d4e [test] Verbose test runner output on windows.
TBR=jkummerow@chromium.org
NOTRY=true

Review URL: https://codereview.chromium.org/1156133006

Cr-Commit-Position: refs/heads/master@{#28643}
2015-05-26 19:50:54 +00:00
adamk
cb07b8ef1a Add {Map,Set}::FromArray to the API
These are similar to the Map/Set constructors when called with an array,
except that they are guaranteed to be side-effect free if called with
a packed array.

This will be useful in implementing structured clone which, as
specified in HTML, speaks in terms of the internal [[MapData]]
and [[SetData]] slots without going through the exposed iteration
ES semantics.

BUG=v8:3340
LOG=y

Review URL: https://codereview.chromium.org/1155893003

Cr-Commit-Position: refs/heads/master@{#28642}
2015-05-26 18:50:23 +00:00
mike
f7b5912276 [es6] Define generator prototype as writable prop
The April 14 2015 final draft of the ES6 specification states that the
`prototype` property of generator function instances should be writable.

BUG=v8:4140, v8:4140
LOG=N
R=arv@chromium.org

Review URL: https://codereview.chromium.org/1153633003

Cr-Commit-Position: refs/heads/master@{#28641}
2015-05-26 18:31:49 +00:00
adamk
a8d9c58b1f Add {Map,Set}::AsArray to the API
These return arrays representing the current contents of the given
Map/Set. They are similar to what would be returned by the JS code:

  Array.from(collection)

except that they are guaranteed side-effect free.

This will be useful in implementing structured clone which, as
specified in HTML, speaks in terms of the internal [[MapData]]
and [[SetData]] slots without going through the exposed iteration
ES semantics.

BUG=v8:3340
LOG=y

Review URL: https://codereview.chromium.org/1148383007

Cr-Commit-Position: refs/heads/master@{#28640}
2015-05-26 18:13:32 +00:00
ben
28cea2b749 Use CLOCK_REALTIME_COARSE when available.
On systems that have CLOCK_REALTIME_COARSE with good enough resolution,
we can avoid making a system call to get the current time; it's serviced
from the vDSO.

This is v2 of the patch.  v1 can be found at [0] but was reverted in [1]
because of Chromium sandbox restrictions.  The necessary changes have
been applied upstream in [2].

[0] https://codereview.chromium.org/1125003002
[1] https://codereview.chromium.org/1130083003
[2] https://codereview.chromium.org/1133653002

BUG=
LOG=N

Review URL: https://codereview.chromium.org/1151283005

Cr-Commit-Position: refs/heads/master@{#28639}
2015-05-26 18:10:43 +00:00
hpayer
3e9c664b8c Fix overflow in allocation throughput calculation.
BUG=chromium:492021
LOG=n

Review URL: https://codereview.chromium.org/1148953009

Cr-Commit-Position: refs/heads/master@{#28638}
2015-05-26 17:46:57 +00:00
adamk
395fa8ba24 Add basic API support for Map & Set
Only supports constructing new objects and returning size.
Followup patch will need to add ability to retrieve and
set contents in order to support structured clone.

Also removes a bunch of outdated "experimental" markers from v8.h.

BUG=v8:3340
LOG=y

Review URL: https://codereview.chromium.org/1157453002

Cr-Commit-Position: refs/heads/master@{#28637}
2015-05-26 17:37:01 +00:00
mbrandy
a6676cfebd PPC: Vector ICs: Introduce Store and KeyedStore IC code stubs.
Port a86384f192

Original commit message:
Also introduce new interface descriptors for the trampoline and full
versions of those stubs.

Currently, the stubs aren't functional.

R=mvstanton@chromium.org, dstence@us.ibm.com, michael_dawson@ca.ibm.com
BUG=

Review URL: https://codereview.chromium.org/1159483003

Cr-Commit-Position: refs/heads/master@{#28636}
2015-05-26 15:51:07 +00:00
ulan
1999221f76 Fix windows builder after fe9a16b6.
TBR=hpayer@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/1161623003

Cr-Commit-Position: refs/heads/master@{#28635}
2015-05-26 15:48:32 +00:00