Commit Graph

47102 Commits

Author SHA1 Message Date
Igor Sheludko
9367f80f17 [builtins] Implement fast path of Object.assign using CSA.
Bug: v8:5988
Change-Id: I2e90ed8df6b966e04299774e50aeb2913a8c1922
Reviewed-on: https://chromium-review.googlesource.com/999603
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52610}
2018-04-16 02:06:46 +00:00
Jakob Kummerow
8cc5a7239a [bigint] Update "bigint < string" semantics
Per the spec change at [1], Abstract Relational Comparison between a
BigInt and a String converts the String to BigInt via StringToBigInt
before performing the comparison. Before this change, the String was
converted to a Number, and a BigInt/Number comparison was performed.

[1] https://github.com/tc39/proposal-bigint/pull/139

Bug: v8:6791
Change-Id: I40b4f4ddc78977adb0d44180eb58e0f9a8a70cb6
Reviewed-on: https://chromium-review.googlesource.com/1004117
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52609}
2018-04-15 00:53:36 +00:00
Ben L. Titzer
88b08f12f5 [wasm] Use the proper constant for exports limit
R=gdeepti@chromium.org

Change-Id: I3d0a21c6db671718b9f41fb8392f6900b2fecf27
Reviewed-on: https://chromium-review.googlesource.com/1013197
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Commit-Queue: Ben Titzer <titzer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52608}
2018-04-14 22:13:45 +00:00
Junliang Yan
9adf8fa8d6 PPC/s390: [ubsan] Change Address typedef to uintptr_t
Port 2459046c1d

Original Commit Message:

    The "Address" type is V8's general-purpose type for manipulating memory
    addresses. Per the C++ spec, pointer arithmetic and pointer comparisons
    are undefined behavior except within the same array; since we generally
    don't operate within a C++ array, our general-purpose type shouldn't be
    a pointer type.

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

Change-Id: Ic30ef19019e5b39b01f90587011c6a1b06c4b7a1
Reviewed-on: https://chromium-review.googlesource.com/1012461
Reviewed-by: Junliang Yan <jyan@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#52607}
2018-04-14 20:39:55 +00:00
Junliang Yan
5e8bc1c316 PPC/s390: [stubs] Convert DoubleToIStub and MathPowStub to builtins
Port a3b6067525

Original Commit Message:

    This is mostly a simple copy & paste of the stub implementation from
    code-stubs-arch.cc to builtins-arch.cc.

    The conversion allows removal of a special case for the DoubleToIStub
    within the compiler & wasm pipelines, and also makes the following
    builtins isolate-independent (in conjunction with
    https://crrev.com/c/1006581):

    TFC BitwiseAnd
    TFC BitwiseOr
    TFC BitwiseXor
    TFC Exponentiate
    TFC ShiftLeft
    TFC ShiftRight
    TFC ShiftRightLogical
    TFJ AtomicsAdd
    TFJ AtomicsAnd
    TFJ AtomicsCompareExchange
    TFJ AtomicsExchange
    TFJ AtomicsLoad
    TFJ AtomicsOr
    TFJ AtomicsStore
    TFJ AtomicsSub
    TFJ AtomicsXor
    TFJ MathClz32
    TFJ MathImul
    TFJ MathPow
    TFJ NumberParseInt
    TFJ StringFromCharCode
    TFJ TypedArrayFrom
    TFJ TypedArrayOf
    TFJ TypedArrayPrototypeMap

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

Change-Id: Iee9fc5671646772625556717db052b78089c5c66
Reviewed-on: https://chromium-review.googlesource.com/1013247
Reviewed-by: Junliang Yan <jyan@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#52606}
2018-04-14 19:39:45 +00:00
Junliang Yan
3110259efb PPC/s390: [stubs] Remove return register argument from DoubleToIStub
Port 87557649e4

Original Commit Message:

    This changes DoubleToIStub to return its result on the stack instead
    of a specific return register.

    In a follow-up, the DoubleToIStub could be converted into a builtin.

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

Change-Id: I952fec4fbe004e2734a84ba853f4f5a33c8dd8ce
Reviewed-on: https://chromium-review.googlesource.com/1013418
Reviewed-by: Junliang Yan <jyan@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#52605}
2018-04-14 16:40:15 +00:00
v8-autoroll
c1c6f55e97 Update V8 DEPS.
Rolling v8/build: 7726657..80b7a3c

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/67d01a2..f718fb1

Rolling v8/tools/clang: d7c36b0..5395a74

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

Change-Id: I2981aa8a42866ecc06091a0090ea69f3d5829a5d
Reviewed-on: https://chromium-review.googlesource.com/1012820
Commit-Queue: v8 autoroll <v8-autoroll@chromium.org>
Reviewed-by: v8 autoroll <v8-autoroll@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52604}
2018-04-14 07:28:37 +00:00
Alexey Kozyatinskiy
edf15167b9 Reland "[inspector] added timeout argument for Runtime.evaluate"
This is a reland of deb875f7ea

