Commit Graph

53979 Commits

Author SHA1 Message Date
Georg Neis
462a01505c [turbofan] Use && instead of & in some condition.
R=jarin@chromium.org

Change-Id: I7005dc4c8282f8de75859f642e4d1808c6a8ef90
Reviewed-on: https://chromium-review.googlesource.com/c/1462000
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59487}
2019-02-11 08:53:04 +00:00
Z Duong Nguyen-Huu
cc7ac98b0c add micro-benchmark for object freeze with tagged template
Bug: v8:6831
Change-Id: I67e4d9f39576a4067dad59b18b3b4bf04bcdcb99
Reviewed-on: https://chromium-review.googlesource.com/c/1461166
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59486}
2019-02-09 18:13:48 +00:00
Mike Stanton
ba1d0f25d5 Reland "Reland "Introduce a PREMONOMORPHIC state to StoreGlobalIC""
This is a reland of 7179cdb116

The node integration build failure appears to be constant.

Original change's description:
> Reland "Introduce a PREMONOMORPHIC state to StoreGlobalIC"
>
> (Fixed test failure in lite-mode)
>
> Introduce a PREMONOMORPHIC state to StoreGlobalIC
>
> It's used rather narrowly for now -- only when we run into an
> interceptor during the lookup. After the call to SetProperty, we know
> more. That is, the interceptor was only there because it's a new
> property, and the call to SetProperty ends up creating it.
>
> By delaying the initialization of the IC, we recognize the (now)
> created property, and can provide good feedback downstream to
> TurboFan.
>
> TBR=ishell@chromium.org
>
> Bug: v8:8712
> Change-Id: Ieb79dcf1354ee294ad0f479a4a6c41a77f389850
> Reviewed-on: https://chromium-review.googlesource.com/c/1460955
> Reviewed-by: Michael Stanton <mvstanton@chromium.org>
> Commit-Queue: Michael Stanton <mvstanton@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#59483}

TBR=ishell@chromium.org

Bug: v8:8712
Change-Id: I31aa4c066ff46cb39187eed392313d2e524f4445
Reviewed-on: https://chromium-review.googlesource.com/c/1461998
Reviewed-by: Michael Stanton <mvstanton@chromium.org>
Commit-Queue: Michael Stanton <mvstanton@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59485}
2019-02-09 15:24:15 +00:00
Michael Stanton
e986f44012 Revert "Reland "Introduce a PREMONOMORPHIC state to StoreGlobalIC""
This reverts commit 7179cdb116.

Reason for revert: Breaks node integration build.

Original change's description:
> Reland "Introduce a PREMONOMORPHIC state to StoreGlobalIC"
> 
> (Fixed test failure in lite-mode)
> 
> Introduce a PREMONOMORPHIC state to StoreGlobalIC
> 
> It's used rather narrowly for now -- only when we run into an
> interceptor during the lookup. After the call to SetProperty, we know
> more. That is, the interceptor was only there because it's a new
> property, and the call to SetProperty ends up creating it.
> 
> By delaying the initialization of the IC, we recognize the (now)
> created property, and can provide good feedback downstream to
> TurboFan.
> 
> TBR=ishell@chromium.org
> 
> Bug: v8:8712
> Change-Id: Ieb79dcf1354ee294ad0f479a4a6c41a77f389850
> Reviewed-on: https://chromium-review.googlesource.com/c/1460955
> Reviewed-by: Michael Stanton <mvstanton@chromium.org>
> Commit-Queue: Michael Stanton <mvstanton@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#59483}

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

Change-Id: Ifd45908ee66760ef9199d9722b7e558c31f77830
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:8712
Reviewed-on: https://chromium-review.googlesource.com/c/1461997
Reviewed-by: Michael Stanton <mvstanton@chromium.org>
Commit-Queue: Michael Stanton <mvstanton@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59484}
2019-02-09 14:34:27 +00:00
Mike Stanton
7179cdb116 Reland "Introduce a PREMONOMORPHIC state to StoreGlobalIC"
(Fixed test failure in lite-mode)

Introduce a PREMONOMORPHIC state to StoreGlobalIC

