Commit Graph

48889 Commits

Author SHA1 Message Date
Toon Verwaest
ae044d697f [scanner] Fix scanner stream creation: Sliced strings can have an underlying thin string.
Bug: chromium:862538
Change-Id: I13a6886f78ee88ca7c69feb0abda6b149a1e423e
Reviewed-on: https://chromium-review.googlesource.com/1133980
Commit-Queue: Marja Hölttä <marja@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54397}
2018-07-12 10:32:47 +00:00
Marja Hölttä
eb98d5c5c6 [heap] Remove obsolete left trimming code + comments.
Follow-up to r54219 ( https://chromium-review.googlesource.com/1124450 )

They're relevant if we also iterate the heap and check there are no pointers to
the original FixedArrayBase, but in the landed version of that CL we don't do
that.

BUG=chromium:859809

Change-Id: Iffd8b76e74b6690cde961d4c542cb16ddd934f33
Reviewed-on: https://chromium-review.googlesource.com/1131123
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54396}
2018-07-12 09:46:27 +00:00
Dan Elphick
df58ce22bc [explicit isolates] Eliminate GetIsolate from String
Uses Heap::FromWritableHeapObject where the object must be mutable and
otherwise pass Isolate in. String and subclasses should now be free of
GetIsolate/GetHeap.

Bug: v8:7786
Change-Id: Ic9d55250ea4afebbebda87be9415ccdaa4fc8779
Reviewed-on: https://chromium-review.googlesource.com/1131736
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54395}
2018-07-12 09:25:37 +00:00
Dan Elphick
a07519a55f [cleanup] Delete unused method in DescriptorArray
Happily this also removes a use of GetIsolate().

Also delete Descriptor::Init which is no longer needed and some friend
declarations.

Bug: v8:7786
Change-Id: Ica803ef6c8963b38aef72121ff4fb737c9780920
Reviewed-on: https://chromium-review.googlesource.com/1133982
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54394}
2018-07-12 09:07:37 +00:00
Andreas Haas
7971f9d6f7 [wasm] Prepare API changes for WebAssembly.instantiateStreaming
This is the first CL to refactor WebAssembly.instantiateStreaming to
make it spec compliant again. The design doc where the whole change is
discussed is available in the tracking bug. The tracking bug also
references prototype implementations of the whole change, which includes
the changes in this CL.

Tests for the new API functions will be added with the second V8 CL
which adds the implementation of the API functions.

R=ulan@chromium.org

Bug: chromium:860637
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Ia1048b7ca0291c824ef4212ebde2c6054e102069
Reviewed-on: https://chromium-review.googlesource.com/1127667
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54393}
2018-07-12 09:06:28 +00:00
Clemens Hammacher
50509a9b4f [wasm] Also print absolute PC for wasm frames
On {Isolate::PrintStack}, we currently only print the pc offset for
wasm compiled frame. This CL changes this to also print the absolute PC.

R=ahaas@chromium.org

Change-Id: Ic72b7ad140ef74d2f284fdd8827b858cc78cf1c0
Reviewed-on: https://chromium-review.googlesource.com/1133985
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54392}
2018-07-12 09:03:27 +00:00
Michael Lippautz
39ee93f0bd [unified-heap] Preserve flags when forcing finalization
Preserve flags for GC finalization triggered by EmbedderHeapTracer.

Bug: chromium:843903
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Ie3d039bc1b69771ce9830dddb5e4d4375581981f
Reviewed-on: https://chromium-review.googlesource.com/1134766
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54391}
2018-07-12 08:47:49 +00:00
Dan Elphick
58ead42b9d [explicit isolates] Make IsKey and IsLive use ReadOnlyRoots
Converts the Shape functions IsKey and IsLive to take ReadOnlyRoots
rather Isolate. This allows HashTableBase::FindEntry and
ObjectHashTableBase::Lookup to also take ReadOnlyRoots rather than
Isolate.