Original change's description:
> [inspector] added timeout argument for Runtime.evaluate
> 
> R=yangguo@chromium.org,dgozman@chromium.org
> 
> Bug: none
> Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
> Change-Id: I31667b3d5f39db9d899d58acd5205a9c34e570db
> Reviewed-on: https://chromium-review.googlesource.com/1005985
> Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
> Reviewed-by: Yang Guo <yangguo@chromium.org>
> Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#52594}

Bug: none
Change-Id: Ib8aff5d9f83e41fc6c2019712708fda074bd1ad9
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
Reviewed-on: https://chromium-review.googlesource.com/1012724
Reviewed-by: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52603}
2018-04-14 07:27:32 +00:00
Alexey Kozyatinskiy
bbf28ecb18 fixed build after intptr_t -> uintptr_t migration
Bug: none
Change-Id: I156bfe9846d0890ffdf482bcc8c84da53fe1af61
TBR: jkummerow@chromium.org
NOTREECHECKS: true
NOTRY: true
Reviewed-on: https://chromium-review.googlesource.com/1013392
Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
Reviewed-by: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52602}
2018-04-14 07:12:22 +00:00
Jakob Kummerow
2459046c1d [ubsan] Change Address typedef to uintptr_t
The "Address" type is V8's general-purpose type for manipulating memory
addresses. Per the C++ spec, pointer arithmetic and pointer comparisons
are undefined behavior except within the same array; since we generally
don't operate within a C++ array, our general-purpose type shouldn't be
a pointer type.

Bug: v8:3770
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: Ib96016c24a0f18bcdba916dabd83e3f24a1b5779
Reviewed-on: https://chromium-review.googlesource.com/988657
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52601}
2018-04-14 01:25:28 +00:00
Deepti Gandluri
1bb5d012bb [arm64] Cleanup visitors for Atomic operations
Change-Id: I4e32786d7c100161daf3d245d887dfe19b164394
Reviewed-on: https://chromium-review.googlesource.com/1013046
Reviewed-by: Ben Titzer <titzer@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52600}
2018-04-13 21:54:38 +00:00
Fabrice de Gans-Riberi
b40cc63e37 Fix Fuchsia build configuration.
This was missed in the original CL switching |is_posix| to false for
Fuchsia.

Bug: chromium:812974
Change-Id: I532516296c6b6ece9805c2f986c8dded00a798df
Reviewed-on: https://chromium-review.googlesource.com/1011251
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Fabrice de Gans-Riberi <fdegans@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52599}
2018-04-13 18:28:45 +00:00
Deepti Gandluri
10233179d8 [wasm] Add Remaining I64Atomic operations for ARM64
- Add Implementation for I64Atomic{Load, Store, Exchange,
CompareExchange} for supported MemTypes/Representations
 - Refactoring to simplify instruction selection
 - Enable tests for ARM64