It's used rather narrowly for now -- only when we run into an
interceptor during the lookup. After the call to SetProperty, we know
more. That is, the interceptor was only there because it's a new
property, and the call to SetProperty ends up creating it.

By delaying the initialization of the IC, we recognize the (now)
created property, and can provide good feedback downstream to
TurboFan.

TBR=ishell@chromium.org

Bug: v8:8712
Change-Id: Ieb79dcf1354ee294ad0f479a4a6c41a77f389850
Reviewed-on: https://chromium-review.googlesource.com/c/1460955
Reviewed-by: Michael Stanton <mvstanton@chromium.org>
Commit-Queue: Michael Stanton <mvstanton@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59483}
2019-02-09 13:39:02 +00:00
Michael Stanton
b5003d269e Revert "Introduce a PREMONOMORPHIC state to StoreGlobalIC"
This reverts commit ec06b5c456.

Reason for revert: Breaks "lite" builder.

Original change's description:
> Introduce a PREMONOMORPHIC state to StoreGlobalIC
> 
> It's used rather narrowly for now -- only when we run into an
> interceptor during the lookup. After the call to SetProperty, we know
> more. That is, the interceptor was only there because it's a new
> property, and the call to SetProperty ends up creating it.
> 
> By delaying the initialization of the IC, we recognize the (now)
> created property, and can provide good feedback downstream to
> TurboFan.
> 
> Bug: v8:8712
> Change-Id: I4e10ba220c8363b393c6de84ce35fe5ef0e9c427
> Reviewed-on: https://chromium-review.googlesource.com/c/1456090
> Commit-Queue: Michael Stanton <mvstanton@chromium.org>
> Reviewed-by: Igor Sheludko <ishell@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#59481}

TBR=mvstanton@chromium.org,ishell@google.com,ishell@chromium.org

Change-Id: I072a55275d64315924090a68247bb430f5c4f03d
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:8712
Reviewed-on: https://chromium-review.googlesource.com/c/1460954
Reviewed-by: Michael Stanton <mvstanton@chromium.org>
Commit-Queue: Michael Stanton <mvstanton@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59482}
2019-02-09 12:48:35 +00:00
Mike Stanton
ec06b5c456 Introduce a PREMONOMORPHIC state to StoreGlobalIC
It's used rather narrowly for now -- only when we run into an
interceptor during the lookup. After the call to SetProperty, we know
more. That is, the interceptor was only there because it's a new
property, and the call to SetProperty ends up creating it.

By delaying the initialization of the IC, we recognize the (now)
created property, and can provide good feedback downstream to
TurboFan.

Bug: v8:8712
Change-Id: I4e10ba220c8363b393c6de84ce35fe5ef0e9c427
Reviewed-on: https://chromium-review.googlesource.com/c/1456090
Commit-Queue: Michael Stanton <mvstanton@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59481}
2019-02-09 12:10:32 +00:00
Jaroslav Sevcik
154bb50c22 Fix map updater for non-extensible maps with private symbols.
Bailout from map update if there are private symbol transitions on
non-extensible maps.

Bug: chromium:930045
Change-Id: I02fbea0ec0afde07cded688c06122d8f2bb25921
Reviewed-on: https://chromium-review.googlesource.com/c/1460949
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59480}
2019-02-09 09:09:02 +00:00
Johannes Henkel
f1c92ac171 [DevTools] Roll inspector_protocol to 02ca2bc2bb337cb2d4143157383b554f9b75dc99.
This brings in the CBOR_h / CBOR_cc template.

Change-Id: I3d3971a5ba4c98a8b36982449e4d9a2606010f22
Reviewed-on: https://chromium-review.googlesource.com/c/1459738
Reviewed-by: Alexei Filippov <alph@chromium.org>
Commit-Queue: Johannes Henkel <johannes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59479}
2019-02-09 01:54:28 +00:00
Jakob Kummerow
455200e009 [cleanup] Move some stuff out of objects-inl.h
HeapObject::SizeFromMap() was too large to get inlined anyway.
HeapObject::IsFoo() predicates should be implemented in foo-inl.h,
because that's what they depend on.
This patch also fixes up includes: dropping unnecessary ones from
object-inl.h, and adding them in other places that previously
relied on getting them transitively.

