Commit Graph

52574 Commits

Author SHA1 Message Date
Frank Tang
6355ca4559 [Intl] Remove flaky regress-8414.js
The removed tests should be later covered by v8:8556

Bug: v8:5751, v8:8556
Change-Id: Iea5450564ab4f85256f1aa76fb09d7e6704f9bd3
Reviewed-on: https://chromium-review.googlesource.com/c/1355634
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58082}
2018-12-07 07:05:49 +00:00
Frank Tang
a6d2fe4009 [Intl] Remove GetDefaultLocale
Simplified test for default locale under test/intl
Remove GetDefaultLocale from runtime
Move Intl::DefaultLocale from intl-object.h to
internal function inside intl-object.cc

Bug: v8:5751
Change-Id: I885abf30ff33d5213ee99c07ac1e92d3c5065d8b
Reviewed-on: https://chromium-review.googlesource.com/c/1358022
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Jungshik Shin <jshin@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58081}
2018-12-07 06:27:42 +00:00
v8-ci-autoroll-builder
29684ef04c Update V8 DEPS.
Rolling v8/build: 9fee3d5..9e9ea82

Rolling v8/buildtools: 04161ec..7d88270

Rolling v8/test/wasm-js/data: 76d26bb..89ae39c

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/a8f4725..5d7bcad

Rolling v8/third_party/depot_tools: 9875e18..f94f910

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

Change-Id: I7825688d990209a62fb5aca120d96b1bf38c5c17
Reviewed-on: https://chromium-review.googlesource.com/c/1367127
Reviewed-by: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#58080}
2018-12-07 03:43:53 +00:00
Sathya Gunasekaran
cf47678b17 [test262] test262 roll
Bug: v8:7834
Change-Id: I2b1444eded3d2917bf67f5077f35daccdbbbb951
Reviewed-on: https://chromium-review.googlesource.com/c/1367125
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58079}
2018-12-07 02:09:33 +00:00
Sven Sauleau
0ad76c9709 Reland "[wasm] fix js-api interface"
This is a reland of 0e8f20d2ab

Original change's description:
> [wasm] fix js-api interface
> 
> Make sure WebAssembly's js-api exposes the correct attributes: writable,
> enumerable and configurable.
> 
> Bug: v8:8319
> Change-Id: I427533159d7975a42c0c5cb1babdc8a61f8198b5
> Reviewed-on: https://chromium-review.googlesource.com/c/1351002
> Commit-Queue: Adam Klein <adamk@chromium.org>
> Reviewed-by: Adam Klein <adamk@chromium.org>
> Reviewed-by: Ben Smith <binji@chromium.org>
> Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#58053}

Bug: v8:8319
Change-Id: I2d0af568edab295ad8c01b64e588bbabf89bd251
Reviewed-on: https://chromium-review.googlesource.com/c/1365273
Reviewed-by: Adam Klein <adamk@chromium.org>
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58078}
2018-12-07 01:36:22 +00:00
Dmitry Gozman
4401ac4461 Revert "inspector: return [[StableObjectId]] as internal property"
This reverts commit d9fbfeb894.

Reason for revert: see bug.
Bug: 906847

Original change's description:
> inspector: return [[StableObjectId]] as internal property
> 
> This property might be useful for fast '===' check.
> 
> R=​dgozman@chromium.org,yangguo@chromium.org
> 
> Bug: none
> Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
> Change-Id: Iabc3555ce1ec2c14cf0ccd40b7d964ae144e7352
> Reviewed-on: https://chromium-review.googlesource.com/1226411
> Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
> Reviewed-by: Yang Guo <yangguo@chromium.org>
> Reviewed-by: Jakob Gruber <jgruber@chromium.org>
> Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#56095}

TBR=dgozman@chromium.org,yangguo@chromium.org,kozyatinskiy@chromium.org,jgruber@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: none
Change-Id: I68c700b7b8fd0a015f099460c15665d74e4da183
Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
Reviewed-on: https://chromium-review.googlesource.com/c/1363558
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Reviewed-by: Alexei Filippov <alph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58077}
2018-12-06 21:47:22 +00:00
Igor Sheludko
8ed4e17273 [ptr-compr] Don't use Code::cast for off-heap code objects
because attempt to decompress the off-heap map slot will fail.