Bug: v8:6532
Change-Id: I4c4a65fd3bbdc6955eda29d7e08d6eef29c55628
Reviewed-on: https://chromium-review.googlesource.com/1003225
Reviewed-by: Martyn Capewell <martyn.capewell@arm.com>
Reviewed-by: Bill Budge <bbudge@chromium.org>
Reviewed-by: Ben Smith <binji@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52598}
2018-04-13 18:27:41 +00:00
Gus Caplan
39d546a240 [api] introduce v8::Value::IsModuleNamespaceObject
This allows an embedder to check if a Value is a module namespace object.

Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Idffceff451dd5f5c6a53d4cb3ce02c1c2c5b653c
Reviewed-on: https://chromium-review.googlesource.com/1011762
Reviewed-by: Georg Neis <neis@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52597}
2018-04-13 18:26:36 +00:00
Georg Neis
42049b43c9 [interpreter] Move desugaring of spread super call to bytecode generator
This patch moves the desugaring from the parser to the bytecode
generator for super calls that have a spread at a non last position.

This allows us to have the post super() call behavior, such as
initializing instance fields in one place in VisitCallSuper.

Bug: v8:7642
Change-Id: I00a693beb7078a63282359c1121b66bb62c157c8
Reviewed-on: https://chromium-review.googlesource.com/1009907
Commit-Queue: Georg Neis <neis@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Reviewed-by: Mythri Alle <mythria@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52596}
2018-04-13 18:25:31 +00:00
Deepti Gandluri
2af0c316c2 Revert "[inspector] added timeout argument for Runtime.evaluate"
This reverts commit deb875f7ea.

Reason for revert: ASAN failure closes tree. 
https://ci.chromium.org/buildbot/client.v8/V8%20Mac64%20ASAN/17377 


Original change's description:
> [inspector] added timeout argument for Runtime.evaluate
> 
> R=​yangguo@chromium.org,dgozman@chromium.org
> 
> Bug: none
> Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
> Change-Id: I31667b3d5f39db9d899d58acd5205a9c34e570db
> Reviewed-on: https://chromium-review.googlesource.com/1005985
> Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
> Reviewed-by: Yang Guo <yangguo@chromium.org>
> Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#52594}

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

Change-Id: I61f996143d8c6436cbf9d3905d103047578aff0c
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: none
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
Reviewed-on: https://chromium-review.googlesource.com/1012562
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52595}
2018-04-13 17:54:31 +00:00
Alexey Kozyatinskiy
deb875f7ea [inspector] added timeout argument for Runtime.evaluate
R=yangguo@chromium.org,dgozman@chromium.org

Bug: none
Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng;master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I31667b3d5f39db9d899d58acd5205a9c34e570db
Reviewed-on: https://chromium-review.googlesource.com/1005985
Commit-Queue: Aleksey Kozyatinskiy <kozyatinskiy@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52594}
2018-04-13 16:19:40 +00:00
Ivica Bogosavljevic
fcb8061e98 MIPS[64]: Fix register overwrite in ShiftPair instructions
This patch fixes register overwrite in ShrPair, ShlPair and SarPair
instructions. Additionally, we rename kLithiumScratch register
register since lithium is not present anymore.

Change-Id: I65861c4f27d2161bcf49cf02ca8987eb82c997ea
Reviewed-on: https://chromium-review.googlesource.com/1012110
Reviewed-by: Sreten Kovacevic <sreten.kovacevic@mips.com>
Commit-Queue: Sreten Kovacevic <sreten.kovacevic@mips.com>
Cr-Commit-Position: refs/heads/master@{#52593}
2018-04-13 15:32:51 +00:00
Georg Neis
a86fa96813 [interpreter] Refactor VisitArrayLiteral.
This factors out the element insertion code, so that it can be reused
elsewhere in a follow-up CL.

Change-Id: Ic085c8359b3024f381803ce64b49e976018277f9
Reviewed-on: https://chromium-review.googlesource.com/1010068
Reviewed-by: Mythri Alle <mythria@chromium.org>
Reviewed-by: Sathya Gunasekaran <gsathya@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52592}
2018-04-13 13:50:02 +00:00
jgruber
a3b6067525 [stubs] Convert DoubleToIStub and MathPowStub to builtins
This is mostly a simple copy & paste of the stub implementation from
code-stubs-arch.cc to builtins-arch.cc.