Bug: v8:8562
Change-Id: Id062bed67257d9dc1899f2d71f44cf69a1368c83
Reviewed-on: https://chromium-review.googlesource.com/c/1450778
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Sigurd Schneider <sigurds@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59478}
2019-02-09 00:34:12 +00:00
Frank Tang
8c684d5666 [Intl] Remove redundant call
Bug: v8:7684
Change-Id: If74e2b6d1ff7d11f3133ff74847d23b171b05f0a
Reviewed-on: https://chromium-review.googlesource.com/c/1459744
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59477}
2019-02-08 22:46:54 +00:00
Frank Tang
8c2ec19403 [Intl] Work around ICU-8420 for "und"
Fix intl402/Locale/likely-subtags

Bug: v8:8236
Change-Id: I0f109d0bedb1fda3f5eaac9cfce935788f54b595
Reviewed-on: https://chromium-review.googlesource.com/c/1459745
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59476}
2019-02-08 21:54:49 +00:00
Frank Tang
daa38a9a6e Reland "[Intl] Cleans up intl-relative-time-format flag"
This is a reland of 048a3a3ecb

Original change's description:
> [Intl] Cleans up intl-relative-time-format flag
> 
> Cleans up always=true intl-relative-time-format flag
> It shipped in m71 in Dec 2018.
> 
> Bug: v8:8704
> Change-Id: I52d86aea9aedf201a216a1df0773a486fbee37b9
> Reviewed-on: https://chromium-review.googlesource.com/c/1417299
> Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
> Commit-Queue: Frank Tang <ftang@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#58904}

Bug: v8:8704
Change-Id: I0b3c58b89a81200e9ac8303494317d21d8936319
Reviewed-on: https://chromium-review.googlesource.com/c/1420360
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59475}
2019-02-08 21:53:44 +00:00
Frank Tang
bc80fbc99f [Intl] Reduces memory by sharing code.
Bug: chromium:928098
Change-Id: I47333b06bb7cf2319eec6f6beab830ce6c6da1c5
Reviewed-on: https://chromium-review.googlesource.com/c/1461162
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59474}
2019-02-08 21:44:44 +00:00
Matt Gardner
c22bb466d8 Inline indexOf/includes at polymorphic sites
This commit allows inlining of Array#indexOf and Array#includes when the array type is polymorphic for types that are compatable for array iteration.

Bug: v8:8388
Change-Id: Ib826bad857c7dfe0ee7af99bb456b50b7a8b6ef9
Reviewed-on: https://chromium-review.googlesource.com/c/1450137
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59473}
2019-02-08 19:45:10 +00:00
Igor Sheludko
ead726f37a [snapshot][ptr-compr] Stop using UnalignedSlot
... in favor of [Full]MaybeObjectSlot and finally make deserializer
pointer compression friendly.

Bug: v8:8794
Change-Id: I23e5b119ccfe7d0c12c15a857978d89813e0522f
Reviewed-on: https://chromium-review.googlesource.com/c/1460460
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59472}
2019-02-08 18:24:58 +00:00
Igor Sheludko
51f11f0f65 [snapshot][cleanup] Reassign bytecode values
... and update the list of unused bytecodes.

This CL also drops kInternalReferenceEncoded as all necessary details
are already encoded in RelocInfo.

Bug: v8:8794, v8:8562
Change-Id: Ia8aec1f4bcf9802fe15322bd6bb273218d8959fa
Reviewed-on: https://chromium-review.googlesource.com/c/1460459
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59471}
2019-02-08 18:18:28 +00:00
Seth Brenith
ed5230a996 improve exec performance on RegExp with named capture groups
When creating the results object for an exec call, V8 is calling into a
runtime helper once per named capture group. It can instead create that
object without any runtime calls, using existing CSA helpers. The only
additional cost of this approach is that it internalizes the capture
group names at regex compilation time, even if the script never calls
exec on that regex.

Bug: v8:6914

