Commit Graph

48214 Commits

Author SHA1 Message Date
Sathya Gunasekaran
da02f095d3 [hash-table] Introduce OrderedHashTableHandler
OrderedHashTableHandler (to be renamed to OrderedHashTable) is the
interface that abstracts away the two different ordered hash tables.

All operations on the two ordered hash tables must be performed
through this new interface so that we can seamlessly migrate from one
table to another behind the scenes.

Bug: v8:6443, v8:7569
Change-Id: Ifc0a38974605b63e0a2a36b4aafb8dc68a081f4a
Reviewed-on: https://chromium-review.googlesource.com/1059865
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53622}
2018-06-11 00:22:12 +00:00
Michael Achenbach
2530a04412 [build] Add common directory for custom deps
NOTRY=true

Bug: chromium:846711
Change-Id: I5d7f366db2e80fbe539b34a5dcb7475e4e38bd29
Reviewed-on: https://chromium-review.googlesource.com/1088694
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53621}
2018-06-08 19:23:02 +00:00
Dominik Inführ
d14decc3eb Remove next field from JSWeakCollection
The GC now stores EphemeronHashTables in a Worklist.

Bug: chromium:844008
Change-Id: I6ad95b3b49484901d75c6fd92b59065c438fcd03
Reviewed-on: https://chromium-review.googlesource.com/1093092
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53620}
2018-06-08 17:48:51 +00:00
Dominik Inführ
16586b5296 Keep track of EphemeronHashTables in Worklist
JSWeakCollections used to be chained in a singly-linked list. The GC now
stores the JSWeakCollection's backing store EphemeronHashTable in a
Worklist. This should allow easier parallelization in the future.

Bug: chromium:844008
Change-Id: Icc0c1b537c23e8d24dc5b27452fb8106562c9a09
Reviewed-on: https://chromium-review.googlesource.com/1092496
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53619}
2018-06-08 17:35:22 +00:00
Sathya Gunasekaran
5760586ed6 Test262 roll
Bug: v8:7834
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I1fcbcf0b019a0fbf0f17a676bd31a686a6d5377d
Reviewed-on: https://chromium-review.googlesource.com/1091880
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Mathias Bynens <mathias@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53618}
2018-06-08 16:53:31 +00:00
Rodrigo Bruno
748e33944d [heap ]Added test to verify the output of CalculateOldGenerationAllocationLimit.
Bug: chromium:845409
Change-Id: Id8b89e6dac48bba9065ac9f04ce48f951aa2186b
Reviewed-on: https://chromium-review.googlesource.com/1092860
Commit-Queue: Rodrigo Bruno <rfbpb@google.com>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53617}
2018-06-08 16:45:41 +00:00
Ulan Degenbaev
7f442da6d8 Fix Linux64_TSAN-concurrent_marking bot after 7a9e3ec
The mock histogram functions cannot be cleared and can be called on
isolate tear down if incremental marking is in progress.

Bug: chromium:850508
Tbr: mlippautz@chromium.org
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: I99e52aaa81c863f71e195aeed691b37da9e71da6
Reviewed-on: https://chromium-review.googlesource.com/1093073
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53616}
2018-06-08 15:46:44 +00:00
Ulan Degenbaev
65ba1cb618 Fix jumbo build after 7a9e3ec
Bug: chromium:850508

Tbr: mlippautz@chromium.org
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: I99adf68c4b3e26decf3b68c8062ce74cbf27874d
Reviewed-on: https://chromium-review.googlesource.com/1093071
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53615}
2018-06-08 15:31:45 +00:00
Ulan Degenbaev
7a9e3ec98d [heap] Record histograms for Mark-Compact phases.
This adds the following histograms recorded corresponding to
V8.GCFinalizeMC phases:
- V8.GCFinalizeMC.Clear
- V8.GCFinalizeMC.Epilogue
- V8.GCFinalizeMC.Evacuate
- V8.GCFinalizeMC.Finish
- V8.GCFinalizeMC.Mark
- V8.GCFinalizeMC.Prologue
- V8.GCFinalizeMC.Sweep