The conversion allows removal of a special case for the DoubleToIStub
within the compiler & wasm pipelines, and also makes the following
builtins isolate-independent (in conjunction with
https://crrev.com/c/1006581):

TFC BitwiseAnd
TFC BitwiseOr
TFC BitwiseXor
TFC Exponentiate
TFC ShiftLeft
TFC ShiftRight
TFC ShiftRightLogical
TFJ AtomicsAdd
TFJ AtomicsAnd
TFJ AtomicsCompareExchange
TFJ AtomicsExchange
TFJ AtomicsLoad
TFJ AtomicsOr
TFJ AtomicsStore
TFJ AtomicsSub
TFJ AtomicsXor
TFJ MathClz32
TFJ MathImul
TFJ MathPow
TFJ NumberParseInt
TFJ StringFromCharCode
TFJ TypedArrayFrom
TFJ TypedArrayOf
TFJ TypedArrayPrototypeMap

Drive-by: dead code removal & TODOs in code-stubs.h.

Bug: v8:6666
Change-Id: I763cba2242bcadc2d130b0aaa16a9787212b466a
Reviewed-on: https://chromium-review.googlesource.com/1012024
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52591}
2018-04-13 12:12:09 +00:00
jgruber
7c36eff8d5 Add Int32 matching to CodeAssembler::ToInt32Constant
Prior to this, ToInt32Constant only matched Int64Constant nodes within
the int32_t range, but did not match actual Int32Constant nodes.

Change-Id: I4e67ea57f53f3b1d4b1f2b27f11ebdeffb2bf357
Reviewed-on: https://chromium-review.googlesource.com/1012022
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52590}
2018-04-13 11:21:44 +00:00
Mathias Bynens
2c7c8da127 [js-perf-test] Add String#{starts,ends}With micro-benchmark
This patch adds a micro-benchmark comparing
`string.startsWith(singleCodeUnit)`, `string[0]`,
`string.endsWith(singleCodeUnit)`, and `string[string.length - 1]`.

The benchmark can be used to measure any String#{starts,ends}With
optimizations we implement in the future.

Test:

    tools/run_perf.py --binary-override-path=out/x64.release/d8 \
      --filter=JSTests/Strings/StringStartsEndsWithComparison \
      --extra-flags=--trace-turbo test/js-perf-test/JSTests.json

Bug: v8:7453
Change-Id: I68cad197fbcbfc6b1938fc437776c319ee9f81df
Reviewed-on: https://chromium-review.googlesource.com/1011619
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Mathias Bynens <mathias@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52589}
2018-04-13 09:36:29 +00:00
Simon Zünd
b8defbc99d Add missing file to resources for TypedArray.p.sort benchmarks.
R=sergiyb@chromium.org

Bug: v8:7382
Change-Id: I6fc0b2ca9857a80192e1a202ee516f544105ee56
Reviewed-on: https://chromium-review.googlesource.com/1011611
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Commit-Queue: Simon Zünd <szuend@google.com>
Cr-Commit-Position: refs/heads/master@{#52588}
2018-04-13 08:58:39 +00:00
jgruber
87557649e4 [stubs] Remove return register argument from DoubleToIStub
This changes DoubleToIStub to return its result on the stack instead
of a specific return register.

In a follow-up, the DoubleToIStub could be converted into a builtin.

Bug: v8:6666
Change-Id: I7852e1586c8f7b56bc5d2545a7bf6238dd2ad650
Reviewed-on: https://chromium-review.googlesource.com/1009702
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52587}
2018-04-13 07:09:59 +00:00
v8-autoroll
3d468c3886 Update V8 DEPS.
Rolling v8/build: bf6af18..7726657