Change-Id: I58975b8d7aea05f8c67ae087608715099f62fc48
Reviewed-on: https://chromium-review.googlesource.com/c/1454268
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
Cr-Commit-Position: refs/heads/master@{#59470}
2019-02-08 17:38:18 +00:00
Toon Verwaest
f644fa40ec [d8] Add parser experimentation flags
--parse-only only invokes the parser but does not compile / run the scripts
--max-lazy ignores eager compilation hints from IIFE.

Change-Id: Icd156cab16d796b9f676b95bb1542ad07c67546d
Reviewed-on: https://chromium-review.googlesource.com/c/1460939
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59469}
2019-02-08 17:29:38 +00:00
Igor Sheludko
93d92cfbbe [ptr-compr] Fix compressing stores in CSA/builtins
... and also loads of off-heap tagged values.

Bug: v8:7703
Change-Id: I0dd15ecda76cc35fe5f2f51a7103937a7ac238dc
Reviewed-on: https://chromium-review.googlesource.com/c/1459639
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59468}
2019-02-08 17:24:19 +00:00
Jaroslav Sevcik
7bb6dc0e06 [turbofan] Introduce aborting bounds checks.
Instead of eliminating bounds checks based on types, we introduce
an aborting bounds check that crashes rather than deopts.

Bug: v8:8806
Change-Id: Icbd9c4554b6ad20fe4135b8622590093679dac3f
Reviewed-on: https://chromium-review.googlesource.com/c/1460461
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59467}
2019-02-08 16:14:23 +00:00
Georg Neis
d3c4a0b087 [turbofan] Respect unset kBailoutOnUninitialized flag in element access.
Change-Id: Ie996f5da3f2f4a45b5664e33833362b8d13c476c
Reviewed-on: https://chromium-review.googlesource.com/c/1460943
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59466}
2019-02-08 15:15:29 +00:00
Ulan Degenbaev
c06cb88bc6 [heap, serializer] Fix data race in serialization of DescriptorArray
This patch ensures that the serializer does not read the field of
the DescriptorArray that can be changed concurrently by GC.

Bug: v8:8803
Change-Id: I849fd2278abd228a46351ab18efb8bfd201ceafc
Reviewed-on: https://chromium-review.googlesource.com/c/1458239
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59465}
2019-02-08 15:14:24 +00:00
Toon Verwaest
b9af6ad89d [api] Mark SetHiddenPrototype as DEPRECATED
Change-Id: Iad53e1a3b6ef0148dc5aa9c5c04c25c446dcdfa2
Reviewed-on: https://chromium-review.googlesource.com/c/1460468
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59464}
2019-02-08 14:49:30 +00:00
Igor Sheludko
37e632b119 [snapshot][cleanup] Remove HowToCode flag from bytecodes
... as it's no longer needed.

Bug: v8:8794, v8:8562
Change-Id: Ia5149bab33af219e5cdc6909af4688e53f1409fa
Reviewed-on: https://chromium-review.googlesource.com/c/1460458
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59463}
2019-02-08 14:40:49 +00:00
Igor Sheludko
8a526a4153 [ptr-compr][x64] TurboFan support for compressing stores
This CL also stops using checked decompression for tagged values
in TurboFan backend.

Bug: v8:7703
Change-Id: I4ab7670301924a365a10bb78f43bce0bbf785862
Reviewed-on: https://chromium-review.googlesource.com/c/1459638
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59462}
2019-02-08 14:27:18 +00:00
Igor Sheludko
60f8b7a894 [snapshot][cleanup] Remove WhereToPoint flag from bytecodes
... as it's no longer needed.

Bug: v8:8794, v8:8562
Change-Id: Ifbc4f5f5d34f24ff4ba8f32309e8a032268c12c0
Reviewed-on: https://chromium-review.googlesource.com/c/1460457
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59461}
2019-02-08 14:21:00 +00:00
Simon Zünd
9afefcbc05 [cleanup] Rename field offsets in StackFrameInfo
This CL renames field offsets from *Index to *Offset in the
StackFrameInfo class for consistency.

R=mstarzinger@chromium.org

