Commit Graph

25798 Commits

Author SHA1 Message Date
littledan
5c1ef6ac82 Make RegExp use ToLength on lastIndex when flag is turned on
In the ES2015 spec, RegExp uses ToLength, not ToInteger, on lastIndex
to coerce it to an integer. This patch switches to ToLength when
the --harmony-tolength flag is on, and adds some tests to verify the
new behavior.

BUG=v8:4244
LOG=Y
R=adamk

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

Cr-Commit-Position: refs/heads/master@{#31306}
2015-10-15 14:10:48 +00:00
mvstanton
31487015de VectorICs: turn on vectors for STORE and KEYED_STORE ics.
R=jkummerow@chromium.org
BUG=

Committed: https://crrev.com/52225f39df578e77b4804506ca4bc15e096f5cab
Cr-Commit-Position: refs/heads/master@{#31252}

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

Cr-Commit-Position: refs/heads/master@{#31305}
2015-10-15 13:35:17 +00:00
jkummerow
102e3e87e7 [arm64] Fix jssp based spill slot accesses in Crankshaft
Review URL: https://codereview.chromium.org/1401703003

Cr-Commit-Position: refs/heads/master@{#31304}
2015-10-15 13:34:15 +00:00
adamk
b646cb3e50 Take Symbol-keyed properties into account in Object.freeze and friends
R=rossberg@chromium.org
BUG=chromium:539875
LOG=y

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

Cr-Commit-Position: refs/heads/master@{#31303}
2015-10-15 13:32:57 +00:00
mstarzinger
2aba89e336 Remove bogus flags from call-counts.js test.
The runtime flag in question makes no sense, because the feature cannot
be disabled without keeping the snapshot in sync. We should avoid having
the flag in our "mjsunit" test suite, so that CluserFuzz doesn't pick it
up. The test in question is already skipped, the change will not affect
test results on our waterfall.

R=mvstanton@chromium.org
TEST=mjsunit/call-counts
BUG=v8:4458
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31302}
2015-10-15 13:31:57 +00:00
mlippautz
10019c2b05 [heap] Cleanup: Enforce coding style in FreeList and FreeListCategory
Also update comments.

BUG=

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

Cr-Commit-Position: refs/heads/master@{#31301}
2015-10-15 13:30:51 +00:00
bmeurer
23a8837fcc Revert of [turbofan] Splinter into one range. (patchset #2 id:80001 of https://codereview.chromium.org/1391023007/ )
Reason for revert:
Weird endless loop in TopLevelLiveRange::Merge() due to always splitting first and not making progress. See comments, unfortunately no useable repro.

Original issue's description:
> [turbofan] Splinter into one range.
>
> Before this CL, we created one live range per successive set of
> deferred blocks. For scenarios with many such blocks, this creates
> an upfront pressure for the register allocator to deal with many ranges.
> Linear sorts ranges, which is a super-linear operation.
>
> The change places all deferred intervals into one range, meaning that,
> at most, there will be twice as many live ranges as the original set. In
> pathological cases (benchmarks/Compile/slow_nbody1.js), this change
> halves the compilation time. We see some improvements elsewhere,
> notably SQLite at ~4-5%.
>
> We may be able to avoid the subsequent merge. Its cost is the
> additional ranges it may need to create. The sole reason for the merge
> phase is to provide an unchanged view of the world to the subsequent
> phases. With the at-most-one splinter model, we may be able to teach
> the other phases about splintering - should we find perf hindrances
> due to merging.
>
> Committed: https://crrev.com/efdcd20267870276c5824f1ccf4e171ac378f7ae
> Cr-Commit-Position: refs/heads/master@{#31224}

TBR=jarin@chromium.org,mtrofin@google.com,mtrofin@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#31300}
2015-10-15 13:28:20 +00:00
neis
2ed1eebe9f [es6] Implement Reflect.enumerate.
R=rossberg
BUG=v8:3931
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31299}
2015-10-15 12:59:37 +00:00
machenbach
0937cdbfbd Revert of [Interpreter] Support for operator new. (patchset #17 id:290001 of https://codereview.chromium.org/1402943002/ )
Reason for revert:
[Sheriff] Breaks arm64 debug:
http://build.chromium.org/p/client.v8/builders/V8%20Linux%20-%20arm64%20-%20sim%20-%20debug/builds/4595

Original issue's description:
> [Interpreter] Support for operator new.
>
> This change add a new bytecode for operator new and implements it using
> the Construct() builtin.
>
> BUG=v8:4280
> LOG=N
>
> Committed: https://crrev.com/8e4f9963d53913eab7fbd2f61a5733d8dc2169e7
> Cr-Commit-Position: refs/heads/master@{#31293}

TBR=rmcilroy@chromium.org,bmeurer@chromium.org,oth@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:4280

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

Cr-Commit-Position: refs/heads/master@{#31298}
2015-10-15 12:50:11 +00:00
danno
f4c9f2221b [turbofan]: Fix double register output in traces
Review URL: https://codereview.chromium.org/1404983002

Cr-Commit-Position: refs/heads/master@{#31297}
2015-10-15 12:28:39 +00:00
yangguo
73c9be9b31 Debugger: allow stepping into resolver from Promise constructor.
R=rossberg@chromium.org
BUG=chromium:451967
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31296}
2015-10-15 12:27:40 +00:00
ulan
dd3f1ecf71 Revert of Make dates default to the local timezone if none specified (https://codereview.chromium.org/1229903004/)
Even though the change is ES6 spec compliant, we decided to revert
to be consistent with other browsers and work on fixing the spec.

Original issue's description:
> Make dates default to the local timezone if none specified
>
> In ES5, dates were supposed to default to UTC if no timezone was specified. However, this changed in ES6, which specified that dates should be in the local timezone if no timezone was specified. This CL updates our behavior to match that part of the ES6 spec.

> BUG=chromium:391730, v8:4242
> LOG=Y

> Committed: https://crrev.com/f06754a8e1d305a43560705f6c167d85d40e602d
> Cr-Commit-Position: refs/heads/master@{#29854}

BUG=chromium:543320,chromium:539813
LOG=NO

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

Cr-Commit-Position: refs/heads/master@{#31295}
2015-10-15 12:18:16 +00:00
mstarzinger
e6a923ab56 [turbofan] Fix various issues with --turbo-inlining enabled.
This is in preparation to enabling --turbo-inlining by default, fixing
various issues when general purpose inlining is running against our
entire test suite.

R=bmeurer@chromium.org
BUG=v8:4493
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31294}
2015-10-15 12:02:06 +00:00
oth
8e4f9963d5 [Interpreter] Support for operator new.
This change add a new bytecode for operator new and implements it using
the Construct() builtin.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31293}
2015-10-15 11:51:05 +00:00
mlippautz
4a2f630fe8 [tools] Add ranking to GC NVP eval script
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31292}
2015-10-15 11:37:42 +00:00
machenbach
4da32d505f [test] Pull simdjs as a dependency.
BUG=chromium:535160
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31291}
2015-10-15 11:26:55 +00:00
hpayer
cad73fcbe4 [heap] Reland decrease large object limit for regular heap objects.
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31290}
2015-10-15 10:55:19 +00:00
littledan
b802051df2 Fix let pattern error accumulation
When the checker was added prohibiting lexical binding called let,
certain error propagation was not implemented properly. This patch
fixes that issue, which fixes error checking for cases such as
  let [let]

BUG=v8:4403
R=adamk
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31289}
2015-10-15 10:46:17 +00:00
rmcilroy
370984018f [Interpreter]: Add fake support for try/catch/finally.
Adds fake try/catch/finally support hidden behind the flag
--ignition-fake-try-catch.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31288}
2015-10-15 10:35:31 +00:00
adamk
4937cc9457 Remove unused Zone argument from InitializeAstVisitor
This adds a bit of boilerplate to some AstVisitors (they now have to
declare their own zone_ member and zone() accessor), but makes it clearer
what DEFINE_AST_VISITOR_SUBCLASS_MEMBERS is for: stack limit checking.

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

Cr-Commit-Position: refs/heads/master@{#31287}
2015-10-15 10:34:28 +00:00
bmeurer
ffd0a2ae74 [turbofan] Make native context specialization dependent on the typed pipeline.
Also refactor the JSGlobalSpecialization somewhat to reduce the amount
of duplicated code somewhat.

R=jarin@chromium.org
BUG=v8:4470
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31286}
2015-10-15 10:25:47 +00:00
yangguo
558f1441c6 Use import/export for more functions (instead of js builtins object).
R=cbruni@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31285}
2015-10-15 10:23:09 +00:00
mlippautz
5a3929ea4f Reland "Add bailout for large objects when allocating arrays in optimized code."
This reverts commit dc0adc5668.

NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#31284}
2015-10-15 09:54:49 +00:00
jarin
b79f00bcf6 [turbofan] Change deoptimization register allocator constraints to ANY.
Review URL: https://codereview.chromium.org/1398943003

Cr-Commit-Position: refs/heads/master@{#31283}
2015-10-15 09:52:29 +00:00
machenbach
3348efaa7b [test] Mark some test262 intl tests as failing.
BUG=v8:4437
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31282}
2015-10-15 09:35:24 +00:00
mythria
5a09f1b9a7 [Interpreter] Adds logical and/or and comma operators to interpreter
Adds support for following operators
 -Logical and
 -Logical or
 -Comma

Adds the above bytecodes, support to BytecodeGenerator and BytecodeArrayBuilder
to enable it's use, it's implementation and tests.

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31281}
2015-10-15 09:11:59 +00:00
yangguo
c7c7b598ee Serializer: remove unused --serialize-inner flag.
R=vogelheim@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31280}
2015-10-15 08:47:19 +00:00
yangguo
b6c945642c Native context: use import/export for Object observe related functions.
R=adamk@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31279}
2015-10-15 08:32:47 +00:00
littledan
dd24cc33d3 Check for let in lexically bound names for short object literals
An identifier may be parsed in an object literal like {let}, but
this was previously left out of lexical name checking. This patch
adds that check to prohibit code like
  let {let} = {let: 1}

BUG=v8:4403
LOG=N
R=adamk

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

Cr-Commit-Position: refs/heads/master@{#31278}
2015-10-15 07:52:20 +00:00
alph
ad1e057049 Revert of [x64] Use vcvtlsi2sd when AVX is enabled (patchset #1 id:1 of https://codereview.chromium.org/1404903004/ )
Reason for revert:
Caused a crash on Windows

Original issue's description:
> [x64] Use vcvtlsi2sd when AVX is enabled
>
> BUG=v8:4406
> LOG=N
>
> Committed: https://crrev.com/adcbe619a959fe1d8f21d06fbf5984868c4f6b9a
> Cr-Commit-Position: refs/heads/master@{#31276}

TBR=bmeurer@chromium.org,danno@chromium.org,yurys@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=v8:4406

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

Cr-Commit-Position: refs/heads/master@{#31277}
2015-10-15 06:08:52 +00:00
alph
adcbe619a9 [x64] Use vcvtlsi2sd when AVX is enabled
BUG=v8:4406
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31276}
2015-10-15 05:53:24 +00:00
alph
5cda2bcfab [x64] Use vmovapd and vmovsd when AVX is enabled.
R=bmeurer@chromium.org
BUG=v8:4406
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31275}
2015-10-15 04:15:00 +00:00
v8-autoroll
facf9953d2 Update V8 DEPS.
Rolling v8/buildtools to ef7f1f539cff0441c4401d8c052e54cfd01bff07

TBR=machenbach@chromium.org,vogelheim@chromium.org,hablich@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31274}
2015-10-15 03:25:07 +00:00
franziska.hinkelmann
8ed0454332 Emit better error message about writable properties
Section 8.10.5 9a specifies that a property descriptor cannot both have
accessors and specify the writability of the property. The previous
error message was misleading because it referred to writable rather
than specifying the writability (which includes writable: false).

BUG=v8:2536
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31273}
2015-10-14 19:22:27 +00:00
domenic
8f8457d2a4 Add methods to extras' InternalPackedArray
https://codereview.chromium.org/1343113003 introduced a separate InternalPackedArray constructor to the extras utils object, distinct from the one used by natives. However, it omitted the code to set up the methods for that InternalPackedArray. This makes all the basic manipulation methods available.

BUG=v8:4276
LOG=Y
R=jochen@chromium.org,yangguo@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31272}
2015-10-14 17:40:54 +00:00
caitpotter88
6b4d7f81a9 [es6] parse arrow ConciseBody with accept_IN flag
Fixes corner case where arrow function ConciseBody expression does not
accept 'in' in productions.