Rolling v8/buildtools: e8aa02e..8febfea

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/a227198..67d01a2

Rolling v8/third_party/googletest/src: 7e5f90d..b640d87

Rolling v8/third_party/icu: d888fd2..aff99f5

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

Change-Id: I9ee0ac81c771ba5659655d93bf2d46cbc2dec2b8
Reviewed-on: https://chromium-review.googlesource.com/1011145
Reviewed-by: v8 autoroll <v8-autoroll@chromium.org>
Commit-Queue: v8 autoroll <v8-autoroll@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52586}
2018-04-13 03:42:28 +00:00
jing.bao
820755e804 [wasm] implement simd lowering for AllTrue/AnyTrue
Change-Id: I7749eae88e4a23d8fe2422e28b8dbcbbfb11f758
Reviewed-on: https://chromium-review.googlesource.com/991733
Reviewed-by: Aseem Garg <aseemgarg@chromium.org>
Commit-Queue: Jing Bao <jing.bao@intel.com>
Cr-Commit-Position: refs/heads/master@{#52585}
2018-04-13 02:11:38 +00:00
Junliang Yan
ebe3e445cf PPC/s390: fix endianess issue in Generate_InterpreterEntryTrampoline
R=joransiu@ca.ibm.com

Change-Id: I97c8e5034cf3541707bf5f5d22359cdcf66f87e1
Reviewed-on: https://chromium-review.googlesource.com/1011585
Reviewed-by: Joran Siu <joransiu@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#52584}
2018-04-13 00:37:48 +00:00
Junliang Yan
fa549bc5c1 PPC/s390: Fix endianess issue on Generate_ConstructFunction
R=joransiu@ca.ibm.com

Change-Id: Ic44ce01e4d9487c7319125df46914a528938071d
Reviewed-on: https://chromium-review.googlesource.com/1010920
Reviewed-by: Joran Siu <joransiu@ca.ibm.com>
Commit-Queue: Junliang Yan <jyan@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#52583}
2018-04-12 20:32:49 +00:00
Sigurd Schneider
d71c34dcee Revert "Introduce CodeReference"
This reverts commit 4d7ad46db4.

Reason for revert: Makes i18n bot red
https://logs.chromium.org/v/?s=chromium%2Fbb%2Fclient.v8%2FV8_Linux_-_noi18n_-_debug%2F20162%2F%2B%2Frecipes%2Fsteps%2FCheck%2F0%2Flogs%2FAssemblerIa32JumpTabl..%2F0

Original change's description:
> Introduce CodeReference
> 
> Add a struct CodeReference that can be stack allocated to pass a
> reference to either an on-heap code object or off-heap WasmCode object
> in a gc safe manner. The struct also provides a common interface such
> that code can be written independently of the kind of code object it
> references.
> 
> Change-Id: I5a6f74462e6e141d167c7fd9bac8c21941fd83b1
> Reviewed-on: https://chromium-review.googlesource.com/977905
> Commit-Queue: Stephan Herhut <herhut@chromium.org>
> Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#52580}

TBR=mstarzinger@chromium.org,herhut@chromium.org

Change-Id: I9c49da9ee97e7423284e58bec3fdc1d212ff1af0
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/1010544
Reviewed-by: Sigurd Schneider <sigurds@chromium.org>
Commit-Queue: Sigurd Schneider <sigurds@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52582}
2018-04-12 16:56:16 +00:00
peterwmwong
ae4529f9e1 [builtins] Add fast paths to String.p.matchAll
Add fast paths when RegExp and RegExp result are fast wherever possible.

As shown below, this CL improves the performance of calling S.p.matchAll and
iterating over matches.

Before:

StringMatchAllBuiltinRegExpIteratorCreation-Strings(Score): 5002
StringMatchAllBuiltinStringIteratorCreation-Strings(Score): 13798
StringMatchAllBuiltinString-Strings(Score): 197
StringMatchAllManualString-Strings(Score): 454
StringMatchAllBuiltinRegExp-Strings(Score): 193
StringMatchAllManualRegExp-Strings(Score): 453
StringMatchAllBuiltinZeroWidth-Strings(Score): 97.2
StringMatchAllBuiltinZeroWidthUnicode-Strings(Score): 95.9

After:

StringMatchAllBuiltinRegExpIteratorCreation-Strings(Score): 15437
StringMatchAllBuiltinStringIteratorCreation-Strings(Score): 16708
StringMatchAllBuiltinString-Strings(Score): 392
StringMatchAllManualString-Strings(Score): 452
StringMatchAllBuiltinRegExp-Strings(Score): 394
StringMatchAllManualRegExp-Strings(Score): 484
StringMatchAllBuiltinZeroWidth-Strings(Score): 409
StringMatchAllBuiltinZeroWidthUnicode-Strings(Score): 413

Bug: v8:6890
Change-Id: I6fcc1003a471314cf412aac456d42286b2926810
Reviewed-on: https://chromium-review.googlesource.com/1005400
Commit-Queue: Peter Wong <peter.wm.wong@gmail.com>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52581}
2018-04-12 16:13:44 +00:00
Stephan Herhut
4d7ad46db4 Introduce CodeReference
Add a struct CodeReference that can be stack allocated to pass a
reference to either an on-heap code object or off-heap WasmCode object
in a gc safe manner. The struct also provides a common interface such
that code can be written independently of the kind of code object it
references.

Change-Id: I5a6f74462e6e141d167c7fd9bac8c21941fd83b1
Reviewed-on: https://chromium-review.googlesource.com/977905
Commit-Queue: Stephan Herhut <herhut@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52580}
2018-04-12 15:50:19 +00:00
Clemens Hammacher
7176708dc5 [wasm] Remove CodeGenerationSchedule
It was supposed to add some randomness to the order of generated code
objects, but it is totally unclear whether this is working, needed or
helpful. This this adds considerable complexity, remove it for now.

R=ahaas@chromium.org
CC=titzer@chromium.org

Change-Id: Ie2b8613bbdeedb48b2e72f5843bacd2c4873edf5
Reviewed-on: https://chromium-review.googlesource.com/1010082
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52579}
2018-04-12 15:49:14 +00:00
peterwmwong
7bdbe77a3f [builtins] Fix missing ToString in RegExp.p.match
It is not safe to assume the first match is a string just
because the RegExp result is fast.

Bug: chromium:831943
Change-Id: Idd40f8b75312f0be54f45f626dc017339033abc6
Reviewed-on: https://chromium-review.googlesource.com/1009325
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Peter Wong <peter.wm.wong@gmail.com>
Cr-Commit-Position: refs/heads/master@{#52578}
2018-04-12 14:54:54 +00:00
Corentin Wallez
8c25fefbd8 auto_roll.py: use LUCI for the optional GPU tests on Windows
BUG=chromium:815092

Change-Id: Ide35e070c01e910545a6d04bd45382d91dbb45e5
Reviewed-on: https://chromium-review.googlesource.com/1008262
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52577}
2018-04-12 14:29:03 +00:00
Clemens Hammacher
f156887d59 [Liftoff] Implement i64.mul
This adds support for i64.mul. On x64, the implementation is straight
forward, on ia32, we need three multiplies and two additions.

R=ahaas@chromium.org