Bug: v8:8562
Change-Id: I9ccec3e6f924a4040d26dc677fdd1ec620cf0463
Reviewed-on: https://chromium-review.googlesource.com/c/1460937
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Simon Zünd <szuend@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59460}
2019-02-08 14:14:48 +00:00
Georg Neis
8dd7212532 [turbofan] Restrict the generality of ElementAccessInfo.
It unnecessarily allowed for transitions in the presence of multiple
receiver maps.

Bug: v8:7790
Change-Id: I226f499f626ffb7c1b084aa5a45684e7782d1760
Reviewed-on: https://chromium-review.googlesource.com/c/1456088
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59459}
2019-02-08 14:02:48 +00:00
Matheus Marchini
3724a12549 Reland "[error] extend error stack w/ function parameters"
This is a reland of 97628eeeb9.

Original change's description:
> [error] extend error stack w/ function parameters
>
> Extend FrameArray to hold weak references to parameters forfunctions in
> the call stack. The goal here is to provide more metadata for postmortem
> tools (such as llnode), especially in cases of rethrowing (this will be
> particularly useful when using postmortem with promises on Node.js).
>
> Besides postmortem, these changes allow us to print a more detailed
> stack trace for errors with parameters types (or even values), which can
> be useful since JavaScript functions can receive any number of
> parameters of any type, and having a function behave differently
> according to the number of parameters received as well as their types is
> a common pattern on JS libraries and frameworks.
>
> R=<U+200B>bmeurer@google.com, yangguo@google.com
>
> Change-Id: Idf0984d0dbac16041f11d738d4b1c095a8eecd61
> Reviewed-on: https://chromium-review.googlesource.com/c/1289489
> Commit-Queue: Yang Guo <yangguo@chromium.org>
> Reviewed-by: Yang Guo <yangguo@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#58468}

R=bmeurer@google.com, jkummerow@chromium.org, yangguo@google.com

Change-Id: I53d90bb862d9c5e9541116b375fa4de70e3e76dd
Reviewed-on: https://chromium-review.googlesource.com/c/1405568
Commit-Queue: Yang Guo <yangguo@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59458}
2019-02-08 13:35:27 +00:00
Igor Sheludko
c9a9d825c8 [snapshot][cleanup] Remove skipping bytecodes
... as they are no longer needed.

Bug: v8:8794, v8:8562
Change-Id: Ib5d87fce9834839410b0dffce95b4a8ae4f946cc
Reviewed-on: https://chromium-review.googlesource.com/c/1460456
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59457}
2019-02-08 13:27:49 +00:00
Benedikt Meurer
1f386f4fdb [runtime] Add %ClearMegamorphicStubCache() intrinsic.
This adds a new %ClearMegamorphicStubCache() runtime function, which can
be used to easily wipe the megamorphic stub cache. This is useful when
investigating performance issues that are related to high contention on
the megamorphic stub cache.

Change-Id: I7abb496bf1dd658298a90065241dd317f2fb6624
Reviewed-on: https://chromium-review.googlesource.com/c/1459637
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59456}
2019-02-08 13:24:57 +00:00
Yang Guo
9b2bcf57ba Expose protected v8::Platform::SystemClockTimeMillis
This allows the embedder to use a shared library build
even if they use this method.

R=ulan@chromium.org

Change-Id: I613a6e5eb82b494128fb95dc89a0b73639ac5ca2
Reviewed-on: https://chromium-review.googlesource.com/c/1456042
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59455}
2019-02-08 12:49:19 +00:00
Gus Caplan
98453126c1 Reland^2 "[builtins] [turbofan] Refactor Float64Pow to use single implementation"
This is a reland of d7def9003d