Bug: v8:7786
Change-Id: I37efea1d20139f394d6365569438755cb8fc44c4
Reviewed-on: https://chromium-review.googlesource.com/1133391
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54390}
2018-07-12 08:45:37 +00:00
Hannes Payer
770ace0779 [heap] Cleanup: Use std::atomic<T> instead of base::AtomicValue<T> in heap/*.
Bug: chromium:842083
Change-Id: Idc04f9ddea326df4ac48a8c58321620660b21549
Reviewed-on: https://chromium-review.googlesource.com/1129520
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54389}
2018-07-12 08:20:12 +00:00
Hannes Payer
bb3b74eabe Retire AtomicNumber.
Bug: chromium:842083
Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I9a8d8327bfbab95cf9bdddb096804b65270cdfed
Reviewed-on: https://chromium-review.googlesource.com/1127944
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54388}
2018-07-12 08:17:57 +00:00
Dan Elphick
60aa28ec99 [explicit isolates] Add Isolate to Oddball::ToNumber
Bug: v8:7786
Change-Id: Ifb866cbb2d02f1231b3706358930e0ace54b0db0
Reviewed-on: https://chromium-review.googlesource.com/1133158
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54387}
2018-07-12 08:12:46 +00:00
John Barboza
d9e78322d0 fix gn builds on aix
Change-Id: I60aed7bf8207703fa6ceddb6165e173e68b5ff5f
Reviewed-on: https://chromium-review.googlesource.com/1103533
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54386}
2018-07-12 07:28:36 +00:00
Hannes Payer
49dbb39382 Cleanup: Use std::atomic<T> instead of base::AtomicNumber<T> in TaskRunner.
Bug: chromium:842083
Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I6b3f60526718f782b075bd450282646d97f6f9b5
Reviewed-on: https://chromium-review.googlesource.com/1131124
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54385}
2018-07-12 07:22:06 +00:00
Dominik Inführ
bf553836f2 [heap] Remove GotoIfNotBlack
Was only used when concurrent marking was disabled at compile-time.

Change-Id: I3977a2cbcfb27e527b2bca4b49887558595c4215
Reviewed-on: https://chromium-review.googlesource.com/1128959
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Cr-Commit-Position: refs/heads/master@{#54384}
2018-07-12 06:42:26 +00:00
v8-ci-autoroll-builder
c2bbbb4216 Update V8 DEPS.
Rolling v8/build: 11ac8d7..6ff84ae

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/345d332..39de3d2

Rolling v8/third_party/depot_tools: c3975e5..32e3d1e

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

Change-Id: I4a57a4ebfa818a19e9057d4c3746087acaf89645
Reviewed-on: https://chromium-review.googlesource.com/1134593
Commit-Queue: V8 Autoroller <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Reviewed-by: V8 Autoroller <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#54383}
2018-07-12 03:53:36 +00:00
Frank Tang
f8036e0a28 [Intl] Add ResourceBundle and RelativeDateTimeFormatter to GetAvailableLocales
R=bstell@chromium.org, cira@chromium.org, yangguo@chromium.org

Bug: v8:7869
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: Ia7176016ecd6da317b3b0eb7af7bf482f99c8129
Reviewed-on: https://chromium-review.googlesource.com/1121657
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@{#54382}
2018-07-12 02:14:25 +00:00
Brian Stell
652acb782d [intl] Change "regexes" to "regexps".
No change in functionality, this only changes spelling.

Bug: v8:5751

Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I8dad2315288e82b23782545b050e9502d0320de5
Reviewed-on: https://chromium-review.googlesource.com/1133679
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54381}
2018-07-11 19:44:15 +00:00
Leszek Swirski
559dc18336 [parser] Move some PPSD sanity checks to debug (reland)
Move some of PreParsedScopeData's santity checks, such as the magic
value separating skippable function data from scope data, to be debug
only, to save memory.

Start position of inner skippable functions is still kept, because it's
too good at catching bugs, but we may want to remove it in the future
as well.

Relanding unchanged after the (unrelated) flake it exposed is fixed in:
https://chromium-review.googlesource.com/1131503

Bug: chromium:818642
Change-Id: Id1d9fe757875cd05ea9a92b41e7256c3ee86fc8e
Reviewed-on: https://chromium-review.googlesource.com/1131505
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54380}
2018-07-11 13:50:23 +00:00
Leszek Swirski
e39b90f65d [modules] Make exported variable indices stable
A module's exported variables are assigned a cell index based on their
order in the exported variable map. This map is keyed by the variable
name, an AstRawString*.

Unfortunately, these string pointers are not guaranteed to increase
monotonically as variables are encountered, which means that this map
isn't stable across parses. In particular, it can cause failures for
setVariableValue if the parser is unlucky.

This patch adds a custom comparator to these AstRawString* keyed maps,
which is stable across parses.

Change-Id: Ie6e88fc2d252d873de661d7fc5278feba3955727
Reviewed-on: https://chromium-review.googlesource.com/1131503
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54379}
2018-07-11 13:07:40 +00:00
Michael Lippautz
8de19ddbcf [unified-heap] Add finalization trigger
Allows embedders using the EmbedderHeapTracer to synchronously finalize
an already running garbage collection

Bug: chromium:843903
Tbr: ulan@chromium.org
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Iea01451ea2c1204c34dc7904732abae6b63e1704
Reviewed-on: https://chromium-review.googlesource.com/1128971
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54378}
2018-07-11 12:25:40 +00:00
v8-ci-autoroll-builder
0454f94bf1 Update V8 DEPS.
Rolling v8/build: 9b4b413..11ac8d7

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/0c92958..345d332

Rolling v8/tools/clang: 2024df9..e9cc24f

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

Change-Id: Ie9af862f1196d6f2ee2d7b12264c171ae715fd07
Reviewed-on: https://chromium-review.googlesource.com/1133119
Reviewed-by: V8 Autoroller <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: V8 Autoroller <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/master@{#54377}
2018-07-11 12:17:30 +00:00
Jungshik Shin
d9f4c84fa4 Roll ICU to ICU 62.1
See
  https://chromium-review.googlesource.com/c/chromium/deps/icu/+/1128503
for ICU changes.

Fix tests for ICU 61/Unicode 11/CLDR 33.1

* Update mjsunit/harmony/regexp-property-script-extensions.js per
  ScriptExtensions.txt in Unicode 11
* Update mjsunit/intl-numberformat-formattoparts.js for CLDR 33.1
* Mark an invalid Mozilla test (Georgian uppercasing)
* Fix currency format test (U+00A0 instead of U+0020)
* Enable Script_Extensions tests (test262)
* Add support for Extended_Pictographic in regex

Ref. https://github.com/tc39/ecma262/issues/1219.

Bug: chromium:850334, v8:7825
Test: intl/*, test262/intl402/*
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I146080cdc1164db4a71f484918723cf302666df8
Reviewed-on: https://chromium-review.googlesource.com/1111857
Reviewed-by: Mathias Bynens <mathias@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54376}
2018-07-11 10:24:26 +00:00
Michael Achenbach
ebb7ac2bc2 Revert "Fix and extend lldbinit"
This reverts commit 5b744bfbd4.

Reason for revert: Breaks node.js install:
https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Linux64%20-%20node.js%20integration/1546

Original change's description:
> Fix and extend lldbinit
> 
> 1) Define all commands in one file.
> 2) Add logic to make 'jco' print current pc by default.
> 3) Add a comment to explain how to load the lldb_commands.py file.
> 4) Minor refactorings.
> 
> R=​ahaas@chromium.org
> No-Try: true
> 
> Bug: v8:7754
> Change-Id: I553f2ce4cefedad05466c692a8665a570372b76a
> Reviewed-on: https://chromium-review.googlesource.com/1127892
> Reviewed-by: Andreas Haas <ahaas@chromium.org>
> Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#54329}

TBR=ahaas@chromium.org,clemensh@chromium.org

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

Bug: v8:7754
Change-Id: Iecaaf53ce6536395f83a78046f0375ec77003356
Reviewed-on: https://chromium-review.googlesource.com/1132878
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54375}
2018-07-11 09:54:16 +00:00
Leszek Swirski
1458c0882e [parser] Make PreParsedScopeData array-like (reland)
Make PreParsedScopeData a new array-like instance type, which holds its
child data inline, rather than indirecting to a FixedArray. Should save
one map word per PreParsedScopeData.

Reland of https://chromium-review.googlesource.com/1127055, adding
padding clearing to keep MSAN happy.

TBR=jarin@chromium.org,marja@chromium.org,ulan@chromium.org

Bug: chromium:818642
Change-Id: I536db452047959e75d5116ddded4f511d05a04d9
Reviewed-on: https://chromium-review.googlesource.com/1131512
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54374}
2018-07-11 08:28:37 +00:00
Dan Elphick
c8354ae5e0 [explicit isolates] Eliminate GetIsolate from FixedArray
Removes GetHeap/GetIsolate from FixedArray::Shrink and
FixedArray::SetAndGrow.

Bug: v8:7786
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: I8db2680f5ef69e901383e0b2cb60198c1b8dd316
Reviewed-on: https://chromium-review.googlesource.com/1131184
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54373}
2018-07-11 07:50:57 +00:00
Sathya Gunasekaran
d94fea9897 [js] Add gsathya to OWNERS
To help with reviewing and porting intl.js

Bug: v8:5751
Change-Id: Ic8ad425e7ff14ed39ff28e907f9d1e83a3629398
Reviewed-on: https://chromium-review.googlesource.com/1132821
Commit-Queue: Yang Guo <yangguo@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54372}
2018-07-11 07:43:07 +00:00
Sigurd Schneider
1dec2864d2 [turbolizer] Change turbolizer to ES2015 modules
Bug: v8:7327
Change-Id: If2670e2b8e64a34f5de7855615e2288b6f2f3133
Reviewed-on: https://chromium-review.googlesource.com/1131193
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54371}
2018-07-11 07:19:47 +00:00
Bill Budge
80508f1457 [wasm simd] Improve code generation for I8x16 Multiply on ia32
- Uses a different technique to do the multiplies, saving one
  instruction and one temporary register on SSE and AVX.

ug: v8:6020
Change-Id: I4f3ff6186dae5eb10d90cda31c7d16b651a00d7e
Reviewed-on: https://chromium-review.googlesource.com/1132522
Reviewed-by: Jing Bao <jing.bao@intel.com>
Commit-Queue: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54370}
2018-07-11 05:02:57 +00:00
Aseem Garg
2114c6eea6 Reland "[wasm] add 64 bit atomic ops to interpreter"
This is a reland of 5301cdc39f

Original change's description:
> [wasm] add 64 bit atomic ops to interpreter
>
> R=gdeepti@chromium.org
> BUG=v8:6532
>
> Change-Id: I532bf67f1631c692e12f9b054b29601a57b76f05
> Reviewed-on: https://chromium-review.googlesource.com/1130635
> Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
> Commit-Queue: Aseem Garg <aseemgarg@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#54365}

Bug: v8:6532
Change-Id: I22af58646b898ee2f54ccb64467d9fb978a645c5
Reviewed-on: https://chromium-review.googlesource.com/1132155
Commit-Queue: Aseem Garg <aseemgarg@chromium.org>
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54369}
2018-07-10 22:35:37 +00:00
Junliang Yan
5d76222686 PPC/s390: [wasm] Fix explicit stack check to be Isolate independent.
Port 4c4c3437e0

Original Commit Message:

    This fixes the special stack check we emit for very large frames to no
    longer embed the limit address but load it from the instance object
    instead. It makes sure WasmCode remains independent of the Isolate.

R=mstarzinger@chromium.org, joransiu@ca.ibm.com, michael_dawson@ca.ibm.com
BUG=v8:7424
LOG=N

Change-Id: I35e662ee89fbad679a6c103518e4d1feb2c8dce0
Reviewed-on: https://chromium-review.googlesource.com/1131996
Reviewed-by: Muntasir Mallick <mmallick@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#54368}
2018-07-10 20:31:37 +00:00
Bill Budge
a87c0cd106 [wasm simd] Eliminate impossible code paths for ARM Dup shuffle
- Dup (broadcast) shuffles are always swizzles (single operand),
  which are canonicalized to only use the first input, so we don't
  need to check the index and switch operands.

Bug: v8:6020
Change-Id: I3ef8ba8071775dfbd21c0cab3fdf24db17f496bb
Reviewed-on: https://chromium-review.googlesource.com/1129540
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Commit-Queue: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54367}
2018-07-10 20:06:07 +00:00
Aseem Garg
cab5304b61 Revert "[wasm] add 64 bit atomic ops to interpreter"
This reverts commit 5301cdc39f.

Reason for revert: Failing on mips

Original change's description:
> [wasm] add 64 bit atomic ops to interpreter
> 
> R=​gdeepti@chromium.org
> BUG=v8:6532
> 
> Change-Id: I532bf67f1631c692e12f9b054b29601a57b76f05
> Reviewed-on: https://chromium-review.googlesource.com/1130635
> Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
> Commit-Queue: Aseem Garg <aseemgarg@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#54365}

TBR=gdeepti@chromium.org,aseemgarg@chromium.org

Change-Id: Id56d3bb1228b38b6e2ad29876ea78542658e8310
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:6532
Reviewed-on: https://chromium-review.googlesource.com/1132154
Reviewed-by: Aseem Garg <aseemgarg@chromium.org>
Commit-Queue: Aseem Garg <aseemgarg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54366}
2018-07-10 20:01:18 +00:00
Aseem Garg
5301cdc39f [wasm] add 64 bit atomic ops to interpreter
R=gdeepti@chromium.org
BUG=v8:6532

Change-Id: I532bf67f1631c692e12f9b054b29601a57b76f05
Reviewed-on: https://chromium-review.googlesource.com/1130635
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Commit-Queue: Aseem Garg <aseemgarg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54365}
2018-07-10 19:04:07 +00:00
Maya Lekova
679a759e41 Disable a flaky test262 test
Bug: chromium:856119
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I5c87ac92742ee2a4f7b4b80654299a718ccc4c6a
Reviewed-on: https://chromium-review.googlesource.com/1131741
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Commit-Queue: Sergiy Byelozyorov <sergiyb@chromium.org>
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54364}
2018-07-10 17:33:37 +00:00
Clemens Hammacher
3839e88320 [wasm] Load jump table start from the instance
This makes js-to-wasm wrappers module-independent, so that we can
eventually share them isolate-wide.

R=mstarzinger@chromium.org

Bug: chromium:862123
Change-Id: I3d9571cf247b95330ffb17f41901278a5dfacca0
Reviewed-on: https://chromium-review.googlesource.com/1131187
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54363}
2018-07-10 16:20:37 +00:00
Bill Budge
17568b9130 [wasm simd] Generate better code for Dup shuffles
- Dup shuffles broadcast a single lane from a source
  operand to all lanes of the destination. Conceptually
  similar to a splat, they require special handling since
  the splatted value must be extracted from a source. The
  32x4 case is already well handled (pshufd) but 16x8 and
  8x16 currently generate the general shuffle code sequence.
- Adds IA32S16x8Dup, IA32S8x16Dup  opcodes.

Bug: v8:6020
Change-Id: Ia4f044aa7e25cae30e8f9007c2488db738ca6cfc
Reviewed-on: https://chromium-review.googlesource.com/1128513
Reviewed-by: Jing Bao <jing.bao@intel.com>
Commit-Queue: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54362}
2018-07-10 16:19:32 +00:00
Dan Elphick
f8bda2d359 [explicit isolates] Remove some GetHeaps from objects.cc
Remove GetHeaps from String::MakeExternal by first checking the String
is not in RO_SPACE (by checking the MemoryChunk's identity) and only
then getting the heap from the chunk. Also changes
String::CanMakeExternal in api.cc to not use GetHeap.

Also remove check GetHeap()->Contains(this/map) that attempts to print
INVALID POINTER/INVALID MAP as it's much more likely that the code will
crash in either GetHeap or Contains before printing anything.

Bug: v8:7786
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Id27ba84eb2ba78c71158d6f2e94a3b4176c34609
Reviewed-on: https://chromium-review.googlesource.com/1131128
Commit-Queue: Dan Elphick <delphick@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54361}
2018-07-10 16:18:27 +00:00
Michael Starzinger
4c4c3437e0 [wasm] Fix explicit stack check to be Isolate independent.
This fixes the special stack check we emit for very large frames to no
longer embed the limit address but load it from the instance object
instead. It makes sure WasmCode remains independent of the Isolate.

R=clemensh@chromium.org
BUG=v8:7424

Change-Id: I8dc40a31a3a4de04aeb6b0b800694cce2321f837
Reviewed-on: https://chromium-review.googlesource.com/1131186
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54360}
2018-07-10 14:37:16 +00:00
Frank Tang
a52c42dad8 [Intl] Implement Intl.RelativeTimeFormat.prototype.resolvedOptions
Spec: http://tc39.github.io/proposal-intl-relative-time/

Design Doc: go/add-intl.relativetimeformat-to-v8

Test: test262/intl402/RelativeTimeFormat/*, intl/relative-time-format/*

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

Bug: v8:7869
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: Ic1ef2e26d164275791dfdbe37d016ba350256d94
Reviewed-on: https://chromium-review.googlesource.com/1125539
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54359}
2018-07-10 14:24:26 +00:00
Frank Tang
97cdf44d7c [Intl] Implement Intl.RelativeTimeFormat constructor
Spec: http://tc39.github.io/proposal-intl-relative-time/

Design Doc: go/add-intl.relativetimeformat-to-v8

Test: test262/intl402/RelativeTimeFormat/*, intl/relative-time-format/*

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

Bug: v8:7869
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I2cfe8dba9d3a99957ad4b444023c89bbdae08c7c
Reviewed-on: https://chromium-review.googlesource.com/1124121
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54358}
2018-07-10 14:20:06 +00:00
Michael Starzinger
dfffde4a52 [wasm] Add proper --turbo-stats-wasm flag.
This gathers TurboFan compilation statistics for WebAssembly separately
from the JavaScript statistics. It is a preparation to having multiple
Isolates trigger TurboFan compilations in a shared engine. By adding
compilation statistics to the engine, their lifetime is independent of
any particular Isolate.

R=ahaas@chromium.org

Change-Id: I1bd0fbe6d6bde65ca813ccfd1154558ea6cddb07
Reviewed-on: https://chromium-review.googlesource.com/1131121
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54357}
2018-07-10 14:07:26 +00:00
Michael Starzinger
8442795a32 [wasm] Fix destructor ordering for {NativeModule}.
R=clemensh@chromium.org
BUG=v8:7921

Change-Id: I82a1c5cff7fd00603a509221b448b11d82edee7e
Reviewed-on: https://chromium-review.googlesource.com/1131176
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54356}
2018-07-10 13:51:41 +00:00
Andreas Haas
d87287bc48 [wasm][anyref] Allow tables of different reference types
Allow the decoding of multiple tables, and allow these tables to have
any reference type. In addition, rename function-tables (in different
occurrences) to tables.

R=titzer@chromium.org

Bug: v8:7581
Change-Id: I191ea8e303b76563f9d91ae7447b373c4760d8b8
Reviewed-on: https://chromium-review.googlesource.com/1019581
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54355}
2018-07-10 13:50:36 +00:00
Leszek Swirski
7184ce3934 Revert "[parser] Make PreParsedScopeData array-like"
This reverts commit a9fed96c00.

Reason for revert: Serializer test msan failures

Original change's description:
> [parser] Make PreParsedScopeData array-like
> 
> Make PreParsedScopeData a new array-like instance type, which holds its
> child data inline, rather than indirecting to a FixedArray. Should save
> one map word per PreParsedScopeData.
> 
> TBR=jarin@chromium.org
> 
> Bug: chromium:818642
> Change-Id: I72dc21160ed9781ad12b18559468f6cce56886fa
> Reviewed-on: https://chromium-review.googlesource.com/1127055
> Reviewed-by: Leszek Swirski <leszeks@chromium.org>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Reviewed-by: Marja Hölttä <marja@chromium.org>
> Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#54349}

TBR=ulan@chromium.org,marja@chromium.org,jarin@chromium.org,leszeks@chromium.org,verwaest@chromium.org

Change-Id: If2f39379bb0bdfca7d36ec1a3ec738519481aa4e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:818642
Reviewed-on: https://chromium-review.googlesource.com/1131234
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54354}
2018-07-10 12:47:14 +00:00
Sathya Gunasekaran
256b4a8247 [intl] Port NumberFormat.prototype.format and bound format function to C++
This increases the size of a NumberFormat instance by a word to store
the bound format function.

The instance to be bound is stored on the context of this builtin function.

Bug: v8:5751, v8:7800
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: Ie85d8db7d10aabb5c40e77687e6f7112a84f3ebd
Reviewed-on: https://chromium-review.googlesource.com/1122153
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54353}
2018-07-10 12:06:44 +00:00
Benedikt Meurer
cf080aebaa [async-generators] Add fast-path to skip "then" lookup in AsyncGeneratorResolve.
This extends the Promise#then protector to also guard the intrinsic
%ObjectPrototype%, making it usable for fast-path logic in the
AsyncGeneratorResolve operation, where we can skip the "then" lookup
on the iteratorResult in that case. We also add a corresponding fast-
path to the ResolvePromise builtin itself, which avoids the second
"then" lookup on the async iterator side.

This reduces execution time of the fibonacci-async-es2017-native test
from 298.16ms to 280.55ms, which corresponds to an improvement of ~6%
in this case.

This is a rebased reland of

  https://chromium-review.googlesource.com/967203

which landed earlier, but had to be reverted as part of the mega-revert
that was necessary to fix the async_hooks breakage in Node 10.

Bug: v8:7253
Change-Id: Id9dd1ddc4a8285d64e92cd2030f3168a12e4b509
Reviewed-on: https://chromium-review.googlesource.com/1130523
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54352}
2018-07-10 12:05:40 +00:00
Sathya Gunasekaran
2bb56165af [JSObject] Refactor AddDataElement
This can't fail.

Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I2b8972fe02d3446726ce12f615fd1f92d00632ff
Reviewed-on: https://chromium-review.googlesource.com/1131015
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54351}
2018-07-10 11:21:59 +00:00
Andreas Haas
adbb4d1d50 [wasm] Update spec tests
R=herhut@chromium.org

Change-Id: I565dbd636b54f6537e401a43cf3d3910654dc279
Reviewed-on: https://chromium-review.googlesource.com/1130521
Reviewed-by: Stephan Herhut <herhut@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54350}
2018-07-10 11:18:19 +00:00
Leszek Swirski
a9fed96c00 [parser] Make PreParsedScopeData array-like
Make PreParsedScopeData a new array-like instance type, which holds its
child data inline, rather than indirecting to a FixedArray. Should save
one map word per PreParsedScopeData.

TBR=jarin@chromium.org

Bug: chromium:818642
Change-Id: I72dc21160ed9781ad12b18559468f6cce56886fa
Reviewed-on: https://chromium-review.googlesource.com/1127055
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54349}
2018-07-10 11:16:30 +00:00
Hannes Payer
3917714854 Cleanup: Use std::atomic<T> instead of base::AtomicNumber<T> in isolate.
Bug: chromium:842083

Change-Id: I015db53853c7da42c4879c791f437bf44eea7a00
Reviewed-on: https://chromium-review.googlesource.com/1130516
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#54348}
2018-07-10 11:12:20 +00:00