Bug: chromium:850508
Change-Id: I47adc125a9a28436d09e35db68a8e8198cbee2dd
Reviewed-on: https://chromium-review.googlesource.com/1091311
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53614}
2018-06-08 14:23:09 +00:00
Dominik Inführ
310ba80b21 Improve output for HashTables
Emit full header and key/value-pairs.

Bug: chromium:844008
Change-Id: Ia94b841ff97d024d6ba27b1bcc2f993f95fc11fa
Reviewed-on: https://chromium-review.googlesource.com/1092698
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Cr-Commit-Position: refs/heads/master@{#53613}
2018-06-08 13:07:21 +00:00
Tobias Tebbi
656dce0c0e Reland "[turbofan] enable switch jump tables with --no-untrusted-code-mitigations, also for stubs and Wasm"
But for builtins, jump tables are disabled
to be compatible with embedded builtins.

This is a reland of 884bec9f70

Original change's description:
> [turbofan] enable switch jump tables with --no-untrusted-code-mitigations,
> also for stubs and Wasm
>
> Bug: chromium:845851
> Change-Id: I9b860dc26f8b35d629235b82fc5fffe04bf10493
> Reviewed-on: https://chromium-review.googlesource.com/1076151
> Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
> Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
> Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#53525}

Bug: chromium:845851
Change-Id: I66c300f875a46a3f2a68730fda94b8196f38aa97
Reviewed-on: https://chromium-review.googlesource.com/1087468
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53612}
2018-06-08 12:43:22 +00:00
Simon Zünd
6b5cd36f37 [csa] Move NumberIsNaN to Torque
This CL implements NumberIsNaN in Torque and removes it from the
CodeStubAssembler. It is currently used in TypedArray.p.sort and
Array.p.sort.

R=jgruber@chromium.org

Change-Id: Iaaa81901f89c0df68997d4501607b302a0449012
Reviewed-on: https://chromium-review.googlesource.com/1092532
Commit-Queue: Simon Zünd <szuend@google.com>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53611}
2018-06-08 12:11:58 +00:00
Clemens Hammacher
d5d116af63 [wasm] [cleanup] Refactor and clean up {DisjointAllocationPool}
Since we never extract pools from a {DisjointAllocationPool}, the
{Allocate} method can just return an {AddressRange}, and also {Merge}
just needs to merge a single {AddressRange}.

Drive-by: Make {AddressRange} a proper struct, for DCHECKs and better
accessors.

R=mstarzinger@chromium.org

Bug: v8:7754
Change-Id: I19fd02b2c6d8eb5316a5e994835b89be9cfa792b
Reviewed-on: https://chromium-review.googlesource.com/1090723
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53610}
2018-06-08 12:10:53 +00:00
jgruber
699a91f2a6 [tasm] Add platform-independent base class TurboAssemblerBase
This class can contain members and functions common across all
platforms.

Bug: v8:6666
Change-Id: I8f232f806457164a2401f74c7140fd035ad05096
Reviewed-on: https://chromium-review.googlesource.com/1086940
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53609}
2018-06-08 12:09:49 +00:00
Rodrigo Bruno
502f92160f [heap] Refactor of HeapController to avoid Heap dependencies.
Bug: chromium:845409
Change-Id: If1fbb03258fdfae528069ba37bbef0395ddb230d
Reviewed-on: https://chromium-review.googlesource.com/1090920
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Rodrigo Bruno <rfbpb@google.com>
Cr-Commit-Position: refs/heads/master@{#53608}
2018-06-08 10:48:09 +00:00
Igor Sheludko
d9daf85974 [csa][builtins] Port DeserializeLazy to CSA.
Bug: v8:5269, v8:7703
Change-Id: I0b766ab4ca55edc05d1849745fd3604be6c726d6
Reviewed-on: https://chromium-review.googlesource.com/1087460
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53607}
2018-06-08 09:55:00 +00:00
Théotime Grohens
e5318195ac [dataview] Move DataView floating point getters to Torque
This CL moves the DataViewGetFloat32 and DataViewGetFloat64
getters from runtime to Torque.