Original change's description:
> Reland "[builtins] [turbofan] Refactor Float64Pow to use single implementation"
>
> This is a reland of I968a08cef6a6d49350aa79185b2c6fb856d15f23
>
> Original change's description:
> > [builtins] [turbofan] Refactor Float64Pow to use single implementation
> >
> > Remove platform-specific Float64Pow implementations and utils Pow in
> > favor of a base::ieee754::pow implementation.
> >
> > This unifies the implementation of pow for the compiler, wasm, and
> > runtime.
> >
> > Bug: v8:5848, v8:5086
> > Change-Id: I968a08cef6a6d49350aa79185b2c6fb856d15f23
> > Reviewed-on: https://chromium-review.googlesource.com/c/1403018
> > Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
> > Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
> > Reviewed-by: Georg Neis <neis@chromium.org>
> > Reviewed-by: Yang Guo <yangguo@chromium.org>
> > Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
> > Cr-Commit-Position: refs/heads/master@{#59229}
>
> Bug: v8:5848, v8:5086
> Change-Id: I92f22ae03adafd9ad042e8d4bb406cbd5b5fb51e
> Cq-Include-Trybots: luci.chromium.try:linux_chromium_ubsan_rel_ng
> Reviewed-on: https://chromium-review.googlesource.com/c/1447854
> Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
> Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
> Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
> Reviewed-by: Georg Neis <neis@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#59411}

Tbr: neis@chromium.org, bmeurer@chromium.org, jkummerow@chromium.org
Bug: v8:5848, v8:5086
Change-Id: I42972b29b8830ed47a00b2b1d408d3005a810c0e
Cq-Include-Trybots: luci.chromium.try:linux_chromium_ubsan_rel_ng
Cq-Include-Trybots: luci.v8.try:v8_linux64_ubsan_rel_ng
Reviewed-on: https://chromium-review.googlesource.com/c/1456302
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59454}
2019-02-08 12:25:27 +00:00
Tamer Tas
bb909b5af5 [tools] auto-format unformatted Torque source files
Presubmit script complains when an unformatted Torque file is submitted.

This CL automates the formatting process of the Torque files.

Presubmit script is run before every 'git cl upload', the workflow will make
sure that the upload is canceled, but the files are formatted.

Bug: chromium:898436, v8:8805
Change-Id: I821ce36907c62e222451e883c5e3e18a9359f20e
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/1458222
Reviewed-by: Daniel Clifford <danno@chromium.org>
Reviewed-by: Sergiy Belozorov <sergiyb@chromium.org>
Commit-Queue: Tamer Tas <tmrts@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59453}
2019-02-08 11:51:37 +00:00
Dan Elphick
c6d2169183 [api] Advance deprecation for Value::BooleanValue
Mark Context version of BooleanValue as V8_DEPRECATED.

Bug: v8:7279, v8:8562
Change-Id: I152f5080d92a940dadea9e8f2ed3f25338e6f099
Reviewed-on: https://chromium-review.googlesource.com/c/1458245
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Dan Elphick <delphick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59452}
2019-02-08 11:33:07 +00:00
Clemens Hammacher
c4411b0be8 [api] Deprecate legacy RegisterExtension method
The new API receives a unique_ptr to avoid leaking the Extension object.
All chromium uses were refactored in https://crrev.com/c/1447652.

R=adamk@chromium.org

Bug: v8:8725
Cq-Include-Trybots: luci.chromium.try:linux-blink-rel
Change-Id: I46a931a73e941fe7b78f5390fec74663677e13e4
Reviewed-on: https://chromium-review.googlesource.com/c/1454723
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59451}
2019-02-08 10:55:17 +00:00
Mythri
648ba1f7dd Defer inferring language mode for PropertyCallbackInfo
This cl: https://chromium-review.googlesource.com/c/v8/v8/+/1421077
changed the implementation of SetProperty to infer the language mode.
Language mode is only required when there is an error to decide if we
have to throw an error or not. However we used to compute language mode
eagerly for PropertyCallbackInfo. This causes regressions in some
benchmarks. This cl changes it by deferring it further by computing
it only when it is actually required.

BUG: v8:8580, chromium:925289
Change-Id: Iba70ec5f9bb3deec16414a1ec418b3963f2144f9
Reviewed-on: https://chromium-review.googlesource.com/c/1454608
Reviewed-by: Adam Klein <adamk@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Mythri Alle <mythria@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59450}
2019-02-08 10:24:27 +00:00
Toon Verwaest
64ea6bb4e5 [interpreter] Rename BuildThisAccess to BuildThisVariableLoad
As requested in https://chromium-review.googlesource.com/c/v8/v8/+/1448313

