Commit Graph

50745 Commits

Author SHA1 Message Date
Marja Hölttä
e39d2cbe1b [objects.h splitting] Move ic/FeedbackVector related enums
BUG=v8:5402,v8:8015

Change-Id: I19440f77601317d99d912f5d7248a5275c980993
Reviewed-on: https://chromium-review.googlesource.com/1245761
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56253}
2018-09-27 07:06:59 +00:00
Alexei Filippov
62b03d55f1 Revert "Reland "[heap profiler] Refactor: Replace indices with HeapEntry*""
This reverts commit 181bbd5c88.

Reason for revert: Still break Win tests https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Win64%20-%20debug/25096

Original change's description:
> Reland "[heap profiler] Refactor: Replace indices with HeapEntry*"
> 
> This is a reland of 69a502ce5c
> 
> TBR=ulan@chromium.org
> 
> Original change's description:
> > [heap profiler] Refactor: Replace indices with HeapEntry*
> >
> > Change-Id: I0c176f66711d45e2f59d527f3133a1afbf825ec3
> > Reviewed-on: https://chromium-review.googlesource.com/1229613
> > Commit-Queue: Alexei Filippov <alph@chromium.org>
> > Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> > Cr-Commit-Position: refs/heads/master@{#56245}
> 
> Change-Id: I416da19eb38a1a55f5e2f5897062bc1ca454ac34
> Reviewed-on: https://chromium-review.googlesource.com/1246802
> Commit-Queue: Alexei Filippov <alph@chromium.org>
> Reviewed-by: Alexei Filippov <alph@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#56250}

TBR=ulan@chromium.org,alph@chromium.org,mlippautz@chromium.org

Change-Id: I0d027d192a9354eb6157405566420e6aa38738c1
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/1248131
Reviewed-by: Alexei Filippov <alph@chromium.org>
Commit-Queue: Alexei Filippov <alph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56252}
2018-09-27 06:04:44 +00:00
v8-ci-autoroll-builder
36c77c2252 Update V8 DEPS.
Rolling v8/build: 6f889c3..343caac

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/846ae9b..3cf15a9

Rolling v8/third_party/depot_tools: c4a7356..f221bac

Rolling v8/third_party/fuchsia-sdk: 9b435fc..ce131de

Rolling v8/tools/clang: 9ad74fa..86c7e6d

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

Change-Id: Iaf0d368c44cd99d570d47782c2121d625fb9a551
Reviewed-on: https://chromium-review.googlesource.com/1248122
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@{#56251}
2018-09-27 03:39:12 +00:00
Alexei Filippov
181bbd5c88 Reland "[heap profiler] Refactor: Replace indices with HeapEntry*"
This is a reland of 69a502ce5c

TBR=ulan@chromium.org

Original change's description:
> [heap profiler] Refactor: Replace indices with HeapEntry*
>
> Change-Id: I0c176f66711d45e2f59d527f3133a1afbf825ec3
> Reviewed-on: https://chromium-review.googlesource.com/1229613
> Commit-Queue: Alexei Filippov <alph@chromium.org>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#56245}

Change-Id: I416da19eb38a1a55f5e2f5897062bc1ca454ac34
Reviewed-on: https://chromium-review.googlesource.com/1246802
Commit-Queue: Alexei Filippov <alph@chromium.org>
Reviewed-by: Alexei Filippov <alph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56250}
2018-09-26 22:17:36 +00:00
Frank Tang
e6d208b6a0 [Intl] add tests for 'quarter'
Add tests for 'quarter' unit in Intl.RelativeTimeFormat#format

Bug: v8:7869
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I03077d5d89e1b9e459af0c31b5bf7378d9c4a1f0
Reviewed-on: https://chromium-review.googlesource.com/1244758
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56249}
2018-09-26 20:56:49 +00:00
Alexei Filippov
a87b0e63db Revert "[heap profiler] Refactor: Replace indices with HeapEntry*"
This reverts commit 69a502ce5c.

Reason for revert: Broke the build https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Linux%20gcc%204.8/22123