Change-Id: Ic85ec7bcb4e48f679c24e28121b7c543454e7cde
Reviewed-on: https://chromium-review.googlesource.com/1088919
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Théotime Grohens <theotime@google.com>
Cr-Commit-Position: refs/heads/master@{#53606}
2018-06-08 09:53:55 +00:00
Igor Sheludko
a17041d022 [test] Make IsValidPositiveSmi test independent of Smi representation.
Change-Id: I308c05feace7b1bb69d12a35243340724a96a49b
Reviewed-on: https://chromium-review.googlesource.com/1090491
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53605}
2018-06-08 09:15:23 +00:00
Sigurd Schneider
8a7d8f8142 [turbolizer] Migrate d3 from v3 to v5
This CL updates the d3.js library to version 5.4. The most notable
change is that the library can now distinguish between click and drag
events if an element supports both selection via click and displacement
via drag.

Curiously, npm created a 'package-lock.json', which is ~500 lines, and
which is supposed to be checked into the repository according to documentation.

Change-Id: Ifabd236296d951f390e0a1516d89e73138ce1713
Reviewed-on: https://chromium-review.googlesource.com/1076234
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53604}
2018-06-08 09:06:43 +00:00
Michael Starzinger
85a3e244b0 [assembler] Make {RelocInfo::WASM_STUB_CALL} shareable.
This makes sure that reloc entries with WASM_STUB_CALL mode can be
shared within the constant pool. Call sites to such stubs never need to
be patched individually and absolute addresses of such call targets can
be shared when they are put into constant pools.

This applies to ARM, ARM64 and PPC architectures only.

R=clemensh@chromium.org
BUG=chromium:850413

Change-Id: I657248f61f122f1a3d6d30ebd14326df45f67540
Reviewed-on: https://chromium-review.googlesource.com/1091055
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53603}
2018-06-08 08:37:23 +00:00
Dominik Inführ
6b50454d37 Reland "Add Visitor for EphemeronHashTable"
This is a reland of 4f9455994c

Original change's description:
> Add Visitor for EphemeronHashTable
> 
> JSWeakCollection does not have any weak references anymore. Special
> handling of Ephemerons can now be implemented in
> VisitEphemeronHashTable.
> 
> Bug: chromium:844008
> Change-Id: I9f4d8ad6a32cc7a55b715803f6a83ff8d2743ce8
> Reviewed-on: https://chromium-review.googlesource.com/1090274
> Commit-Queue: Dominik Inführ <dinfuehr@google.com>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#53584}

Bug: chromium:844008
Change-Id: I9d2953d55eb0affba4fede5ec37369c1eb6574f5
Reviewed-on: https://chromium-review.googlesource.com/1092370
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Cr-Commit-Position: refs/heads/master@{#53602}
2018-06-08 08:19:22 +00:00
Michael Achenbach
eb086bb6b2 [test] Change precedence of statusfile flags
Bug: v8:7812
Change-Id: Ia5a9c68e0aeb9d993ca2cd5f855ff39e172890e8
Reviewed-on: https://chromium-review.googlesource.com/1090282
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53601}
2018-06-08 08:09:22 +00:00
jgruber
1086bb7f92 Only enable embedded builtins in snapshot builds
Currently, nosnap builds do not run mksnapshot and thus do not have a
chance to generate the embedded blob. In theory we could support this,
but let's just ensure we don't crash for now.

Bug: v8:6666,v8:7835
Change-Id: I7d3b1f772b296ae3bcaed1604e0d1e44834da1c0
Reviewed-on: https://chromium-review.googlesource.com/1092491
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53600}
2018-06-08 07:44:26 +00:00
v8-ci-autoroll-builder
7783fa1a23 Update V8 DEPS.
Rolling v8/build: 2e17643..41d1fdd

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/93a962f..09b82f4

Rolling v8/third_party/depot_tools: e89dcf7..8e6f58c

Rolling v8/third_party/fuchsia-sdk: adae55a..5131d44

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

Change-Id: Icdea3ae3d892ccb6132196903753a40e19e3ba95
Reviewed-on: https://chromium-review.googlesource.com/1091477
Reviewed-by: <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53599}
2018-06-08 07:42:37 +00:00
Kanghua Yu
14bed9bd8c [turbofan][x64] Optimize moving constant to stack for GapResolver
Before:
    movl r10,0x1
    REX.W movq [rbp-0x40],r10