Bug: v8:7703
Change-Id: Iad3884fb95ccb17b2992d190acb5914062a0e8f4
Reviewed-on: https://chromium-review.googlesource.com/c/1365286
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58076}
2018-12-06 19:50:06 +00:00
Igor Sheludko
8a321c5dae [ptr-compr] Use RelaxedLoad() in FullObjectSlot::contains_value()
to make TSAN happy.

Bug: v8:8518
Change-Id: I1c7291cc6035c7e88758d867cb74467c59e95ef1
No-Tree-Checks: true
Reviewed-on: https://chromium-review.googlesource.com/c/1365285
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58075}
2018-12-06 17:32:13 +00:00
Dan Elphick
c1ceee7d9e [heap] Force all RO_SPACE strings to be internalized
Since RO_SPACE strings cannot be written to after creation, they cannot
be internalized later. This adds checks to normal string construction
methods that they are not created with TENURED_READ_ONLY.

Also changes the Symbol construction in setup-heap-internal.cc to use
internalized strings, which increases the number of internalized
RO_SPACE strings from 490 to 514 (915 including OLD_SPACE).

Bug: chromium:911416
Change-Id: I222ff883e98f3a2f4ce70d369f22273f5c9edb0b
Reviewed-on: https://chromium-review.googlesource.com/c/1365279
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58074}
2018-12-06 15:32:37 +00:00
Igor Sheludko
ee485e2c98 [ptr-compr] Introduce MapWordSlot
which will require different handling for compressed pointers case.

Bug: v8:8518
Change-Id: I99cb103bad57b134ecb8d7dd7018cf16ed3d8f25
Reviewed-on: https://chromium-review.googlesource.com/c/1365272
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58073}
2018-12-06 15:25:38 +00:00
Ulan Degenbaev
b04632d581 [heap] Support concurrent marking of code objects.
The main change is about tracking typed slots locally in
each concurrent marking thread.

This generalizes the old LiveBytesMap to MemoryChunkData, which
now contains the live bytes and the typed slots.

With that in place it is straightforward to mark code concurrently.

Bug: v8:8459
Change-Id: I103fff0ad39beadea5151a1d8519f5d3c6602e58
Reviewed-on: https://chromium-review.googlesource.com/c/1337747
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58072}
2018-12-06 15:22:18 +00:00
Jaroslav Sevcik
67f3018510 [builtins] Shortcut for empty substrings.
There is no fast path for 0-length substrings, which implied runtime
calls for some of the trickier types of strings (such as non-flat
cons-strings). This made for a big performance gap between
String.p.slice and String.p.substring for those inputs.

This CL just adds the 0-length shortcut in CSA implementation
of SubString.

Here is an example where it makes difference:

  let s = "abcdefghijkalmnopqrst";
  let a = "";

  console.time("Substring");
  for (let i = 0; i < 100000; i++) {
    s += "0";
    a += s.substring(0, 0);
  }
  console.timeEnd("Substring");

Before this change:
> console.timeEnd: Substring, 640.308000

After this change:
> console.timeEnd: Substring, 13.242000

For completeness, here is the time for slice:
> console.timeEnd: Slice, 13.142000

This also recovers performance in the jsdom library, as
observed in https://github.com/jsdom/jsdom/issues/2350.

Bug: v8:6730
Change-Id: I7d2127e4506a86ec2a7ed378293476c3699dc47a
Reviewed-on: https://chromium-review.googlesource.com/c/1365282
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58071}
2018-12-06 14:53:04 +00:00
Mythri
84b9e927a7 Update construct bytecode handlers to work without feedback vectors
Bug: v8:8394
Change-Id: If9af9f3c79e442f6e384934e005ae5d82b0d358b
Reviewed-on: https://chromium-review.googlesource.com/c/1365277
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Mythri Alle <mythria@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58070}
2018-12-06 13:32:27 +00:00
Jakob Gruber
d8b59fc60d [nojit] Fix debug-evaluate failure on noembed builds
Fixes https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Linux%20-%20noembed%20-%20debug/781.
Failing since https://crrev.com/c/1360630.

Tbr: yangguo@chromium.org
Bug: v8:7777
Change-Id: Ia9adfa9340087dfcd74c966c40a54176081f6933
Reviewed-on: https://chromium-review.googlesource.com/c/1365276
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58069}
2018-12-06 11:37:08 +00:00
tzik
07011cc4f0 Replace %RunMicrotasks with %PerformMicrotaskCheckpoint
This replaces Runtime_RunMicrotasks with Runtime_PerformMicrotaskCheckpoint.