Original change's description:
> [heap profiler] Refactor: Replace indices with HeapEntry*
> 
> Change-Id: I0c176f66711d45e2f59d527f3133a1afbf825ec3
> Reviewed-on: https://chromium-review.googlesource.com/1229613
> Commit-Queue: Alexei Filippov <alph@chromium.org>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#56245}

TBR=ulan@chromium.org,alph@chromium.org,mlippautz@chromium.org

Change-Id: Ib4495f17a653a95f8d5af634da74905c63048f8e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/1246235
Reviewed-by: Alexei Filippov <alph@chromium.org>
Commit-Queue: Alexei Filippov <alph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56248}
2018-09-26 18:45:44 +00:00
Alexei Filippov
f5e65cc81d Revert "[heap profiler] Refactor: remove SnapshotFiller proxy"
This reverts commit 0352ea97da.

Reason for revert: A dependent patch broke the build https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Linux%20gcc%204.8/22123

Original change's description:
> [heap profiler] Refactor: remove SnapshotFiller proxy
> 
> Long time ago there were two passes over heap. One was counting
> objects and edge and another was filling them. Since then we have
> just a single pass, but the filler object is still there.
> 
> Remove it for the sake of layering simplicity.
> 
> Change-Id: Ic873eb5ca616b9dcae17fe388197dde8f539026f
> Reviewed-on: https://chromium-review.googlesource.com/1244380
> Commit-Queue: Alexei Filippov <alph@chromium.org>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#56246}

TBR=ulan@chromium.org,alph@chromium.org,mlippautz@chromium.org

Change-Id: If71ddcc0008d138054074fc4cca3f38e032763e0
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/1246234
Reviewed-by: Alexei Filippov <alph@chromium.org>
Commit-Queue: Alexei Filippov <alph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56247}
2018-09-26 18:44:26 +00:00
Alexei Filippov
0352ea97da [heap profiler] Refactor: remove SnapshotFiller proxy
Long time ago there were two passes over heap. One was counting
objects and edge and another was filling them. Since then we have
just a single pass, but the filler object is still there.

Remove it for the sake of layering simplicity.

Change-Id: Ic873eb5ca616b9dcae17fe388197dde8f539026f
Reviewed-on: https://chromium-review.googlesource.com/1244380
Commit-Queue: Alexei Filippov <alph@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56246}
2018-09-26 18:37:03 +00:00
Alexei Filippov
69a502ce5c [heap profiler] Refactor: Replace indices with HeapEntry*
Change-Id: I0c176f66711d45e2f59d527f3133a1afbf825ec3
Reviewed-on: https://chromium-review.googlesource.com/1229613
Commit-Queue: Alexei Filippov <alph@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56245}
2018-09-26 18:21:03 +00:00
Maya Lekova
c86b90d12c Improve logging when signaling a semaphore fails
That change is attempting to surface the root cause of a recent flake,
see the related bug.

Bug: v8:8228
Change-Id: Iebed5b8f46db3fd47154031856dc7ea173cf3d7f
Reviewed-on: https://chromium-review.googlesource.com/1245771
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56244}
2018-09-26 15:09:29 +00:00
Toon Verwaest
400be60c13 [parser] Allocate preparsed scope members in preparse zone
Before I gave the preparser its own zone this was the case. I somewhat
accidentally dropped it when I used set_zone instead; causing large regressions
for certain types of pages.

Bug: chromium:889086
Change-Id: Ib3cf1f926b5c65506c66a97981c4544dccb372aa
Reviewed-on: https://chromium-review.googlesource.com/1245767
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56243}
2018-09-26 14:17:43 +00:00
Jaroslav Sevcik
68f8dbb72f [turbofan] Stop lowering array constructor calls to stub calls.
Bug: v8:8230
Change-Id: Ibf93300cd54c6d5053ebed0cb897b4068f2bc160
Reviewed-on: https://chromium-review.googlesource.com/1245768
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56242}
2018-09-26 14:15:23 +00:00
Peter Marshall
5fb5509786 [API] Change GetCodeRange to match the style of GetEmbeddedCodeRange
Deprecate GetCodeRange(void** start, size_t* length_in_bytes) in favor
of a new signature MemoryRange GetCodeRange() which is consistent with
that of GetEmbeddedCodeRange.

Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Ic5e244981422a2c75485c851ca768e54914cc539
Reviewed-on: https://chromium-review.googlesource.com/1245741
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Peter Marshall <petermarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56241}
2018-09-26 13:16:58 +00:00
Clemens Hammacher
6d86857cd4 [wasm] Remove AddressRange, use base::AddressRegion
R=ahaas@chromium.org