Bug: v8:6600
Change-Id: I083872c1a6885458396ae5ff29e29d057e458561
Reviewed-on: https://chromium-review.googlesource.com/1009943
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52576}
2018-04-12 14:20:24 +00:00
Ivica Bogosavljevic
e184dcae96 MIPS[64]: Implement Round, Ceil, Floor and Trunc in LiftOff
Change-Id: I13c58a462ec844b6df0e55bbbbf9134a476363c4
Reviewed-on: https://chromium-review.googlesource.com/1009908
Reviewed-by: Sreten Kovacevic <sreten.kovacevic@mips.com>
Commit-Queue: Ivica Bogosavljevic <ivica.bogosavljevic@mips.com>
Cr-Commit-Position: refs/heads/master@{#52575}
2018-04-12 14:16:34 +00:00
Simon Zünd
5874911bc7 Extend Array.p.sort benchmarks.
This adds benchmarks that sort all element kinds with multiple comparison
functions. This also adds benchmarks that cause the element kind of
the array to change after x amount of comparisons.
The last set of benchmarks that are added, measure performance on
pre-sorted arrays.

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

Bug: v8:7382
Change-Id: I620de37f4a28f8096682bb708ea4f7a9a21d5316
Reviewed-on: https://chromium-review.googlesource.com/1009602
Commit-Queue: Peter Marshall <petermarshall@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52574}
2018-04-12 14:11:34 +00:00
sreten.kovacevic
44007be068 [Liftoff][mips] Implement f32 and f64 set_cond instructions
Also, implement supporting function for translating Condition to
MIPS FPUCondition.

Bug: v8:6600
Change-Id: I5a3497a8445e2fc5a18abd56a83cd1451c2c48ec
Reviewed-on: https://chromium-review.googlesource.com/1010163
Commit-Queue: Sreten Kovacevic <sreten.kovacevic@mips.com>
Reviewed-by: Ivica Bogosavljevic <ivica.bogosavljevic@mips.com>
Cr-Commit-Position: refs/heads/master@{#52573}
2018-04-12 12:43:13 +00:00
Igor Sheludko
2b7e063f2a [csa][runtime] Introduce IsCustomElementsReceiverInstanceType() predicate and friends.
Bug: v8:7570
Change-Id: I3349062f82df89a5a1a484b22fea5c5763d264f7
Reviewed-on: https://chromium-review.googlesource.com/1007662
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52572}
2018-04-12 12:14:55 +00:00
Peter Marshall
4feb5ce7fd [cpu-profiler] Fix bugs and add tests for JITLineInfoTable
Looking up line numbers with the JITLineInfoTable would sometimes give
wrong answers. Fix these bugs and add a cctest for this data structure.

Also do some cleanup while we're here like inlining the (empty)
constructor and destructor and removing the empty() method which is
only used unnecessarily anyway, to make the contract of
GetSourceLineNumber a bit clearer.

Also rename the data structure to SourcePositionTable, because it
doesn't just provide info for JIT code, but also bytecode, and 'Info'
is pretty ambiguous.

Bug: v8:7018
Change-Id: I126581c844d85df6b2b3f80f2f5acbce01c16ba1
Reviewed-on: https://chromium-review.googlesource.com/1006795
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Peter Marshall <petermarshall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52571}
2018-04-12 11:48:05 +00:00
Michael Hablich
c6e3e1c0a8 Update version to 6.8
TBR=machenbach@chromium.org
NOTRY=true

Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
Change-Id: Ifd0eee86da0bf8b8e234b6f55ddce77239d0a3a5
Reviewed-on: https://chromium-review.googlesource.com/1009905
Commit-Queue: Michael Hablich <hablich@chromium.org>
Reviewed-by: Michael Hablich <hablich@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52570}
2018-04-12 10:58:04 +00:00
Michael Achenbach
8a9db8442f [CQ] Use linux x64 debug bot on CQ instead of ia32
NOTRY=true
TBR=sergiyb@chromium.org

Change-Id: I1f7281fdf4144ad192efa6581df3109a0f6abd68
Reviewed-on: https://chromium-review.googlesource.com/1010067
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52569}
2018-04-12 10:27:47 +00:00
Clemens Hammacher
d30af614a9 [wasm] Use correct types for instance fields
Memory size, mask and function table size are 32-bit values in wasm.
There is no relation to pointer size. Hence, replace uintptr_t by
uint32_t.
These fields are already being loaded as uint32_t in wasm-compiler.cc,
causing problems on big endian systems.

