Commit Graph

73062 Commits

Author SHA1 Message Date
Shu-yu Guo
4b4e073007 [string] Don't MakeThin on shared strings.
This is a temporary solution so prototyping of shared structs and shared
strings can be worked on in parallel.

Bug: v8:12007
Change-Id: Ic849ec66da1d3824d50d695f16e4b77380afa015
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3379222
Reviewed-by: Patrick Thier <pthier@chromium.org>
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78570}
2022-01-11 20:02:37 +00:00
Andreas Haas
53018f4eb4 [wasm] Throw an exception when wasm memory allocation fails
V8 crashed with a FATAL when memory allocation during instantiation
failed. With this CL, a RangeError is thrown instead.

This is not the only possible OOM that can happen during the startup of
a WebAssembly app, but since the allocation of WebAssembly memory is
among the biggest allocations, this change may already prevent several
crashes.

R=clemensb@chromium.org

Bug: chromium:1268898
Change-Id: I9376830ba2fe9df62b5595b6b19c92e35a75dfda
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3380586
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78569}
2022-01-11 19:52:47 +00:00
Igor Sheludko
4ecd70a284 [ext-code-space] Fix CodeRange hint logic on Windows and Linux
Windows requires additional writable page to be allocated in front of
the code range, but at the same time the code range must not cross 4 GB
boundary in order to make Code pointer compression work for Code
pointers. All these constraints make the logic of hint calculation too
dependent on what VirtualMemoryCage::InitReservation() would do with
the provided hint. This CL simplifies the hint calculation and fully
relies on VirtualMemoryCage::InitReservation() to do the right thing.

On Linux the implementation of OS::GetFreeMemoryRangesWithin() doesn't
work when Chromium sandbox is enabled, so we use the beginning of the
preferred short builtin calls region as a hint. It should be at least
as good as the fallback hint but with higher chances to point to free
address space location.

Bug: v8:11880
Change-Id: I0b6ebec98dd0cf483f67e6ba8a919deb9ce7cc25
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3380585
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78568}
2022-01-11 17:03:56 +00:00
Piotr Sikora
3e0fad5aeb Fix build rules for ppc64.
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: Ib4dc67fcb58d7d8f7e48752c579468229c23de52
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375469
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Junliang Yan <junyan@redhat.com>
Cr-Commit-Position: refs/heads/main@{#78567}
2022-01-11 16:37:31 +00:00
Milad Fa
9b8146566b PPC/AIX [simd]: Implement vector load/store lane and load extend
This CL takes advantage of the P9 `vector byte-reverse`
instructions to add to support to BE platforms.

Change-Id: Ia022e056ca61373b7f8f7754ec76e94774b80af3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3378922
Reviewed-by: Junliang Yan <junyan@redhat.com>
Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
Cr-Commit-Position: refs/heads/main@{#78566}
2022-01-11 16:28:13 +00:00
Manos Koukoutos
a9668e25e6 [wasm-gc] Introduce supertype of all arrays
We introduce a type arrayref, which is a supertype of all array types
and a subtype of dataref. We change array.len to accept values of type
(ref null array).

Drive-by: Fix kEq/kData case in TypecheckJSObject.

Bug: v8:7748
Change-Id: I47c6a4487ddf5e7280c1427f43abe87a97c896bd
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3368105
Reviewed-by: Simon Zünd <szuend@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78565}
2022-01-11 13:43:26 +00:00
Andreas Haas
eb129a5cf1 Reland "[wasm] Lazy compilation after deserialization"
The original CL introduced a test that does not work when it is executed
concurrently on multiple isolates. This CL skips this test
configuration.

Original change's description:
> [wasm] Lazy compilation after deserialization
>
> The serialization format contains one boolean flag per function which
> specifies whether the function code exists in the serialized module or
> not. With this CL, this boolean flag is extended to a three-value flag
> which indicates whether the function exists, and if not, whether the
> function was executed before serialization. This information can then be
> used upon deserialization to compile only those functions that were
> executed before serialization.
>
> Design doc: https://docs.google.com/document/d/1U3uqq4njqLqFhr1G2sU_bmpQxY-3bvfG55udSb-DvA4/edit?usp=sharing
>
> Bug: v8:12281

Change-Id: I36ce90b37736172aa01c47ab04e154ec8ea2d8aa
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3380590
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78564}
2022-01-11 13:13:56 +00:00
JianxiaoLuIntel
e7f92432db [tool] fix typo in heap-layout and system-analyzer
Change-Id: I443d6e84fb3ca9d27456300b777105319ec0fe25
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3352457
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78563}
2022-01-11 13:06:21 +00:00
Victor Gomes
b6092749a3 [bazel] Adds local flag in generated_inspector_files
No-Try: true
Change-Id: If4d72836d40ee994ea5b7f7f1f2a98092d7b4079
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3380599
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78562}
2022-01-11 12:27:46 +00:00
Piotr Sikora
685e6078ff [bazel] Use v8_enable_handle_zapping only in debug builds.
This leads to a noticable performance improvements, and this flag
is flipped to "is_debug" by the V8 Autoroller in release branches
for the GN builds, so this change matches that behavior.

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: I0a6d9798617939f822a6ce347ed2005b1597627a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3380246
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78561}
2022-01-11 11:32:39 +00:00
Thibaud Michaud
5c829be17c [wasm] Add Suspender.suspendOnReturnedPromise
- Add Suspender.suspendOnReturnedPromise method
- Extend the WasmApiFunctionRef data with the suspender
- Detect wrapped WasmJSFunctions when we resolve the import