Bug: v8:8015
Change-Id: Ic449b76ab3957bb989bbb1fc9cc1fb4782db7acf
Reviewed-on: https://chromium-review.googlesource.com/1240119
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56240}
2018-09-26 12:49:44 +00:00
Clemens Hammacher
980a960205 [wasm][cleanup] Remove single-user NativeModule::Free method
This method only has a single user, and can be implemented in a few
lines, so just inline it.

R=ahaas@chromium.org

Bug: v8:8015
Change-Id: I26247d97ebb939274fa72cc5441e8c2e0c6bc869
Reviewed-on: https://chromium-review.googlesource.com/1245743
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56239}
2018-09-26 12:46:10 +00:00
Clemens Hammacher
1fa16da73b Avoid passing rvalue references to VirtualMemory
The idea of movable data structures is to pass them by value. This is
also preferred by the style guide.

R=ahaas@chromium.org
CC=sattlerf@google.com

Bug: v8:8015
Change-Id: Ica016425d624f4497e374b25b363c1f2eb49b4c0
Reviewed-on: https://chromium-review.googlesource.com/1245762
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56238}
2018-09-26 12:45:05 +00:00
Hannes Payer
6b5b3a5abf [heap] Promote surviving young generation large objects in the Scavenger.
Surviving large objects are directly promoted to the old generation.

Bug: chromium:852420
Change-Id: I460649714544d4338e01085f487d4b70065ecfb5
Reviewed-on: https://chromium-review.googlesource.com/1238173
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56237}
2018-09-26 12:34:24 +00:00
Jaroslav Sevcik
52a9e67a47 [turbofan] Fix ObjectCreate's side effect annotation.
Bug: chromium:888923
Change-Id: Ifb22cd9b34f53de3cf6e47cd92f3c0abeb10ac79
Reviewed-on: https://chromium-review.googlesource.com/1245763
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56236}
2018-09-26 12:02:11 +00:00
Toon Verwaest
568979f4d8 [parser] Fix memory accounting of explicitly cleared zones
Bug: chromium:889086
Change-Id: Ie5a6a9e27260545469ea62d35b9571c0524f0f92
Reviewed-on: https://chromium-review.googlesource.com/1245427
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56235}
2018-09-26 11:17:31 +00:00
Igor Sheludko
e5648b2ac9 [cleanup] Move some helper methods from Heap to ReadOnlyRoots
In particular: MapForFixedTypedArray() and EmptyFixedTypedArrayForMap().

And make ReadOnlyRoots object independent of the Heap.

Bug: v8:8015
Change-Id: Ifd17294661fac21c8e7545145280c8a2dedfe8c3
Reviewed-on: https://chromium-review.googlesource.com/1243131
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56234}
2018-09-26 11:03:11 +00:00
Igor Sheludko
647e0c2312 [cleanup] Use RootIndex instead of int in serializer code
Bug: v8:8015
Change-Id: I2f407c5ffaed96b90b9ead452a98a19ef1700b75
Reviewed-on: https://chromium-review.googlesource.com/1240336
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56233}
2018-09-26 09:49:40 +00:00
Maya Lekova
3c3330f6f0 Revert "[interpreter] Separate bytecodes for one-shot property loads and stores"
This reverts commit eccf186749.

Reason for revert: Speculative revert because it seems to introduce a pretty stable flake on gc stress tests, see https://bugs.chromium.org/p/v8/issues/detail?id=8229