R=mstarzinger@chromium.org

Change-Id: Ie03b552934262d5fa8de9998abdd7409e60af690
Reviewed-on: https://chromium-review.googlesource.com/1005154
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Michael Starzinger <mstarzinger@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52568}
2018-04-12 10:06:36 +00:00
Sergiy Byelozyorov
c59698681d [tools] Whitespace CL
TBR=sergiyb@chromium.org

Bug: chromium:827890
Change-Id: I25d647f3511c2101c30cca88b91c372ee4fee05b
Reviewed-on: https://chromium-review.googlesource.com/1009662
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Commit-Queue: Sergiy Byelozyorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52567}
2018-04-12 09:59:16 +00:00
Toon Verwaest
225bc87e2e Revert '[runtime] Temporarily disable double fields unboxing.'
Bug: chromium:831981
Change-Id: Ie0e4bb6ca585f76829e0100202e01d02c521ac51
Reviewed-on: https://chromium-review.googlesource.com/1009902
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52566}
2018-04-12 09:38:46 +00:00
sreten.kovacevic
72a126b947 [Liftoff][mips] Add big endian support
Add big endian support for MIPS in Liftoff.

Bug: v8:6600
Change-Id: Ibd90e7b6a8f0f826bd70ef489135cabcadeed7b0
Reviewed-on: https://chromium-review.googlesource.com/995457
Commit-Queue: Sreten Kovacevic <sreten.kovacevic@mips.com>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Reviewed-by: Ivica Bogosavljevic <ivica.bogosavljevic@mips.com>
Cr-Commit-Position: refs/heads/master@{#52565}
2018-04-12 09:19:44 +00:00
Michael Achenbach
7f564f457f [CQ] Add linux64 debug trybot to CQ experiment
It'll replace the linux32 debug trybot in CQ soon when it's confirmed stable.

This also adds the corresponding MB config.

NOTRY=true
TBR=sergiyb@chromium.org

Change-Id: I99464d7d2d776390e59c48f0f65daa213a14f0f7
Reviewed-on: https://chromium-review.googlesource.com/1009746
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52564}
2018-04-12 09:04:41 +00:00
Michael Achenbach
88a93e8f8e [release] Deprecate v8rel
NOTRY=true

Change-Id: Ie97090587841830ed82097f5411131a9dc9ff5e6
Reviewed-on: https://chromium-review.googlesource.com/1009742
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Michael Hablich <hablich@chromium.org>
Reviewed-by: Sergiy Byelozyorov <sergiyb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52563}
2018-04-12 08:56:01 +00:00
Vlad Tsyrklevich
5fb562fcf7 Reland "Enable cfi-icall on the v8 CFI bots"
This is a reland of 9a7e9cf2a7

Original change's description:
> Enable cfi-icall on the v8 CFI bots
>
> BUG=v8:7164
>
> Change-Id: I7522ba6ac2bde89c84bcd49bc116a432091a2938
> Reviewed-on: https://chromium-review.googlesource.com/990802
> Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
> Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#52343}

CQ_INCLUDE_TRYBOTS=luci.v8.try:v8_linux64_cfi_rel_ng

Bug: v8:7164
Change-Id: I683116e86685fb7295bb576e57ce85fed7445b3c
Reviewed-on: https://chromium-review.googlesource.com/1003692
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52562}
2018-04-12 08:44:39 +00:00
Clemens Hammacher
a05c7d51b1 [wasm] Fix data race on failed_ field
R=ahaas@chromium.org

Bug: chromium:831989, chromium:824681
Change-Id: I0a8b2cc9f80af5f954bd358c30a3c6d84b6adeae
Reviewed-on: https://chromium-review.googlesource.com/1009603
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Clemens Hammacher <clemensh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52561}
2018-04-12 08:40:48 +00:00