After:
    REX.W movq [rbp-0x40],0x1

Change-Id: Iebc77e14a947fd89f7ed4702cea703c15dcb6718
Reviewed-on: https://chromium-review.googlesource.com/1092159
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53598}
2018-06-08 07:34:16 +00:00
Ben Smith
bbea16727c Add a sample that uses the JS API to create wasm
This updates 'hello-world.cc' sample.

Change-Id: Id1f3fd222ddd89946e3ab50a8eff5c6477d1f665
Reviewed-on: https://chromium-review.googlesource.com/1089816
Commit-Queue: Ben Smith <binji@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53597}
2018-06-07 23:43:38 +00:00
Joyee Cheung
d7829ba681 [esnext] stage --harmony-symbol-description
Bug: v8:7807
Change-Id: Ie86329580551b3364da6fdf7f5bd1cdceb8ad88d
Reviewed-on: https://chromium-review.googlesource.com/1091498
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53596}
2018-06-07 21:59:51 +00:00
Aseem Garg
63b32e2747 [wasm] disable SIMD interpreter tests for mips
The globals tests for simd are failing on mips big endian. Will re-enable
after fixing.

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

Change-Id: I8a8a17c4e947b69ccc2eb6bbe79c308b1129d1af
Reviewed-on: https://chromium-review.googlesource.com/1089814
Commit-Queue: Aseem Garg <aseemgarg@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53595}
2018-06-07 19:53:57 +00:00
Dominik Inführ
e2325ccd78 Reland "Add InstanceType for EphemeronHashTable"
This is a reland of 3b93e695bb

Original change's description:
> Add InstanceType for EphemeronHashTable
>
> This will allow the GC to differentiate between regular HashTables and EphemeronHashTables.
>
> Bug: chromium:844008
> Change-Id: I2f9009ac25eb117de03786b110dd362b829c5e9e
> Reviewed-on: https://chromium-review.googlesource.com/1089066
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Commit-Queue: Dominik Inführ <dinfuehr@google.com>
> Cr-Commit-Position: refs/heads/master@{#53577}

TBR=tebbi@chromium.org

Bug: chromium:844008
Change-Id: Ia5da3d15e28ace94063f9db4fdd4997d88696501
Reviewed-on: https://chromium-review.googlesource.com/1091090
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53594}
2018-06-07 19:33:57 +00:00
Joran Siu
7ea34a90f5 s390: Fix LOCR/LOCGR disassembly
z/Architecture Principles of Operation details LOCR/LOCGR to be RRF-c
format, with the operands printed in the form LOCR/LOCGR R1,R2,M3,
where M3 is binary encoded in bits 16-20.  Current disassembler
is printing the operands in the wrong order, and extracting the Mask
from the wrong bits.

R=jyan@ca.ibm.com, michael_dawson@ca.ibm.com

Change-Id: I30baaab16ab3dbf879df381cd1f0978a66a214a6
Reviewed-on: https://chromium-review.googlesource.com/1091139
Reviewed-by: Junliang Yan <jyan@ca.ibm.com>
Commit-Queue: Joran Siu <joransiu@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#53593}
2018-06-07 18:55:17 +00:00
Joyee Cheung
ca489d39da [esnext] Implement Symbol.prototype.description
Proposal repo: https://github.com/tc39/proposal-symbol-description

Add new Builtin SymbolPrototypeDescriptionGetter.

Bug: v8:7807
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I7353bd00b172e91d8624e3373d2a4b55aced8b5c
Reviewed-on: https://chromium-review.googlesource.com/1088871
Commit-Queue: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53592}
2018-06-07 18:26:46 +00:00
Vasili Skurydzin
81e75305de s390: assembler-s390 instruction format cleanup
Change-Id: I7736314257bba44b4336d584020744c05874aa64
Reviewed-on: https://chromium-review.googlesource.com/1067607
Reviewed-by: Junliang Yan <jyan@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#53591}
2018-06-07 18:23:01 +00:00
Igor Sheludko
afd6351dcd [csa][builtins] Port CompileLazy* to CSA.
This CL introduces CSA::TailCallJSCode() for tail calling code objects
with JSCall linkage.