For now the generated wrapper is still a regular wasm-to-js wrapper, but
this sets the ground for generating specific wrappers for functions
wrapped by suspendOnReturnedPromise, and to access the suspender from
the wrapper code.

R=ahaas@chromium.org
CC=​fgm@chromium.org

Bug: v8:12191
Change-Id: I81cbec6b023507e47e6e1463b5f9b912f807da6a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3345000
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Dominik Inführ <dinfuehr@chromium.org>
Commit-Queue: Thibaud Michaud <thibaudm@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78560}
2022-01-11 11:31:36 +00:00
Piotr Sikora
d82b4b6699 [bazel] Cleanup style with Buildifier.
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: I5b924b02b56c66c186518cbfa372a82b960f1242
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3379226
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78559}
2022-01-11 10:00:36 +00:00
Aleksei Koziatinskii
39f55fc7ba cppgc: added missing virtual BaseSpace destructor
BaseSpace classes. So BaseSpace should have a virtual destructor
for memory to be freed properly.

cppgc: :internal::RawHeap maintains a std::vector of
std: :unique_ptr<BaseSpace> and stores there different derived from
Change-Id: Id9f59817799303bf62aafb66b3a29770bbd2af1f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3379228
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Alexey Kozyatinskiy <kozyatinskiy@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78558}
2022-01-11 08:18:53 +00:00
Benedikt Meurer
21b1391dbe [owners] Same owners for src/heap/*factory* and src/objects.
The methods in the v8::internal::Factory deal with creating the objects
described in src/objects, so there's no point in having different sets
of owners for them.

Bug: none
Change-Id: I05b48535bd81d37796e3f741156a059be8554759
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3359634
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Auto-Submit: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78557}
2022-01-11 06:09:33 +00:00
v8-ci-autoroll-builder
e6aada80d4 Update google_benchmark
Rolling v8/third_party/google_benchmark/src: 3b3de69..0d98dba

Creating release commit for v1.6.1 (Dominic Hamon)
https://chromium.googlesource.com/external/github.com/google/benchmark/+/0d98dba

Destructor not returning is expected in some cases (#1316) (staffantj)
https://chromium.googlesource.com/external/github.com/google/benchmark/+/0e78738

Address c4267 warning on MSVC (#1315) (staffantj)
https://chromium.googlesource.com/external/github.com/google/benchmark/+/6dfe7af

R=v8-waterfall-sheriff@grotations.appspotmail.com,mtv-sf-v8-sheriff@grotations.appspotmail.com,mlippautz@chromium.org

Change-Id: I484073c46b839f7ba8d8c8abac6e6c28da79b1ac
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3379826
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#78556}
2022-01-11 05:40:33 +00:00
Frank Tang
470bebc2b9 [Temporal] Implement Temporal.*.prototype.valueOf
Bug: v8:11544
Change-Id: If0a6eeb6591538a969efaac9d148d019300b4113
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3374067
Reviewed-by: Shu-yu Guo <syg@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78555}
2022-01-11 05:37:44 +00:00
v8-ci-autoroll-builder
55daf4cd56 Update V8 DEPS.
Rolling v8/build: 12badc1..3803b80

Rolling v8/buildtools/linux64: git_revision:f1b1412521b41e47118b29863224171e434a27a2..git_revision:80a40b07305373617eba2d5878d353532af77da3

Rolling v8/buildtools/third_party/libunwind/trunk: 58d1647..14da6e7

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/aa0e8d0..dc12138

Rolling v8/third_party/depot_tools: d3cc7ad..0f5a4de

Rolling v8/tools/clang: 6e330f7..f5a2da5

R=v8-waterfall-sheriff@grotations.appspotmail.com,mtv-sf-v8-sheriff@grotations.appspotmail.com

Change-Id: Ie20d091b4fd5b69d68a9b6f0e69ea3403abbce0e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3379824
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#78554}
2022-01-11 03:53:04 +00:00
Lu Yahan
87483842cb [riscv64] Implement simd128 in swap
enable simd on riscv64

Change-Id: I446d6b14e4f89164b49a66367340d904ba104911
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3347493
Reviewed-by: ji qiu <qiuji@iscas.ac.cn>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Yahan Lu <yahan@iscas.ac.cn>
Cr-Commit-Position: refs/heads/main@{#78553}
2022-01-11 03:40:16 +00:00
Piotr Sikora
d1f04238f5 [bazel] Use //external: bindings for dependencies.
This simplifies integration with Bazel workspaces that already
have those libraries imported under different repository names.

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: Iee6dee1abb8fca10f6b998b2ec9f459c14376bc1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3333633
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78552}
2022-01-10 21:18:54 +00:00
Piotr Sikora
f2724654a5 [bazel] Split zlib into core and compression utils.
This allows other Bazel projects to use their existing zlib import,
and only pull compression utils from Chromium's zlib.

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: I1f88632dd07661312aa2aaf8716c1742c1f29c53
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375479
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78551}
2022-01-10 20:39:04 +00:00
Piotr Sikora
12bb012592 [bazel] Don't use source files from external dependencies.
This allows other Bazel projects to fetch those dependencies
without relying on a full "gclient" checkout.

Added "com_googlesource_chromium" prefix to repository names to
indicate that those are Chromium forks and not official releases.

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: I87272c3e8c28d14d8974cea144e457713c59d994
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375478
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78550}
2022-01-10 20:08:45 +00:00
Corentin Pescheloche
747cdba92b Shift EmbedderState values next to each other
For consistency with the other enums values, avoid gaps between
EmbedderState values.

Bug: chromium:1263871
Change-Id: I22c58700f292b007ced7c12db219f578f82d77d1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3370081
Auto-Submit: Corentin Pescheloche <cpescheloche@fb.com>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78549}
2022-01-10 17:43:47 +00:00
Adenilson Cavalcanti
4dd8d9a926 [pac] Allow PAC-only build of C++ code
The enablement of PAC in Chromium will have two phases where support
will first be enabled on C++ code (e.g. Blink/Chrome/etc) and its
dependencies, followed next by support for dynamic code generated by
V8.

This change will allow enable PAC support for C++ code when V8
is built with Chromium.

Bug: chromium:919548
Change-Id: I8ebcbcfe3c2a3a38807b814f936272ac09625795
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3372162
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Adenilson Cavalcanti <cavalcantii@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78548}
2022-01-10 17:42:45 +00:00
Alexander Timin
da4467b64a [tracing] Add missing v8.inspector category declaration
Add the new disabled-by-default-v8.inspector category (added by  [1]) to the category list to ensure that v8 can be built with perfetto client library (example failure [2]).

[1] https://chromium-review.googlesource.com/c/v8/v8/+/3364085  
[2] https://ci.chromium.org/ui/p/chromium/builders/try/linux-perfetto-rel/5926/overview

Change-Id: I7b187a18d2f996148fbfd42f9039f9a2012537bf
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3370121
Auto-Submit: Alexander Timin <altimin@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78547}
2022-01-10 17:41:42 +00:00
Clemens Backes
8d8a021c8d Revert "[wasm] Lazy compilation after deserialization"
This reverts commit fbcdb28178.

Reason for revert: New test fails for multiple (concurrent) isolates: https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux/45152/overview

Original change's description:
> [wasm] Lazy compilation after deserialization
>
> The serialization format contains one boolean flag per function which
> specifies whether the function code exists in the serialized module or
> not. With this CL, this boolean flag is extended to a three-value flag
> which indicates whether the function exists, and if not, whether the
> function was executed before serialization. This information can then be
> used upon deserialization to compile only those functions that were
> executed before serialization.
>
> Design doc: https://docs.google.com/document/d/1U3uqq4njqLqFhr1G2sU_bmpQxY-3bvfG55udSb-DvA4/edit?usp=sharing
>
> Bug: v8:12281
> Change-Id: I465e31e5422fa45163256be0e6594045865f0174
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3364089
> Reviewed-by: Clemens Backes <clemensb@chromium.org>
> Commit-Queue: Andreas Haas <ahaas@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#78545}

Bug: v8:12281
Change-Id: If0e327d02e8257a4d1cfcf8b82381af11f28e91c
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3377126
Auto-Submit: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#78546}
2022-01-10 17:37:03 +00:00
Andreas Haas
fbcdb28178 [wasm] Lazy compilation after deserialization
The serialization format contains one boolean flag per function which
specifies whether the function code exists in the serialized module or
not. With this CL, this boolean flag is extended to a three-value flag
which indicates whether the function exists, and if not, whether the
function was executed before serialization. This information can then be
used upon deserialization to compile only those functions that were
executed before serialization.

Design doc: https://docs.google.com/document/d/1U3uqq4njqLqFhr1G2sU_bmpQxY-3bvfG55udSb-DvA4/edit?usp=sharing

Bug: v8:12281
Change-Id: I465e31e5422fa45163256be0e6594045865f0174
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3364089
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78545}
2022-01-10 16:35:48 +00:00
Milad Fa
b480971834 PPC/AIX [simd]: Implement vector load and splat
This CL takes advantage of the P9 `vector byte-reverse`
instruction to implement Simd LoadSplat opcodes.

We will need to implement the rest of the `load transform` ops
before enabling this from wasm-compiler on BE machines.

Change-Id: I094e37d3b15e0dc04484eb2a701cb479f18e2f9e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3371790
Reviewed-by: Junliang Yan <junyan@redhat.com>
Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
Cr-Commit-Position: refs/heads/main@{#78544}
2022-01-10 15:46:58 +00:00
Al Muthanna Athamina
625392095a Doubling number of shards for 'test262 extra' on 'V8 Linux64'
Bug: v8:12538
Change-Id: I4f1d4bc33846c158044da76b882d54469ff031a4
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3377124
Commit-Queue: Almothana Athamneh <almuthanna@chromium.org>
Auto-Submit: Almothana Athamneh <almuthanna@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78543}
2022-01-10 15:29:28 +00:00
Benedikt Meurer
765ca6a0d3 [inspector] Capture stack trace only once for JSError objects.
When creating a new JSError object (or using the non-standard API
`Error.captureStackTrace`) V8 would previously capture the "simple stack
trace" (as FixedArray of CallSiteInfo instances) to be used for the non-
standard `error.stack` property, and if the inspector was active also
capture the "detailed stack trace" (as FixedArray of StackFrameInfo
instances). This turns out to be quite a lot of overhead, both in terms
of execution time as well as memory pressure, especially since the
information needed for the inspector is a proper subset of the
information needed by `error.stack`.

So this CL addresses the above issue by capturing only the "simple stack
trace" (in the common case) and computing the "detailed stack trace"
from the "simple stack trace" when on demand. This is accomplished by
introducing a new ErrorStackData container that is used to store the
stack trace information on JSErrors when the inspector is active. When
capturing stack trace for a JSError object while the inspector is
active, we take the maximum of the program controlled stack trace limit
and the inspector requested stack trace limit, and memorize the program
controlled stack trace limit for later formatting (to ensure that the
presence of the inspector is not observable by the program).

On the `standalone.js` benchmark from crbug.com/1283162 (with the
default max call stack size of 200) we reduce execution time by around
16% compared to ToT. And compared to V8 9.9.4 (the version prior to the
regression in crbug.com/1280831), we are 6% faster now.

Doc: https://bit.ly/v8-cheaper-inspector-stack-traces
Bug: chromium:1280831, chromium:1278650, chromium:1258599
Bug: chromium:1280803, chromium:1280832, chromium:1280818
Fixed: chromium:1283162
Change-Id: I57dac73e0ecf7d50ea57c3eb4981067deb28133e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3366660
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78542}
2022-01-10 14:55:18 +00:00
XiangYang
506c0cf24f [snapshot] The length of the snapshot version string is 64 bytes
Modify the wrong code annotation.

Change-Id: Ied592d7066f394581ba36480eb91221f1ba53bbc
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3359104
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78541}
2022-01-10 14:46:58 +00:00
Romain Pokrzywka
d6f8af0169 [heap] Fix NewArrayList tripping DCHECK with LocalFactory
LocalFactory::AllocateRaw() only allows the kOld and kSharedOld
allocation types, but NewArrayList() calls NewFixedArray() without
an explicit allocation argument, which then defaults to kYoung.

Add an allocation argument to NewArrayList() with the same default
value as for NewFixedArray() and pass kOld when calling it from
NewScriptWithId() to avoid tripping the DCHECK with LocalFactory.

Follow-up to https://crrev.com/c/3211575

Bug: chromium:1244145
Change-Id: I88d394bda250c45bf49141b78c09f6ca4a61dbe3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3354087
Reviewed-by: Dominik Inführ <dinfuehr@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78540}
2022-01-10 14:44:08 +00:00
Benedikt Meurer
2cc1b98167 [owners] Same owners for src/init/heap-symbols.h and src/objects.
The special symbols defined in heap-symbols.h were extracted out of
src/heap/heap.{cc,h} a long time ago because they logically belong to
the objects and not to the implementation of the GC/heap, so they should
have the same ownership as the objects that use them in src/objects.

Bug: none
Change-Id: I9a87c1600dc26b0fc5e620a13d409fb9116235e2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375546
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78539}
2022-01-10 14:42:28 +00:00
Shu-yu Guo
fb855334e5 [heap] Fix --trace-gc-object-stats stats in debug builds
Bug: v8:11708
Change-Id: Ibf0f91b9e63646f226a2e70ec4a1733820e968ae
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3373135
Auto-Submit: Shu-yu Guo <syg@chromium.org>
Reviewed-by: Dominik Inführ <dinfuehr@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78538}
2022-01-10 14:07:21 +00:00
Piotr Sikora
db77f7fb4a [bazel] Generate inspector files using @rules_python.
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: I776b98676df0094c141a395cfbe10801153e1076
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3343881
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78537}
2022-01-10 13:32:28 +00:00
Liviu Rau
de09719410 Doubling number of shards for 'test262 extra' on 'V8 Linux'
Bug: v8:12538
Change-Id: I57496ee0f50df92000c445c07acc8d6ee763d4e8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3377123
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Liviu Rau <liviurau@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78536}
2022-01-10 13:27:29 +00:00
Piotr Sikora
8622563f32 [bazel] Fix zlib build on arm64.
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: Ibc7b458e9ee7b632294aba2750716cbbd72923b1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3377103
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78535}
2022-01-10 12:35:30 +00:00
Piotr Sikora
eeb0c00471 [bazel] Add support for building on ppc64le.
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: I23135214a6cf78122b35ed7d43c7fa22a8ece34e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375471
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78534}
2022-01-10 12:09:18 +00:00
Piotr Sikora
4938c58754 [bazel] Add support for building on riscv64.
Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: I880b06d9b4fe37d242869ab4f18c15c28b48fb8a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375470
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78533}
2022-01-10 11:20:28 +00:00
Clemens Backes
2a7f160233 [compiler] Fix SIMD register overlap check
We should only check the "SIMD sibling" register if we are handling a
SIMD register. This avoids unneeded spills, and in this particular case
ran into a DCHECK because there are only 29 registers, but we tried
checking #29.

R=thibaudm@chromium.org

Bug: v8:12330, v8:1285007
Change-Id: Ife8b295ac958990611ca8816bbfbfb5124a4297d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3372916
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78532}
2022-01-10 10:41:30 +00:00
Piotr Sikora
b4870d2822 [bazel] Add support for building on s390x.
Tested with both GCC and Clang on s390x (under QEMU).

Signed-off-by: Piotr Sikora <piotrsikora@google.com>
Change-Id: Iad6609136e25a6e94d51f365e4c54e6f042aa897
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3346395
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78531}
2022-01-10 10:40:28 +00:00
Al Muthanna Athamina
e4bf033142 Doubling number of shards for test262 novfp3 on arm sim debug
Bug: v8:12538
Change-Id: I89e7fcde7226d680f3385f527cb2e456829a476d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3376962
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Almothana Athamneh <almuthanna@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78530}
2022-01-10 10:22:39 +00:00
Manos Koukoutos
05f6d3f9f8 Reland "[wasm] Fast paths in EvaluateInitExpression"
This is a reland of be6bd4f448.
The reason for revert was two bots timing out. On further inspection,
the timeouts seem unrelated.

Original change's description:
> [wasm] Fast paths in EvaluateInitExpression
>
> We add fast paths for the most common types of expressions in
> {EvaluateInitExpression} to improve instantiation time. We fall back to
> full expression decoding for less common operators, or for expressions
> with operands.
>
> Bug: chromium:1284557
> Change-Id: I39a1816176974058b801cdad6eaaa6da156cea04
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3367627
> Reviewed-by: Clemens Backes <clemensb@chromium.org>
> Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#78497}

Bug: chromium:1284557
Change-Id: I209458c1fa36ae41899434b90759ebe3fe5e2a57
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375545
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78529}
2022-01-10 10:19:01 +00:00
Clemens Backes
33273f099e [testrunner] Add missing comma
Without the comma, the two strings '--no-enable-sse3' and
'--noenable-ssse3' will be concatenated, resulting in missing detection
for the no_simd_hardware flag.

R=liviurau@chromium.org

Bug: v8:12521
Change-Id: Icbdc5e8057d1eeead472f76efd52c379bffbe5b6
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3372914
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78528}
2022-01-10 10:06:52 +00:00
Al Muthanna Athamina
6a4d6d98a7 Enable javascript promise hooks on pointer compression
Bug: v8:12483
Change-Id: Ic488540c3d4905813a705b0fb6d742d267c994c9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3366239
Auto-Submit: Almothana Athamneh <almuthanna@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78527}
2022-01-10 10:05:50 +00:00
Leszek Swirski
04e57ea614 [test] kraken/audio-beat-detection is slow in jitless
Bug: v8:12529
Change-Id: I73c8176cf0b3570f1424b85038467d5b965d3d04
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3375548
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78526}
2022-01-10 09:31:38 +00:00
v8-ci-autoroll-builder
5b2db71282 Update V8 DEPS.
Rolling v8/build: 66cd756..12badc1

R=v8-waterfall-sheriff@grotations.appspotmail.com,mtv-sf-v8-sheriff@grotations.appspotmail.com

Change-Id: I11dd012d8a4c8775f6ddeac2190df8ce496da986
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3376582
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#78525}
2022-01-10 03:56:18 +00:00
Yujie Wang
8861ca7b74 [riscv64] Add RISCV64 support for wasm-relaxed-simd
- Implement `kRiscvF32x4RecipApprox`, `kRiscvF32x4RecipSqrtApprox`,
  `kRiscvF32x4Qfma`, `kRiscvF32x4Qfms`, `kRiscvF64x2Qfma` and `kRiscvF64x2Qfms`
  in `code-generator-riscv64.cc`

- Reuse lane-select, min-max and trunc instrctions in
  `instruction-selector-riscv64.cc`

Bug: v8:11976
Change-Id: I8566f7e082a3d7071ec9fc64c742da82425a4d4d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3364077
Reviewed-by: Yahan Lu <yahan@iscas.ac.cn>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78524}
2022-01-10 01:40:22 +00:00
v8-ci-autoroll-builder
c0cec07e54 Update V8 DEPS.
Rolling v8/build: 208eb9e..66cd756

Rolling v8/buildtools/third_party/libc++abi/trunk: c884e7a..a0ace99

Rolling v8/buildtools/third_party/libunwind/trunk: 4bf418e..58d1647

R=v8-waterfall-sheriff@grotations.appspotmail.com,mtv-sf-v8-sheriff@grotations.appspotmail.com

Change-Id: Ifc8c5d9708af08c0765e8f3567cfb64aab267d7f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3371679
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#78523}
2022-01-09 04:01:27 +00:00
v8-ci-autoroll-builder
bc317c76dd Update V8 DEPS.
Rolling v8/build: 3fd1fd5..208eb9e

Rolling v8/buildtools/linux64: git_revision:387b368dfe63fec317f8e609d90c634807f2764e..git_revision:f1b1412521b41e47118b29863224171e434a27a2

Rolling v8/third_party/android_platform: abc362f..5023a5c

Rolling v8/third_party/depot_tools: 9552069..d3cc7ad

Rolling v8/tools/clang: 17ca796..6e330f7

R=v8-waterfall-sheriff@grotations.appspotmail.com,mtv-sf-v8-sheriff@grotations.appspotmail.com

Change-Id: Id6780cf6c36e72f0ded9dc918b470ebe4b65755d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3373548
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Bot-Commit: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#78522}
2022-01-08 03:57:06 +00:00
Clemens Backes
9af895db5d [compiler] Remove more unneeded accessors
Inlining the field accesses make the code simpler by avoiding the
abstraction of the accessor, and makes stepping through the code for
debugging easier.

R=thibaudm@chromium.org

Bug: v8:12330
Change-Id: I51bd0e88baa5ffba5bd4bfcca36e95caab7468c3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3372913
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78521}
2022-01-07 21:30:35 +00:00