RunMicrotasks forcibly runs Microtasks even when the microtasks are suppressed,
and may causes nested Microtasks in a problematic way. E.g. that confuses
v8::MicrotasksScope::IsRunningMicrotasks() and GetEnteredOrMicrotaskContext().

OTOH, PerformMicrotaskCheckpoint() doesn't run cause the failure as it
respects the microtask suppressions.

As all existing tests don't call RunMicrotasks() in the suppressed situation
(like Promise.resolve().then(()=>{%RunMicrotasks();})), this change should
not affect to these tests.

Change-Id: Ib043a0cc8e482e022d375084d65ea98a6f54ef3d
Reviewed-on: https://chromium-review.googlesource.com/c/1360095
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Taiju Tsuiki <tzik@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58068}
2018-12-06 11:10:18 +00:00
Frank Tang
157af78881 [Intl] Fix numberingSystem for NumberFormat
Bug: v8:8525
Change-Id: I42764afbb419825fe6af504a641a78dbb127f30c
Reviewed-on: https://chromium-review.googlesource.com/c/1355629
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Jungshik Shin <jshin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58067}
2018-12-06 11:08:36 +00:00
Jaroslav Sevcik
f27ac2806c [turbofan] Pin pure unreachable values to effect chain (in rep selection)
Currently, if we lower to a pure computation that is unreachable because
of some runtime check, we just rename it with DeadValue. This is
problematic if the pure computation gets later eliminated - that allows
the DeadValue node float above the check that makes it dead. As we
conservatively lower DeadValues to debug-break (i.e., crash), we
might induce crash where we should not.

With this CL, whenever we lower an impossible effectful node (i.e., with
Type::None) to a pure node in simplified lowering, we insert an
Unreachable node there (pinned to the effect chain) and mark the
impossible node dead (and make it depend on the Unreachable node).

Bug: chromium:910838
Change-Id: I218991c79b9e283a9dd5beb4d3f0c4664be76cb2
Reviewed-on: https://chromium-review.googlesource.com/c/1365274
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58066}
2018-12-06 10:35:13 +00:00
Jakob Gruber
f7f18b0f1e [nojit] Explicitly pass the root register value to JSEntry
In preparation for converting JSEntry into a builtin. The root register
used to be initialized by an embedded external reference, which is not
isolate-independent. Pass in its value explicitly instead.

Tbr: clemensh@chromium.org
Bug: v8:7777
Change-Id: If9d20cb193af175bd1cf58e5826bdf6f397869ad
Reviewed-on: https://chromium-review.googlesource.com/c/1363139
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58065}
2018-12-06 09:44:32 +00:00
Jakob Gruber
a0858cf0ca [regexp] Add use counters for IsRegExp
A spec change to simplify IsRegExp has been proposed:

https://github.com/tc39/ecma262/pull/1318

This CL adds use counters for cases in which the spec change would
alter behavior:

1. o[@@match] is trueish but o is not a JSRegExp
2. o[@@match] is falseish (but not undefined) and o is a JSRegExp

This is the V8 side of required changes.
The Chromium-side CL: https://crrev.com/c/1360730

Drive-by: TNodeify IsRegExp.

Tbr: yangguo@chromium.org
Bug: v8:8522
Change-Id: I3766e02977f256a80d0e59472d3bafa9c692af9e
Reviewed-on: https://chromium-review.googlesource.com/c/1360630
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Mathias Bynens <mathias@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58064}
2018-12-06 08:15:37 +00:00
Jakob Gruber
8c7a29b201 [nojit] Consistently use DCHECKs in CallApi helper
This addresses follow-up comments to https://crrev.com/c/1354887/.

Use DCHECKs instead of CHECKs and make the branch order consistent
across architectures.

Bug: v8:7777
Change-Id: I5c3f8f5ac97b55fa80662bc211aff7833ff12bfa
Reviewed-on: https://chromium-review.googlesource.com/c/1362912
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58063}
2018-12-06 07:54:37 +00:00
Michael Achenbach
0c25d512e8 Whitespace change to test bots
TBR=santa

Change-Id: If6722b455219d5113ddbfe1a97e9178e7fad63c9
Reviewed-on: https://chromium-review.googlesource.com/c/1365271
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58062}
2018-12-06 07:39:03 +00:00
Clemens Hammacher
588d1789ea Revert "[wasm] fix js-api interface"
This reverts commit 0e8f20d2ab.