Bug: v8:5269, v8:7703
Change-Id: I97370dc4355dc658a9cd62166efcbe7f03d6daca
Reviewed-on: https://chromium-review.googlesource.com/1087459
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53590}
2018-06-07 18:21:55 +00:00
Bill Budge
8d2bda5509 Revert "Add InstanceType for EphemeronHashTable"
This reverts commit 3b93e695bb.

Reason for revert: Breaks Linux nosnap:
https://ci.chromium.org/buildbot/client.v8/V8%20Linux%20-%20nosnap%20-%20debug/19064

Original change's description:
> Add InstanceType for EphemeronHashTable
> 
> This will allow the GC to differentiate between regular HashTables and EphemeronHashTables.
> 
> Bug: chromium:844008
> Change-Id: I2f9009ac25eb117de03786b110dd362b829c5e9e
> Reviewed-on: https://chromium-review.googlesource.com/1089066
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Commit-Queue: Dominik Inführ <dinfuehr@google.com>
> Cr-Commit-Position: refs/heads/master@{#53577}

TBR=ulan@chromium.org,tebbi@chromium.org,dinfuehr@google.com

Change-Id: I8f92d76e35ae419af937add9a0e70a288c604781
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:844008
Reviewed-on: https://chromium-review.googlesource.com/1090973
Reviewed-by: Bill Budge <bbudge@chromium.org>
Commit-Queue: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53589}
2018-06-07 15:55:23 +00:00
Bill Budge
d4cb533a07 Revert "Add Visitor for EphemeronHashTable"
This reverts commit 4f9455994c.

Reason for revert: Changed break Linux Bot:
https://ci.chromium.org/buildbot/client.v8/V8%20Linux%20-%20nosnap%20-%20debug/19064

Original change's description:
> Add Visitor for EphemeronHashTable
> 
> JSWeakCollection does not have any weak references anymore. Special
> handling of Ephemerons can now be implemented in
> VisitEphemeronHashTable.
> 
> Bug: chromium:844008
> Change-Id: I9f4d8ad6a32cc7a55b715803f6a83ff8d2743ce8
> Reviewed-on: https://chromium-review.googlesource.com/1090274
> Commit-Queue: Dominik Inführ <dinfuehr@google.com>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#53584}

TBR=ulan@chromium.org,dinfuehr@google.com

Change-Id: Ifba31e75b0ca221da3a3905db829af586d342e26
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:844008
Reviewed-on: https://chromium-review.googlesource.com/1090971
Reviewed-by: Bill Budge <bbudge@chromium.org>
Commit-Queue: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53588}
2018-06-07 15:52:39 +00:00
Michael Starzinger
a593bb4856 [assembler] Optimize RelocInfo::WASM_STUB_CALL encoding.
This uses an optimized single-byte encoding for WASM_STUB_CALL reloc
entries when possible, by sacrificing size from DEOPT_REASON. Note that
stub calls in WebAssembly are used for trap handlers, which are fairly
common on regular WasmCode.

R=clemensh@chromium.org
BUG=chromium:850111,chromium:850413

Change-Id: I153fdd775290dece2884d438d5defd441486b369
Reviewed-on: https://chromium-review.googlesource.com/1090831
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53587}
2018-06-07 15:08:44 +00:00
Simon Zünd
e21933c17c [csa] Extract LoadNumberDictionaryElement from AccessorAssembler
This CL extracts code for loading a NumberDictionary element
from "EmitElementLoad" to its own function in the CSA.

This is done in preparation for a fast path in Torque for dictionary
elements.

R=jgruber@chromium.org