Original change's description:
> [interpreter] Separate bytecodes for one-shot property loads and stores
> 
> Create LdaNamedPropertyNoFeedback and StaNamedPropertyNoFeedback
> for one-shot property loads and stores. This CL replaces the runtime
> calls with new bytecodes for named property load stores in one-shot code.
> the runtime calls needed extra set of consecutive registers and
> additional move instructions. This increased the size of
> bytecode-array and possibly extended the life time of objects.
> By replacing them with NoFeedback bytecodes we avoid these issues.
> 
> Bug: v8:8072
> Change-Id: I20a38a5ce9940026171d870d354787fe0b7c5a6f
> Reviewed-on: https://chromium-review.googlesource.com/1196725
> Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
> Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
> Reviewed-by: Yang Guo <yangguo@chromium.org>
> Reviewed-by: Georg Neis <neis@chromium.org>
> Commit-Queue: Chandan Reddy <chandanreddy@google.com>
> Cr-Commit-Position: refs/heads/master@{#56211}

TBR=rmcilroy@chromium.org,yangguo@chromium.org,jarin@chromium.org,neis@chromium.org,cbruni@chromium.org,chandanreddy@google.com

Change-Id: I445db58e6d4c275b434fabad5fad775bf259033f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:8072
Reviewed-on: https://chromium-review.googlesource.com/1245421
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56232}
2018-09-26 08:36:14 +00:00
Ivica Bogosavljevic
0d81c8bf42 Update binutils to 2.30
Change-Id: I88db66ef1bea03dee365679487814563250c4bba
Reviewed-on: https://chromium-review.googlesource.com/1243127
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Ivica Bogosavljevic <ibogosavljevic@wavecomp.com>
Cr-Commit-Position: refs/heads/master@{#56231}
2018-09-26 07:36:07 +00:00
Marja Hölttä
eda00a5c49 [objects.h splitting] Move PropertyArray
BUG=v8:5402,v8:8015

Change-Id: I2fce46c944e3057cb05aa53c3030916334ffbc3e
Reviewed-on: https://chromium-review.googlesource.com/1243044
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56230}
2018-09-26 06:41:51 +00:00
v8-ci-autoroll-builder
69e60fb708 Update V8 DEPS.
Rolling v8/build: 4325c99..6f889c3

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/c51eb62..846ae9b

Rolling v8/third_party/depot_tools: 64b6133..c4a7356

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

Change-Id: I0a47e67e23a980b6fd8b95c97172f86d4c303bd0
Reviewed-on: https://chromium-review.googlesource.com/1244957
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@{#56229}
2018-09-26 03:45:03 +00:00
Jakob Kummerow
c2088790ae [atomics] Implement 64-bit Atomics operations
Atomics.{load,store,add,sub,and,or,xor,exchange,compareExchange}
are updated to support BigInt and BigInt64Array/BigUint64Array inputs.

Atomics.{wait,wake,isLockFree} are left unchanged for now.

Bug: v8:8100
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I8862d7e18c58ae08784535e9c010ba94f067a0ee
Reviewed-on: https://chromium-review.googlesource.com/1237294
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56228}
2018-09-26 01:13:30 +00:00
Frank Tang
d34ffa6a38 [Intl] move DateTimeFormat.prototype.resolvedOptions to c++
Bug: v8:8066
Change-Id: I931de0472941fca8f68739a05fa38dee308d59f4
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng;luci.chromium.try:linux_chromium_rel_ng
Reviewed-on: https://chromium-review.googlesource.com/1212467
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56227}
2018-09-26 00:57:09 +00:00
Frank Tang
93cbb579a6 [Intl] Remove incorrect CHECK
The CHECK was introduced in d7ae63e6f2.

The first time the property got read by ToDateTimeOptions
and the test will cause the needsDefault in ToDateTimeOptions
be false. Then in step 22 of InitializeDateTimeFormat,
it will get all undefined and cause the
skeleton to be empty string. If we only pass in empty options, the
defaults will be filled by ToDateTimeOptions and won't cause any
CHECK failure.