Reason for revert: Breaks layout tests, blocks roll: https://ci.chromium.org/p/chromium/builders/luci.chromium.try/linux-blink-rel/3047

Original change's description:
> [wasm] fix js-api interface
> 
> Make sure WebAssembly's js-api exposes the correct attributes: writable,
> enumerable and configurable.
> 
> Bug: v8:8319
> Change-Id: I427533159d7975a42c0c5cb1babdc8a61f8198b5
> Reviewed-on: https://chromium-review.googlesource.com/c/1351002
> Commit-Queue: Adam Klein <adamk@chromium.org>
> Reviewed-by: Adam Klein <adamk@chromium.org>
> Reviewed-by: Ben Smith <binji@chromium.org>
> Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#58053}

TBR=binji@chromium.org,adamk@chromium.org,gdeepti@chromium.org,ssauleau@igalia.com

Change-Id: I16fa44a0e79020850613751ae45a68d67602166d
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:8319
Reviewed-on: https://chromium-review.googlesource.com/c/1365270
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58061}
2018-12-06 06:52:23 +00:00
v8-ci-autoroll-builder
b3348e6ead Update V8 DEPS.
Rolling v8/build: 9c85c83..9fee3d5

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/58f2981..a8f4725

Rolling v8/third_party/depot_tools: f28ef98..9875e18

Rolling v8/tools/clang: 0dea619..f6641a3

Rolling v8/tools/luci-go:infra/tools/luci/isolate/${platform}: https://chrome-infra-packages.appspot.com/infra/tools/luci/isolate/${platform}/+log/git_rev..git_rev

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

Change-Id: I944970e96d4db2531431643cf54d3369ea977b49
Reviewed-on: https://chromium-review.googlesource.com/c/1364711
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Reviewed-by: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#58060}
2018-12-06 03:47:03 +00:00
Deepti Gandluri
c23d4dd38a [wasm] Remove unused functions on the memory object
Change-Id: Id221faecc9873cb0dbbd89777e055884158dbfb3
Reviewed-on: https://chromium-review.googlesource.com/c/1364370
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58059}
2018-12-06 01:30:23 +00:00
Sathya Gunasekaran
fbc82ec3cc [dict] Prefix a slot in ordered dicts
The prefix size is read from the Derived class.
The hash code of the object will be stored in this prefix.

Change-Id: I15646701c9bab99b8aed39ea9ad8ae03f6d605ed
Bug: v8:6443, v8:7569
Reviewed-on: https://chromium-review.googlesource.com/c/1337586
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58058}
2018-12-06 00:14:45 +00:00
Igor Sheludko
014eb84f1f [ptr-compr] Introduce MemsetTagged() for initializing on-heap kTaggedSize-sized slots
Bug: v8:8518
Change-Id: I39db0adbd84627491bcb653b90de724eb988d383
Reviewed-on: https://chromium-review.googlesource.com/c/1363145
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58057}
2018-12-05 22:58:54 +00:00
Igor Sheludko
32a79b2b30 [ptr-compr] Rename XxxSlot classes to FullXxxSlot
and
1) make them represent kSystemPointerSize-sized off-heap slots,
2) reintroduce XxxSlots as an on-heap kTaggedSize-sized slots (for now they
   are just aliases to respective FullXxxSlots).

Bug: v8:8518
Change-Id: I8a9177562308bd9420b1eebca959cc52ceaa628e
Reviewed-on: https://chromium-review.googlesource.com/c/1363144
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58056}
2018-12-05 22:56:16 +00:00
Clemens Hammacher
16afa0a226 [api][wasm] Rename WasmCompiledModule to WasmModuleObject
A WasmModuleObject represents an instance of WebAssembly.Module. It is
called WasmModuleObject internally, so also use that name externally.

We still have a typedef for WasmCompiledModule which will be deprecated
once chromium has been updated to use WasmModuleObject.

R=titzer@chromium.org, adamk@chromium.org

Bug: v8:8238, chromium:912031
Change-Id: I2d7708d4dc183cb4f4714f741b1ea0c153014430
Reviewed-on: https://chromium-review.googlesource.com/c/1362048
Reviewed-by: Adam Klein <adamk@chromium.org>
Reviewed-by: Ben Titzer <titzer@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58055}
2018-12-05 21:22:12 +00:00
Junliang Yan
f8eb3dba1f PPC/s390: [nojit] Migrate CallApi stubs to builtins
Port cfdf6ff847