Change-Id: I3bb9897910183cd50be127bae771e531a61d57be
Reviewed-on: https://chromium-review.googlesource.com/1090832
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Simon Zünd <szuend@google.com>
Cr-Commit-Position: refs/heads/master@{#53586}
2018-06-07 15:00:54 +00:00
Junliang Yan
8fcd3f8f4d PPC/s390: skip regress-2185 on ppc and s390
R=szuend@google.com, cbruni@chromium.org, jgruber@chromium.org

Bug: v8:7382,v8:7806,chromium:849293
Change-Id: I95874713038d14fa6ae294a23679dfaff70c65ba
Reviewed-on: https://chromium-review.googlesource.com/1089141
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#53585}
2018-06-07 14:48:34 +00:00
Dominik Inführ
4f9455994c Add Visitor for EphemeronHashTable
JSWeakCollection does not have any weak references anymore. Special
handling of Ephemerons can now be implemented in
VisitEphemeronHashTable.

Bug: chromium:844008
Change-Id: I9f4d8ad6a32cc7a55b715803f6a83ff8d2743ce8
Reviewed-on: https://chromium-review.googlesource.com/1090274
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53584}
2018-06-07 13:50:14 +00:00
Simon Zünd
3896cdc25c Reland "[array] Use random middle element to determine pivot during sorting"
This is a reland of 91bab5588c

This CL contains two major changes w.r.t to the original CL:

The random state is removed from the Smi root list and we pre-seed the RNG
on each sort with the length of the array.

To cut down on the length of the arguments list and to keep track of the
random state across recursive calls, we move most of the sort arguments into
a FixedArray and reload from the array for each recursion.

Original change's description:
> [array] Use random middle element to determine pivot during sorting
>
> This CL adds a "random state" to the Smi Root list and implements a
> basic Linear congruential pseudo random number generator in Torque.
>
> The RNG is used to determine the pivot element for sorting. This will
> prevent the worst cases for certain data layouts.
>
> Drive-by-fix: Make sorting of ranges and execution pauses for profviz
> deterministic by adding a secondary sorting criteria.
>
> Bug: v8:7382
> Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
> Change-Id: Ieb871e98e74bdb803f821b0cd35d2f67ee0f2868
> Reviewed-on: https://chromium-review.googlesource.com/1082193
> Reviewed-by: Hannes Payer <hpayer@chromium.org>
> Reviewed-by: Jakob Gruber <jgruber@chromium.org>
> Reviewed-by: Camillo Bruni <cbruni@chromium.org>
> Commit-Queue: Simon Zünd <szuend@google.com>
> Cr-Commit-Position: refs/heads/master@{#53524}

Bug: v8:7382
Change-Id: Ia7bef7ed1c0e904ffe43bc428e702f64f9c6a60b
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Reviewed-on: https://chromium-review.googlesource.com/1087888
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Simon Zünd <szuend@google.com>
Cr-Commit-Position: refs/heads/master@{#53583}
2018-06-07 13:33:14 +00:00
Clemens Hammacher
67d449c361 [assembler] [cleanup] Fix field names in {IsolateData}
Struct fields should not end in an underscore according to the style
guide.

Drive-by: Add {TurboAssembler} constructor which receives an
{IsolateData} directly, to allow creating a {TurboAssembler} in a
background thread.

R=mstarzinger@chromium.org

Change-Id: I32800476690f4c8619059519b7d27b06f5d4be95
Reviewed-on: https://chromium-review.googlesource.com/1090278
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53582}
2018-06-07 12:51:14 +00:00
Tobias Tebbi
bca6b58e5a [torque] fix memory leak in DeclareGeneric
Bug: v8:7824
Change-Id: Ifdf0fbe13b3c8229bc6d44cb6d68298b016fa071
Reviewed-on: https://chromium-review.googlesource.com/1090724
Reviewed-by: Daniel Clifford <danno@chromium.org>
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53581}
2018-06-07 12:44:06 +00:00
Rodrigo Bruno
db4b7e7598 [heap] Refactoring heap growing strategy from Heap to HeapController class.
Bug: chromium:845409
Change-Id: I377d6f9d26a193f7fd829f7b74f9fdabc1337dc0
Reviewed-on: https://chromium-review.googlesource.com/1089053
Commit-Queue: Rodrigo Bruno <rfbpb@google.com>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53580}
2018-06-07 12:38:34 +00:00
Creddy
e838e75e39 [CSA] Typing LoadFeedbackVector
Bug: v8:7796
Change-Id: If5e40fa943798cdc0d7dbdc640750c7b7ad4439b
Reviewed-on: https://chromium-review.googlesource.com/1087957
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53579}
2018-06-07 12:37:25 +00:00
Michael Starzinger
c5ba2a6083 [liftoff] Make runtime calls load CEntry from instance.
This makes all runtime calls compiled by Liftoff load the respective
CEntry builtin from the instance object instead of embedding it into the
instruction stream. Another step towards making the code independent of
the originating Isolate.