Bug: chromium:888299
Cq-Include-Trybots: luci.v8.try:v8_linux_noi18n_rel_ng
Change-Id: I3ee14434f0708eaaea78cc8857591152d1bdef8a
Reviewed-on: https://chromium-review.googlesource.com/1241316
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56226}
2018-09-26 00:24:28 +00:00
Vasili Skurydzin
e3eedfb406 ppc64, aix: Fix failing wasm cctests on Aix platform
src/compiler/ppc/instruction-selector-ppc.cc: ensure that input register
does not alias any temporary registers in VisitWord64ReverseBytes method.

Change-Id: I18ddfc5cbe37ba7551ca25efa59d4973f77ffb02
Reviewed-on: https://chromium-review.googlesource.com/1244617
Reviewed-by: Junliang Yan <jyan@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#56225}
2018-09-25 21:47:35 +00:00
Yang Guo
8ff37bc769 Reland "[snapshot] add checksum to startup snapshot"
This is a reland of bcb8d49b2c

TBR=petermarshall@chromium.org

Original change's description:
> [snapshot] add checksum to startup snapshot
>
> We already had checksumming for code cache data. We now extend
> checksumming to the startup snapshot to catch data corruption early.
>
> The performance impact for deserialization is a regression of 1-2%,
> which should be acceptable.
>
> Sample output for the included test with --profile-deserialization:
>
> [Verifying snapshot checksum took 0.023 ms]
> [Deserializing isolate (134348 bytes) took 1.891 ms]
> [Verifying snapshot checksum took 0.024 ms]
> [Deserializing isolate (134348 bytes) took 1.654 ms]
> [Deserializing context #0 (47208 bytes) took 0.331 ms]
> Deserialization will reserve:
>     208168 bytes per isolate
>     123368 bytes per context #0
> Snapshot blob consists of:
>     134492 bytes in 6 chunks for startup
>     115272 bytes for builtins
>      47152 bytes in 31 chunks for context #0
> [Verifying snapshot checksum took 0.048 ms]
> [Verifying snapshot checksum took 0.043 ms]
>
> R=peria@chromium.org, petermarshall@chromium.org
>
> Bug: chromium:881417
> Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
> Change-Id: Ibc57520d459c86be8972f731aa35045b5e3751d7
> Reviewed-on: https://chromium-review.googlesource.com/1241874
> Reviewed-by: Peter Marshall <petermarshall@chromium.org>
> Commit-Queue: Yang Guo <yangguo@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#56217}

Bug: chromium:881417
Change-Id: I037f378fc2d45c3e0fa670bf538df68cbba5c53c
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Reviewed-on: https://chromium-review.googlesource.com/1243191
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56224}
2018-09-25 19:18:23 +00:00
Frank Tang
a3b97babfb [Intl] Ship Intl.RelativeTimeFormat
Bug: v8:7869
Change-Id: If87ab5126a41513d0c69acc849d483159f1a2fde
Reviewed-on: https://chromium-review.googlesource.com/1241317
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56223}
2018-09-25 17:42:45 +00:00
Clemens Hammacher
a345e766ae [wasm] Avoid internal use of Maybe
Maybe (defined in include/v8.h) is an API object, not meant to be used
in internal code. Instead of failing, it will call a callback on the
isolate.
It also adds one word to the size of each WasmCode object.

This CL avoids its use WasmCode. Instead, we use a sentinel value as the
function index of anonymous functions and add proper DCHECKs.

R=mstarzinger@chromium.org

Bug: v8:8015
Change-Id: I4bb155e814d8d0cc9e40b33202b4431718ac79b1
Reviewed-on: https://chromium-review.googlesource.com/1242096
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56222}
2018-09-25 16:46:29 +00:00
Clemens Hammacher
0a04f26370 Revert "[snapshot] add checksum to startup snapshot"
This reverts commit bcb8d49b2c.

Reason for revert: MSan compile error: https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8%20Linux%20-%20arm64%20-%20sim%20-%20MSAN/23025