R=jgruber@chromium.org, joransiu@ca.ibm.com, michael_dawson@ca.ibm.com
BUG=
LOG=N

Change-Id: I8821b82f181a44b70272d770703136983d821d1c
Reviewed-on: https://chromium-review.googlesource.com/c/1363449
Reviewed-by: Joran Siu <joransiu@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#58054}
2018-12-05 20:20:31 +00:00
Sven Sauleau
0e8f20d2ab [wasm] fix js-api interface
Make sure WebAssembly's js-api exposes the correct attributes: writable,
enumerable and configurable.

Bug: v8:8319
Change-Id: I427533159d7975a42c0c5cb1babdc8a61f8198b5
Reviewed-on: https://chromium-review.googlesource.com/c/1351002
Commit-Queue: Adam Klein <adamk@chromium.org>
Reviewed-by: Adam Klein <adamk@chromium.org>
Reviewed-by: Ben Smith <binji@chromium.org>
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58053}
2018-12-05 20:05:00 +00:00
Tobias Tebbi
82cf1cf2e4 [torque] make C++ includes explicit
Bug: v8:7793
Change-Id: I12aae5d61a21f3e6e010e07622fe0d01a5ba03eb
Reviewed-on: https://chromium-review.googlesource.com/c/1344118
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Daniel Clifford <danno@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58052}
2018-12-05 19:48:50 +00:00
Caitlin Potter
7de6d2c196 [esnext] stage Object.fromEntries()
A fancy new stdlib addition for creating JSObjects from a collection of
key/value pairs, coming soon to a javascript runtime near you.

BUG=v8:8021
R=gsathya@chromium.org, adamk@chromium.org

Change-Id: I5eb1dea75bfef009281eef9864c8c0226af4f1fc
Reviewed-on: https://chromium-review.googlesource.com/c/1363293
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Commit-Queue: Caitlin Potter <caitp@igalia.com>
Cr-Commit-Position: refs/heads/master@{#58051}
2018-12-05 19:44:21 +00:00
Ulan Degenbaev
92e228534a Do not pretenure descriptor arrays.
Even though descriptor arrays are references by maps in the old
generation, they seems to be short living in benchmarks.

This fixes perf regressions introduced in 1ad0cd5.

Bug:chromium:911073,chromium:910567,chromium:910443,

Change-Id: Iaf933d409e72c6c26df48f6435f9543224ea7d67
Reviewed-on: https://chromium-review.googlesource.com/c/1363146
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58050}
2018-12-05 19:32:09 +00:00
Daniel Clifford
79605b4508 [torque] Add new and refine existing Torque intrinsic support
Intrinsic changes:

- Rename %RawCast to %RawObjectCast and add error checking so that it
  only applies to subtypes of Objects.

- Add %RawPointerCast, which is similar to %RawObjectCast but must be
  used for all subtypes of RawPtr.

- Add %RawConstexprCast, which allows one constexpr to be be cast to
  another at compile time. It translate to an appropriate static_cast
  in the generated code

- Add %FromConstexpr, which handles most of the standard cases of
  generating XXXConstant CSA nodes from constexpr constants. It uses
  either SmiConstant, NumberConstant, StringConstant, IntPtrConstant
  or Int32Constant, depending on the cast-to type generic <To> type.

- Add support for intrinsics that return constexpr results.

Cleanup:

- Turn FromConstexpr into a generic with two generic types, a <To> and
  a <From> type. Most FromConstexpr can use the new %FromConstexpr
  intrinsic rather than provide an explicit implementation.

Bug: v8:7793
Change-Id: Icab5db16d203034ec157fa3ad5157d10c7dc8464
Reviewed-on: https://chromium-review.googlesource.com/c/1357049
Commit-Queue: Daniel Clifford <danno@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58049}
2018-12-05 19:06:56 +00:00
Predrag Rudic
ee8bb5f016 MIPS64: Correct implementation of LLD/SCD instructions in simulator.
This implementation uses mutex to implement those instructions.
I will add 32-bit version LL/SC after review.