As a drive-by this also changes one implicit runtime call in the stack
check in the TurboFan backend in a similar fashion.

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

Change-Id: Ifab5995aa95250d6fae60ef5debb98aee2b6fc0c
Reviewed-on: https://chromium-review.googlesource.com/1089067
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53578}
2018-06-07 11:59:07 +00:00
Dominik Inführ
3b93e695bb Add InstanceType for EphemeronHashTable
This will allow the GC to differentiate between regular HashTables and EphemeronHashTables.

Bug: chromium:844008
Change-Id: I2f9009ac25eb117de03786b110dd362b829c5e9e
Reviewed-on: https://chromium-review.googlesource.com/1089066
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@google.com>
Cr-Commit-Position: refs/heads/master@{#53577}
2018-06-07 11:42:57 +00:00
Clemens Hammacher
2725f3957e [wasm] Remove {WasmExportedFunction::GetWasmCode}
With lazy compilation, not every exported function has code assiciated
with it. {WasmExportedFunction} provides the function index though,
which can be used to check whether code exists and access that code.

R=mstarzinger@chromium.org

Bug: v8:7758
Change-Id: Id80285fec46bf5be4af49875734aa0fe28d732c9
Reviewed-on: https://chromium-review.googlesource.com/1090273
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53576}
2018-06-07 11:06:57 +00:00
Michael Starzinger
1e7d34b8dd [wasm] Make runtime stubs load CEntry from instance.
This makes the WebAssembly runtime stubs load the correct CEntry stub
from the instance object instead of embedding the address within the
instruction stream. It effectively makes those stubs independent of the
underlying Isolate.

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

Change-Id: I0e7f3ecf7642d3fb1ee7adf83a8f0e6cc4d38fdf
Reviewed-on: https://chromium-review.googlesource.com/1086997
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53575}
2018-06-07 10:50:47 +00:00
Clemens Hammacher
0a9c3a0a3a [wasm] [cleanup] Use {code_table} accessor for iteration
This reads much nicer than the for loop with {num_imported_functions_}
and {num_functions}, and is potentially even faster, because we access
the code table directly and not via function index.

R=mstarzinger@chromium.org

Bug: v8:7754
Change-Id: I83e5c0253d8f78c22982a79d878431ba75cfc027
Reviewed-on: https://chromium-review.googlesource.com/1090271
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53574}
2018-06-07 09:32:27 +00:00
Leszek Swirski
b6888b63ca Revert "[sfi] Remove SFI function literal id field"
This reverts commit ceb9c8127f.

Reason for revert: Tanks compile time

Original change's description:
> [sfi] Remove SFI function literal id field
> 
> SharedFunctionInfos store their original function literal's id. This is
> also their index in the Script's SFI list.
> 
> Since the function literal id is only needed for lazy compilation and live
> edit, we can calculate it on-the-fly by linear search in the Script SFI list,
> and save a field on the SFI.
> 
> If this regresses compile performance, we could alternatively store the
> function literal id on the preparsed scope data as future work.
> 
> Bug: chromium:818642
> Change-Id: I5468cea0e115921f1c864d94e567d749a4349882
> Reviewed-on: https://chromium-review.googlesource.com/1082480
> Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> Reviewed-by: Hannes Payer <hpayer@chromium.org>
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#53523}

TBR=hpayer@chromium.org,leszeks@chromium.org,verwaest@chromium.org

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

Bug: chromium:818642
Bug: chromium:850417
Change-Id: If2fd21331b7062532c04004a51e705f7e9d0a151
Reviewed-on: https://chromium-review.googlesource.com/1090494
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#53573}
2018-06-07 09:21:27 +00:00