Original change's description:
> [snapshot] add checksum to startup snapshot
> 
> We already had checksumming for code cache data. We now extend
> checksumming to the startup snapshot to catch data corruption early.
> 
> The performance impact for deserialization is a regression of 1-2%,
> which should be acceptable.
> 
> Sample output for the included test with --profile-deserialization:
> 
> [Verifying snapshot checksum took 0.023 ms]
> [Deserializing isolate (134348 bytes) took 1.891 ms]
> [Verifying snapshot checksum took 0.024 ms]
> [Deserializing isolate (134348 bytes) took 1.654 ms]
> [Deserializing context #0 (47208 bytes) took 0.331 ms]
> Deserialization will reserve:
>     208168 bytes per isolate
>     123368 bytes per context #0
> Snapshot blob consists of:
>     134492 bytes in 6 chunks for startup
>     115272 bytes for builtins
>      47152 bytes in 31 chunks for context #0
> [Verifying snapshot checksum took 0.048 ms]
> [Verifying snapshot checksum took 0.043 ms]
> 
> R=​peria@chromium.org, petermarshall@chromium.org
> 
> Bug: chromium:881417
> Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
> Change-Id: Ibc57520d459c86be8972f731aa35045b5e3751d7
> Reviewed-on: https://chromium-review.googlesource.com/1241874
> Reviewed-by: Peter Marshall <petermarshall@chromium.org>
> Commit-Queue: Yang Guo <yangguo@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#56217}

TBR=peria@chromium.org,yangguo@chromium.org,petermarshall@chromium.org

Change-Id: Iccb82092858ab68a5d6ae9552fa716108eda354b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: chromium:881417
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Reviewed-on: https://chromium-review.googlesource.com/1243190
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56221}
2018-09-25 16:37:22 +00:00
Ben L. Titzer
89f52f8a44 [wasm] Load formal_param_count for mismatched import calls
For WASM import calls to JSFunctions where the arity is mismatched,
we currently generate code that inlines the formal parameter count
of the target function as a constant in a call to the arguments
adapter. This CL changes this to generate code that loads the formal
parameter count from the function at runtime in order to permit
more sharing later.

R=mstarzinger@chromium.org
CC=clemensh@chromium.org

Change-Id: I5cce97fc338f6468f9d42d48f5bc860b25fb7d73
Reviewed-on: https://chromium-review.googlesource.com/1243108
Commit-Queue: Ben Titzer <titzer@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56220}
2018-09-25 16:13:53 +00:00
Daniel Clifford
274aecdd78 Fix nits in presubmit.py and handling of .tq otherwise formatting
Change-Id: I69a4db1d8be47bad56df74447a29526e9623cb80
Reviewed-on: https://chromium-review.googlesource.com/1243107
Commit-Queue: Daniel Clifford <danno@chromium.org>
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56219}
2018-09-25 15:37:39 +00:00
Toon Verwaest
55ecf51e33 [parser] Don't resolve preparser variables for arrow functions
I moved AnalyzePartially from ParseFunctionLiteral to SkipFunction, but arrow
functions only used the ResetAfterPreparsing part.

Bug: chromium:888825

Change-Id: I08de99af128b28031df6ed86a725e4dc918078f8
Reviewed-on: https://chromium-review.googlesource.com/1243383
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56218}
2018-09-25 15:28:18 +00:00
Yang Guo
bcb8d49b2c [snapshot] add checksum to startup snapshot
We already had checksumming for code cache data. We now extend
checksumming to the startup snapshot to catch data corruption early.

The performance impact for deserialization is a regression of 1-2%,
which should be acceptable.

Sample output for the included test with --profile-deserialization:

[Verifying snapshot checksum took 0.023 ms]
[Deserializing isolate (134348 bytes) took 1.891 ms]
[Verifying snapshot checksum took 0.024 ms]
[Deserializing isolate (134348 bytes) took 1.654 ms]
[Deserializing context #0 (47208 bytes) took 0.331 ms]
Deserialization will reserve:
    208168 bytes per isolate
    123368 bytes per context #0
Snapshot blob consists of:
    134492 bytes in 6 chunks for startup
    115272 bytes for builtins
     47152 bytes in 31 chunks for context #0
[Verifying snapshot checksum took 0.048 ms]
[Verifying snapshot checksum took 0.043 ms]

R=peria@chromium.org, petermarshall@chromium.org

Bug: chromium:881417
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Ibc57520d459c86be8972f731aa35045b5e3751d7
Reviewed-on: https://chromium-review.googlesource.com/1241874
Reviewed-by: Peter Marshall <petermarshall@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56217}
2018-09-25 15:26:38 +00:00
Alexey Kozyatinskiy
e439681323 debug: LoadLookupSlot should initialize receiver for modules..
.. otherwise V8 crashes on attempt to use imported function as part
of expression passed to Debugger.evaluateOnCallFrame.