Change-Id: I89e84600aa4cd3feef3dbf4f5acdaf377e3446f8
Reviewed-on: https://chromium-review.googlesource.com/c/1460463
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59449}
2019-02-08 09:57:26 +00:00
Yang Guo
df5c72b0c3 Revert "Do not enqueue or run a microtask on detached contexts"
This reverts commit 734a657522.

Reason for revert: https://ci.chromium.org/p/v8/builders/luci.v8.ci/V8-Blink%20Linux%2064/29872

Original change's description:
> Do not enqueue or run a microtask on detached contexts
> 
> This CL disables EnqueueMicrotask and RunMicrotasks on detached
> contexts. That is, if an embedder call DetachGlobal() on a v8::Context,
> EnqueueMicrotask on that context will not take effect, and all Microtask
> that is enqueued before DetachGlobal will be cancelled.
> 
> On Blink, this implies that a frame will no longer run a microtask after
> it's navigated away. OTOH, detached frames in Blink are not affected.
> 
> Bug: v8:8124
> Change-Id: I5b00ceef5ea2afb87cf067a65eb95c29bf91176d
> Reviewed-on: https://chromium-review.googlesource.com/c/1416071
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Reviewed-by: Yang Guo <yangguo@chromium.org>
> Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
> Reviewed-by: Adam Klein <adamk@chromium.org>
> Commit-Queue: Taiju Tsuiki <tzik@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#59445}

TBR=yukishiino@chromium.org,adamk@chromium.org,yangguo@chromium.org,bmeurer@chromium.org,verwaest@chromium.org,tzik@chromium.org

Change-Id: I9f5b703e7101aa3c251fe03ed4b52e9d71ae605a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:8124
Reviewed-on: https://chromium-review.googlesource.com/c/1460466
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59448}
2019-02-08 09:34:57 +00:00
Tamer Tas
f1ab74301c [auto-roller] un-break the auto-roller
chromium/buildtools repo was moved and broke the V8 auto-roller.

This CL corrects the old-path.
Failed-Roll: https://chromium-review.googlesource.com/c/v8/v8/+/1459743

R=machenbach@chromium.org,sergiyb@chromium.org
CC=​yangguo@chromium.org

Bug: chromium:930050
Change-Id: I969c73c13bfa996b1010971c37d9325c22048c0a
Reviewed-on: https://chromium-review.googlesource.com/c/1460464
Commit-Queue: Tamer Tas <tmrts@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59447}
2019-02-08 09:30:46 +00:00
Frank Tang
c043538852 [Intl] Speed up Intl.DateTimeFormat constructor
Cache up to 8 Calendar
Cache up to 8 SimpleDateFormat

Improve another ~12% (x1.12)

$ python -u tools/run_perf.py --binary-override-path   out/x64.release/d8 --filter "JSTests/Intl"   test/js-perf-test/JSTests.json
...
NewIntlDateTimeFormat-Intl(Score): 104
...
Compare to baseline in
https://chromium-review.googlesource.com/c/v8/v8/+/1457603


Bug: chromium:928098
Change-Id: Ib3d2d3af1a84c4a856b9e0a40dc06a34aa5d9c71
Reviewed-on: https://chromium-review.googlesource.com/c/1459476
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59446}
2019-02-08 07:32:56 +00:00
tzik
734a657522 Do not enqueue or run a microtask on detached contexts
This CL disables EnqueueMicrotask and RunMicrotasks on detached
contexts. That is, if an embedder call DetachGlobal() on a v8::Context,
EnqueueMicrotask on that context will not take effect, and all Microtask
that is enqueued before DetachGlobal will be cancelled.

On Blink, this implies that a frame will no longer run a microtask after
it's navigated away. OTOH, detached frames in Blink are not affected.

Bug: v8:8124
Change-Id: I5b00ceef5ea2afb87cf067a65eb95c29bf91176d
Reviewed-on: https://chromium-review.googlesource.com/c/1416071
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Taiju Tsuiki <tzik@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59445}
2019-02-08 05:59:16 +00:00
Frank Tang
a9174cf098 [Intl] Speedup by cache DateTimePatternGenerator
$ python -u tools/run_perf.py --binary-override-path   out/x64.release/d8 --filter "JSTests/Intl"   test/js-perf-test/JSTests.json
...
NewIntlDateTimeFormat-Intl(Score): 92.9