Change-Id: I7b0e2b42527bc21060a84eb5e27099e129f2858f
Reviewed-on: https://chromium-review.googlesource.com/c/1354462
Reviewed-by: Sreten Kovacevic <skovacevic@wavecomp.com>
Commit-Queue: Predrag Rudic <prudic@wavecomp.com>
Cr-Commit-Position: refs/heads/master@{#58048}
2018-12-05 17:43:17 +00:00
Peter Marshall
feb6576177 [unwinder] Add a test for large code objects
Large code objects are allocated in CODE_LO_SPACE on the heap instead of
CODE_SPACE. Add a test that checks that these objects are still
considered 'InV8' according to the unwinder API.

Bug: v8:8116
Change-Id: I65968913cd92858fac2b1a689df2904d0574641f
Reviewed-on: https://chromium-review.googlesource.com/c/1363134
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Peter Marshall <petermarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58047}
2018-12-05 16:55:40 +00:00
Peter Marshall
2f852e5e54 [factory] Make sure large code objects actually go to large code space
If the size of a large code object is larger than
kMaxRegularHeapObjectSize, then it should be allocated in the large code
space. Currently if the size is > kMaxRegularHeapObjectSize but <
512000, then it can still be allocated in the normal code space.

Change-Id: I72dbd38803c3d5d414bae85e9e0b15482e50e1c2
Reviewed-on: https://chromium-review.googlesource.com/c/1363137
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Peter Marshall <petermarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58046}
2018-12-05 16:54:30 +00:00
Clemens Hammacher
964d175944 Make SerializedData::kMagicNumber isolate-independent
We currently compute this value from the size of the external table,
which we get from the Isolate. This size is isolate-independent though,
so it can just be a constant.

R=mstarzinger@chromium.org

Bug: chromium:912043
Change-Id: If1c09a56b1a985b855f5b65818322979c194d772
Reviewed-on: https://chromium-review.googlesource.com/c/1362954
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58045}
2018-12-05 15:17:01 +00:00
Andreas Haas
148ef606a7 [wasm] Load thread-in-wasm flag from the isolate
The existing implementation embedded an isolate-specific pointer to the
thread-in-wasm flag in the wrapper code. However, when the module code
is shared among multiple workers, this can mean that the workers
share the same thread-in-wasm flag.

With this change we load the pointer to the flag at runtime from the
current isolate. Thereby the correct flag is used even when the same
code is executed on different workers.

Note that we could access the right flag address by going through the
root register. However, changing the code generation to use the root
register requires some inconvenient steps:
* Pass the isolate to the pipeline again, which we don't want.
* Change the WasmCallDescriptor to allow the use of the root register
  for wrappers but not for other code.
To avoid these issues, and allow the CL to be easy to merge back, we
got for the changes proposed here.

R=mstarzinger@chromium.org, ishell@chromium.org

Bug: v8:8533
Change-Id: If15565a7ad7cba835cfc1628e7a4d3fdef90a5c0
Reviewed-on: https://chromium-review.googlesource.com/c/1358518
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58044}
2018-12-05 15:10:11 +00:00
Ben L. Titzer
b3ee0acdb2 [wasm] Omit alignment check for static index
If the input memory index into an atomic operation is a constant, we can
statically check if the {index+offset} is aligned.

R=herhut@chromium.org

Change-Id: Ia830d7c7df10d50ed4ee3382acfef776306f249c
Reviewed-on: https://chromium-review.googlesource.com/c/1362872
Commit-Queue: Ben Titzer <titzer@chromium.org>
Reviewed-by: Stephan Herhut <herhut@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58043}
2018-12-05 15:08:31 +00:00
Michael Achenbach
49c4c3e6b0 [test] Bump test262 shards on mac
NOTRY=true
TBR=sergiyb@chromium.org

Bug: v8:8552
Change-Id: I096146072915f2d5baf5d4469421696cf31d72c2
Reviewed-on: https://chromium-review.googlesource.com/c/1363136
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58042}
2018-12-05 15:06:41 +00:00
Sergiy Belozorov
e20eba3bcd [tools] Whitespace CL
TBR=sergiyb@chromium.org

Bug: chromium:907752
Change-Id: I06ef5a7e2cb96ebd0912c535e0ad7d8360831bbb
Reviewed-on: https://chromium-review.googlesource.com/c/1362040
Reviewed-by: Sergiy Belozorov <sergiyb@chromium.org>
Commit-Queue: Sergiy Belozorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58041}
2018-12-05 12:33:19 +00:00
Yang Guo
cccaa27eca Gracefully fail in ValueDeserializer.
Bug: chromium:905940, chromium:907343