R=neis@chromium.org

Bug: chromium:878029
Cq-Include-Trybots: luci.chromium.try:linux_chromium_headless_rel;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I61b837f5c7b84a80d91a9cdaaac0422a24aa1620
Reviewed-on: https://chromium-review.googlesource.com/1241475
Reviewed-by: Georg Neis <neis@chromium.org>
Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56216}
2018-09-25 14:52:41 +00:00
Michael Starzinger
72131a74ef [wasm] Improve exception throwing code sequence.
This reduces the size a "Throw" or "Rethrow" takes in generated code by
switching from runtime calls to using WebAssembly runtime stubs. It also
removes a specialized runtime function and instead uses {Runtime_Throw}
which is generic and used by all code (including JavaScript code).

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

Change-Id: Id4f637525f2ea9d81227931b1290d90ca5f376d1
Reviewed-on: https://chromium-review.googlesource.com/1243106
Commit-Queue: Michael Starzinger <mstarzinger@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56215}
2018-09-25 14:51:37 +00:00
Clemens Hammacher
69f264f547 [wasm] Refactor code installation in NativeModule
Whenever we insert new code in the module, we call {set_code} and
{PatchJumpTable}. This CL refactors these two calls into a new
{InstallCode} method. This method will be extended in a future CL to
maintain a counter of potentially dead code and trigger GC.

R=mstarzinger@chromium.org

Bug: v8:8217
Change-Id: I1a1421806c8518cf7b6b78fe4aa2e969d4e4dde6
Reviewed-on: https://chromium-review.googlesource.com/1243003
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56214}
2018-09-25 14:33:56 +00:00
Andreas Haas
1a5a6c3619 [wasm] Notify StreamingDecoder when its AsyncCompileJob is destructed
The lifetime of the AsyncCompileJob does not depend on the lifetime of
the stream which feeds data into it. Multiple checks guarantee that the
AsyncCompileJob still exists when the stream wants to call it. With
this CL we add an additional level of defense to make sure that
streaming does not continue after the AsyncCompileJob got destructed.

It is not clear if this CL fixes the bug referenced below. However, the
crashes there could be caused when streaming accesses the
AsyncCompileJob after it got destructed already. I was not able though
to find a scenario where this is possible.

R=clemensh@chromium.org

Bug: chromium:888170
Change-Id: Id5c6cc34842735a3adaf3e09c57cbe923cfc2630
Reviewed-on: https://chromium-review.googlesource.com/1241961
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56213}
2018-09-25 14:30:54 +00:00
Ross McIlroy
3a00ba5f1a [Compile] Refactor UnoptimizedCompilationJob to use BackgroundCompilerTask
This CL makes UnoptimizedCompilationJob a simple proxy for
BackgroundCompilerTask. A follow-up CL will remove UnoptimizedCompilationJob
entirely and have CompilerDispatcher deal directly with BackgroundCompilerTasks

BUG=v8:8041, v8:8015

Change-Id: Ia53d05c015c4ca2ee32a4d1c5d0c65edb3caeda8
Reviewed-on: https://chromium-review.googlesource.com/1236257
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56212}
2018-09-25 14:23:54 +00:00
Creddy
eccf186749 [interpreter] Separate bytecodes for one-shot property loads and stores
Create LdaNamedPropertyNoFeedback and StaNamedPropertyNoFeedback
for one-shot property loads and stores. This CL replaces the runtime
calls with new bytecodes for named property load stores in one-shot code.
the runtime calls needed extra set of consecutive registers and
additional move instructions. This increased the size of
bytecode-array and possibly extended the life time of objects.
By replacing them with NoFeedback bytecodes we avoid these issues.