Compare to baseline in
https://chromium-review.googlesource.com/c/v8/v8/+/1455727

improve another x3.5

Bug: chromium:928098
Change-Id: Iab6b9e2d58231832c54bc626d01b25a3813537fa
Reviewed-on: https://chromium-review.googlesource.com/c/1457603
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59444}
2019-02-07 19:40:59 +00:00
Igor Sheludko
7e914db539 [snapshot][ptr-compr] Simplify deserialization of references embedded in code
... and use RelocInfo iteration instead of skip-and-unaligned-write sequences.
This is a step towards avoiding unaligned stores via UnalignedSlot.

Various cleanup CLs will follow.

Bug: v8:8794
Change-Id: I62faedfa1c1ababe4b185fa8d7f2c6c1baa5cf79
Reviewed-on: https://chromium-review.googlesource.com/c/1456579
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59443}
2019-02-07 18:08:59 +00:00
Clemens Hammacher
7a8cd55146 [wasm] Check that sync and async errors match
This makes the existing error message tests also test the error
produced by asynchronous compilation and instantiation.
It also slightly tweaks the error message to contain the name of the
API function invoked instead of "WebAssembly Instantiation".

R=titzer@chromium.org

Cq-Include-Trybots: luci.chromium.try:linux-blink-rel
Bug: chromium:926311
Change-Id: If4ab963cee8267d43b289169d21b31637c471d6d
Reviewed-on: https://chromium-review.googlesource.com/c/1456085
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Ben Titzer <titzer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59442}
2019-02-07 16:41:47 +00:00
Ujjwal Sharma
155ccadda6 [string] port String.p.endsWith to torque
Port String.prototype.endsWith from a CPP builtin to a Torque builtin.

Spec: https://tc39.github.io/ecma262/#sec-string.prototype.endswith
Bug: v8:8400
Change-Id: I4ac8cb92acb68389db844deaecc9ae1c6e7d6bd5
Reviewed-on: https://chromium-review.googlesource.com/c/1454677
Commit-Queue: Simon Zünd <szuend@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Simon Zünd <szuend@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59441}
2019-02-07 15:39:18 +00:00
Jaroslav Sevcik
daf67d6de3 Reland "Ship constant field tracking"
This is a reland of 78ed0e3fdb

The breakage was unrelated to constant field tracking (see
the linked bugs).

Original change's description:
> Ship constant field tracking
>
> Bug: v8:8361
> Change-Id: I25c52c708517cf27add89e0c5c97e6d21abb2a9a
> Reviewed-on: https://chromium-review.googlesource.com/c/1456089
> Reviewed-by: Igor Sheludko <ishell@chromium.org>
> Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#59415}

Bug: v8:8361, v8:8799, v8:8801
Change-Id: I318768b925f3efd285cb27aa93e6de35fdcced42
Reviewed-on: https://chromium-review.googlesource.com/c/1458238
Reviewed-by: Sigurd Schneider <sigurds@chromium.org>
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59440}
2019-02-07 15:22:29 +00:00
Andreas Haas
dd6f4d4f4c [wasm][anyref] Implement decoding of table.get and table.set
R=titzer@chromium.org

Bug: v8:7581
Change-Id: I857a40a0f955b3506d7958d2128a1b4560cff0bc
Reviewed-on: https://chromium-review.googlesource.com/c/1458236
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Ben Titzer <titzer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59439}
2019-02-07 14:45:38 +00:00
Ulan Degenbaev
5208e1da45 [heap] Use SizeOfObjects() instead of Size() for accounting new_lo_space
The Size() includes the page header.

Bug: chromium:852420
Change-Id: I1f2da2309ff38f2222c82b5758937bdaf5036f12
Reviewed-on: https://chromium-review.googlesource.com/c/1458242
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#59438}
2019-02-07 14:28:33 +00:00