R=verwaest@chromium.org

Change-Id: Ibe8f06782f8a0bf9a09832d443e1c66c3bda8399
Reviewed-on: https://chromium-review.googlesource.com/c/1362046
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58040}
2018-12-05 11:20:23 +00:00
Sergiy Belozorov
f3552af7fc [tools] Fix sorting order in cq.cfg
R=machenbach@chromium.org

No-Try: true
No-Tree-Checks: true
Bug: v8:8532
Change-Id: I2149c795a2d50ed794c0925d632e946b22c3e5d5
Reviewed-on: https://chromium-review.googlesource.com/c/1362042
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Sergiy Belozorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58039}
2018-12-05 10:57:00 +00:00
Marja Hölttä
4204289210 [Map::TransitionToDataProperty speed] Remove a branch in TransitionsAccessor::SearchTransition
We checked against kNotFound twice; once in
TransitionsAccessor::SearchTransitions and once in TransitionArray::Search. It's
unnecessary to check twice.

In local tests, this speeds up searching for a non-existent transition in a
2-element TransitionArray by ~20%.

BUG=v8:8547

Change-Id: Ic220c4c0bfeeacd9b81953efad212ed15168437e
Reviewed-on: https://chromium-review.googlesource.com/c/1361167
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58038}
2018-12-05 10:52:00 +00:00
Jakob Gruber
bec0234f4b [nojit] Migrate DirectCEntryStub to a builtin
Drive-by: Replace uses in CallApi* with a direct call now that they've
been converted to builtins themselves and are thus immovable.

Bug: v8:7777
Change-Id: I660b5788bdac4f5e45cc5c5677b86be17474cd83
Reviewed-on: https://chromium-review.googlesource.com/c/1361161
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58037}
2018-12-05 10:36:10 +00:00
Jakob Gruber
cfdf6ff847 [nojit] Migrate CallApi stubs to builtins
Bug: v8:7777
Change-Id: Iee3e03b0a3fea245408de4d675caa634a74aa188
Reviewed-on: https://chromium-review.googlesource.com/c/1357053
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58036}
2018-12-05 08:38:24 +00:00
Jaroslav Sevcik
8abde08a7c Revert "[constant-tracking] Track constants by default."
This reverts commit a6669bdce7.

Reason for revert: Regresses Speedometer 2 (EmberJS-Debug-TodoMVC)

Original change's description:
> [constant-tracking] Track constants by default.
> 
> It is possible this CL results in various regressions, the idea
> is to get some data on where constant tracking helps and where
> it regresses.
> 
> Bug: v8:8361
> Change-Id: I2f291788a8bea03e6eaac9f51564c1da02734d1a
> Reviewed-on: https://chromium-review.googlesource.com/c/1347474
> Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
> Reviewed-by: Igor Sheludko <ishell@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#58008}

TBR=jarin@chromium.org,ishell@chromium.org

Change-Id: I1e2b18c34829e1f53ea287aae0ef7fcf88980341
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:8361
Reviewed-on: https://chromium-review.googlesource.com/c/1362047
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#58035}
2018-12-05 08:22:53 +00:00
v8-ci-autoroll-builder
c2ae5e7744 Update V8 DEPS.
Rolling v8/build: f686dfc..9c85c83

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/4feee58..58f2981

Rolling v8/third_party/depot_tools: d87b096..f28ef98

Rolling v8/tools/clang: 558f684..0dea619

Rolling v8/tools/luci-go:infra/tools/luci/isolate/${platform}: https://chrome-infra-packages.appspot.com/infra/tools/luci/isolate/${platform}/+log/git_rev..git_rev

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

Change-Id: I7dc2bba96c14a275fd728e0567890eb0b21ea795
Reviewed-on: https://chromium-review.googlesource.com/c/1362171
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Reviewed-by: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#58034}
2018-12-05 03:31:21 +00:00
Junliang Yan
815c3758b7 s390x: add LoadPC to fix compilation error
R=joransiu@ca.ibm.com

Change-Id: Ia8cb93f4d01e252ec6b3b538f795550768db5726
Reviewed-on: https://chromium-review.googlesource.com/c/1362083
Reviewed-by: Joran Siu <joransiu@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#58033}
2018-12-05 03:30:16 +00:00