BUG=v8:4472
LOG=N
R=wingo@igalia.com, adamk@chromium.org, rossberg@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31271}
2015-10-14 17:39:52 +00:00
domenic
0db3710421 Put experimental extras through the same filters as non-experimental
When introducing experimental extras I forgot to update this check. That resulted in experimental extras running through the steps normally reserved for non-extra natives: macro and constant expansion, validation, and minification. This causes problems since per the linked bug minification is buggy.

R=yangguo@chromium.org, jochen@chromium.org
BUG=v8:4064
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31270}
2015-10-14 17:38:47 +00:00
littledan
ab3110e875 Add a lexical scope for the body of a with statement
For an edge case like the following in sloppy mode
  with ({}) function f() {}
a lexical scope needs to be created around the body in order
to hold the function declaration, so it can be hoisted according
to a loose interpretation of Annex B 3.3 (loose because ES2015
does not permit a function declaration as the body of a with
statement). This patch adds that scope.

BUG=chromium:542100
LOG=N
R=adamk

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

Cr-Commit-Position: refs/heads/master@{#31269}
2015-10-14 17:37:22 +00:00
littledan
d0618585a7 Fix scopes for body of sloppy-mode for-in/of loop
This patch fixes an obscure edge case for functions defined as the
direct body of a for-of/for-in loop, such as the following:

 for (foo in []) function foo() { return foo; }

Here, the first occurrence of foo should point to the outer scope;
however, before this patch, it pointed to the inner foo in an
invalid way which caused an assertion about the scope chain to fail.
This patch fixes the scope chain by inserting an extra scope for
the body of the loop, not including the header.

BUG=chromium:542099
LOG=N
R=rossberg

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

Cr-Commit-Position: refs/heads/master@{#31268}
2015-10-14 17:36:16 +00:00
machenbach
e6d45f1a78 [swarming] Isolate webkit and optimize_for_size.
BUG=chromium:535160
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31267}
2015-10-14 17:35:05 +00:00
machenbach
dc0adc5668 Revert of Add bailout for large objects when allocating arrays in optimized code. (patchset #1 id:1 of https://codereview.chromium.org/1408553002/ )
Reason for revert:
[Sheriff] Breaks deopt fuzzer:
http://build.chromium.org/p/client.v8/builders/V8%20Deopt%20Fuzzer/builds/5634

See comment in CL for repro.

Original issue's description:
> Add bailout for large objects when allocating arrays in optimized code.
>
> BUG=
>
> Committed: https://crrev.com/0c81c4e924d7bdb45fce98209c21985d754e047d
> Cr-Commit-Position: refs/heads/master@{#31259}

TBR=bmeurer@chromium.org,hpayer@chromium.org,mlippautz@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31266}
2015-10-14 15:04:19 +00:00
jarin
59c616ccd7 [turbofan] Introduce node regions for protection from scheduling.
This CL re-purposes ValueEffect and Finish as delimiters for regions
that are scheduled atomically (renamed to BeginRegion, FinishRegion).

The BeginRegion node takes and produces an effect. For the uses that do
not care about the placement in the effect chain, it is ok to feed
graph->start() as an effect input.

The FinishRegion takes a value and an effect and produces a value and
an effect. It is important that any value or effect produced inside the
region is not used outside the region. The FinishRegion node is the only
way to smuggle an effect and a value out.

At the moment, this does not support control flow inside the region. Control flow would be hard.

During scheduling we do some sanity check, but the checks are not exhaustive. Here is what we check:
- the effect chain between begin and finish is linear (no splitting,
  single effect input and output).
- any value produced is consumed by the FinishRegion node.
- no control flow outputs.

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

Cr-Commit-Position: refs/heads/master@{#31265}
2015-10-14 14:53:12 +00:00
rmcilroy
1919fa38c2 [Interpreter]: Fix ObjectLiterals test for arm64-sim-nosnap bot.
The AccessorsTable has a non-deterministic iteration order depending on the
random seed. This means that the order of the accessor defines could vary
and the test which tried to set accessors on two different properties
could flakly fail due to the order not being as expected. To fix this I make
the test only do a setter on one property (the test-interpreter.cc test
does the check on multiple property accessors

BUG=v8:4280
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#31264}
2015-10-14 14:52:12 +00:00
martyn.capewell
a456134b8b [turbofan] Negate with shifted input for ARM64
Support negate with shifted input on ARM64 by supporting lhs zero registers for
binary operations, and removing explicit Neg instruction support.

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

Cr-Commit-Position: refs/heads/master@{#31263}
2015-10-14 14:51:06 +00:00
rmcilroy
2ad5655260 [Interpreter]: Use vector store for array literal computed stores.
Replaces the use of KeyedStoreICGeneric with a vector based KeyedStoreIC for
array literal computed stores now that there is a feedback vector slot for
these expressions. Removes KeyedStoreICGeneric bytecode since this is no
longer necessary.

BUG=v8:4280
LOG=N
TBR=mstarzinger@chromium.org

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

Cr-Commit-Position: refs/heads/master@{#31262}
2015-10-14 13:20:11 +00:00
mbrandy
0f51a35061 PPC: VectorICs: use a vector slot to aid in array literal processing.
Port f2f46aff8b

Original commit message:
    The lack of a vector slot for the keyed store operation in filling in
    non-constant array literal properties led to undesirable contortions in
    compilers downwind of full-codegen. The use of a single slot to initialize all
    the array elements is sufficient.

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

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

Cr-Commit-Position: refs/heads/master@{#31261}
2015-10-14 13:18:33 +00:00
adamk
d317145d05 Eagerly extract stack limit from Isolate in InitializeAstVisitor()
Previously, any AstVisitor subclasses which wanted to make use of
the shared stack overflow checking code needed to depend on Isolate.

With this patch, it will be easy to create a second InitializeAstVisitor
overload taking a stack_limit directly, for use in code that has no
Isolate available (such as code running in the parser).

AstVisitor subclasses which depended upon the isolate() accessor have
been fixed to either have their own isolate_ member or get it from
somewhere else convenient.

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

Cr-Commit-Position: refs/heads/master@{#31260}
2015-10-14 13:04:55 +00:00
mlippautz
0c81c4e924 Add bailout for large objects when allocating arrays in optimized code.
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31259}
2015-10-14 13:00:12 +00:00
hpayer
a0159c1168 Bailout to runtime when BuildUncheckedStringAdd results in a large object.
BUG=

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

Cr-Commit-Position: refs/heads/master@{#31258}
2015-10-14 12:59:07 +00:00
hpayer
24622f5f12 Bailout for large object allocations in full code EmitFastOneByteArrayJoin.
BUG=chromium:542823
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#31257}
2015-10-14 12:44:45 +00:00