Bug: v8:8072
Change-Id: I20a38a5ce9940026171d870d354787fe0b7c5a6f
Reviewed-on: https://chromium-review.googlesource.com/1196725
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Commit-Queue: Chandan Reddy <chandanreddy@google.com>
Cr-Commit-Position: refs/heads/master@{#56211}
2018-09-25 13:53:53 +00:00
Ben L. Titzer
7f7545cf55 [wasm] Introduce WasmImportCallKind enum
The WASM engine compiles per-import wrappers for callables imported
into a WASM instance that have one of a number of different shapes,
depending on the type of the imported function and whether there is
a signature match. This CL introduces an enum with a value for each
case in preparation for introducing a per-kind cache.

R=mstarzinger@chromium.org
CC=clemensh@chromium.org

Change-Id: If9b7355ff7c57a329c096f93f3624bc3d6c74e3f
Reviewed-on: https://chromium-review.googlesource.com/1243045
Commit-Queue: Ben Titzer <titzer@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56210}
2018-09-25 13:52:12 +00:00
Hai Dang
9f7ec7d479 Add fast path for cloning by iterating fast holey arrays.
This fast path copies the backing store and replaces holes with undefined.
In the case where the array is holey but there is no actual holes, the
resulting array is of the same elements kind as the source array. If a hole
does appear, the resulting array will be of PACKED_ELEMENTS kind so that it
can contain undefined.

The builtin CloneFastJSArrayFillingHoles includes this fast path, but
CloneFastJSArray does not (it still behaves as before). In case of fast
packed arrays, CloneFastJSArrayFillingHoles behaves the same as
CloneFastJSArray.

Bug: chromium:881273, v8:7980
Change-Id: I49c641c1a673313f06aeed93077031ab6b017b6d
Reviewed-on: https://chromium-review.googlesource.com/1236573
Commit-Queue: Hai Dang <dhai@google.com>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56209}
2018-09-25 13:46:42 +00:00
Toon Verwaest
790b687c65 [parser] Replace tail-position CHECK_OK with ok
CHECK_OK is a macro that checks whether the function failed, and returns a
dummy expression if it did to avoid continuing parsing. If we're immediately
returning the result of the call anyway we don't need the additional check and
can just return whatever the call returned.

Change-Id: I0da1a6a4440728ce14923c57f52522ac93da6b8e
Reviewed-on: https://chromium-review.googlesource.com/1242805
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56208}
2018-09-25 13:45:38 +00:00
Toon Verwaest
651f25a99c [parser] Remove dead case in ParseAndClassifyIdentifier
It deals with strict-mode but is in a branch guarded by is_sloppy.

Change-Id: I309c187a96b5fa62956eec5bb05f50c0ce4e5ad3
Reviewed-on: https://chromium-review.googlesource.com/1243105
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56207}
2018-09-25 13:44:32 +00:00
Georg Neis
74b40e34d5 [turbofan] Remove redundant isolate argument from typers.
This is just a cleanup.

Bug: v8:7790
Change-Id: Ic0114451159b8c504f527f3cf3bdaed6a8cc8741
Reviewed-on: https://chromium-review.googlesource.com/1243103
Commit-Queue: Georg Neis <neis@chromium.org>
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56206}
2018-09-25 13:00:05 +00:00
Georg Neis
78dd1d0c69 [turbofan] Move typer into the background.
... if FLAG_concurrent_compiler_frontend is enabled.

Bug: v8:7790
Change-Id: I448560b21d54c8907e8cbf68bdaf8bbdf2b034df
Reviewed-on: https://chromium-review.googlesource.com/1241959
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56205}
2018-09-25 12:40:50 +00:00
Clemens Hammacher
19bad28dac [wasm][gc] Link Isolates from WasmEngine
First step towards GC of wasm code: Introduce a link to all Isolates
that use a WasmEngine.

R=mstarzinger@chromium.org

Bug: v8:8217
Change-Id: Ib7f4495e7c7e5cc9ad58293518c65738f23d664c
Reviewed-on: https://chromium-review.googlesource.com/1240335
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56204}
2018-09-25 12:16:00 +00:00