Commit Graph

75153 Commits

Author SHA1 Message Date
v8-ci-autoroll-builder
cbc0e0a1d4 Update google_benchmark
Rolling v8/third_party/google_benchmark/src: 8d86026..bc4639c

Add installation and build instructions for Python bindings (#1392) (Nicholas Junge)
https://chromium.googlesource.com/external/github.com/google/benchmark/+/bc4639c

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

Change-Id: I1ab826ee75b642f04c753dd43e5fe01e9821cc2d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3640524
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@{#80461}
2022-05-11 06:04:22 +00:00
v8-ci-autoroll-builder
890e920576 Update V8 DEPS.
Rolling v8/build: 256e629..1c34f36

Rolling v8/buildtools/third_party/libc++abi/trunk: ac1834f..ecff200

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/406c287..d1ddc12

Rolling v8/third_party/depot_tools: 1bc3cd2..31bfd51

Rolling v8/third_party/fuchsia-sdk/sdk: version:8.20220509.2.1..version:8.20220510.2.1

Rolling v8/tools/clang: cd2b9e3..9da9510

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

Change-Id: Ide529df4fdc042606e784122148ad1593893b8f0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3640523
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@{#80460}
2022-05-11 03:55:14 +00:00
Michael Lippautz
cd04f804ae [handles] Fix benign data race
Upon destroying a v8::TracedReference while concurrent marking is
running, we merely reset the object pointer but do not get rid of the
global handle.

We were also restting the parameter which would read the internal
state for a DCHECK. Remove this clearing as the parameter field is not
used for v8::TracedReference.

Bug: chromium:1324074
Change-Id: Ic21bad78deba0925e12c3fc1215b087d0ef5dd7a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3637796
Reviewed-by: Dominik Inführ <dinfuehr@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Auto-Submit: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80459}
2022-05-10 19:02:25 +00:00
Peter Kasting
02261c4b77 Types on both sides of comparison operators should be the same.
This prevents "ambiguous call" warnings when compiling in C++20 mode.

Bug: chromium:1284275
Change-Id: I52f782aaddfad1920e4b2df5e916b2c292cc7cff
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3630346
Auto-Submit: Peter Kasting <pkasting@chromium.org>
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Commit-Queue: Peter Kasting <pkasting@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80458}
2022-05-10 18:48:22 +00:00
Tobias Tebbi
8656d93718 [compiler] remove UnsafePointerAdd operator
UnsafePointerAdd is unnecessary as long as a proper bitcast is used
before the addition. The bitcast is already in the effect chain and
prevents the addition from floating before a GC operation.

Change-Id: Ieadb8a51d2d24eaa1132a62c77c674954f7e2644
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3616727
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80457}
2022-05-10 18:14:35 +00:00
Michael Lippautz
09f39ae00d Inspector protocol: Add optional parameter to expose internals
Deprecate the existing parameter to treat global objects as roots as
this is implied by exposing internals.

Bug: chromium:1321620
Change-Id: I73a8124d63f87599dee7080980844c418eb3b5e4
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3637797
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Simon Zünd <szuend@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80456}
2022-05-10 16:43:25 +00:00
Shu-yu Guo
fa86b6d36e [private brand checks] Remove --harmony-private-brand-checks
Private brand checks have shipped since M91.

Bug: v8:11374
Change-Id: Ifd2f8e9904cdb25b45b2e4019da13b3cfc9efdc5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3622266
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Auto-Submit: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80455}
2022-05-10 16:28:55 +00:00
Peter Kasting
34499e98fd Fix atomic initialization to work with C++20.
Bug: chromium:1284275
Change-Id: I727950c0bed499050ff550e90b9da07404057abe
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3630348
Auto-Submit: Peter Kasting <pkasting@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80454}
2022-05-10 15:43:25 +00:00
Clemens Backes
e57f4bb3fc [API] Deprecate OOMErrorCallback
Deprecate the OOMErrorCallback such that we can add a new parameter for
OOM details.

R=mlippautz@chromium.org

Bug: chromium:1323177
Change-Id: I72c931ad0d1b75cda46e8815387098acbe091c68
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3632106
Reviewed-by: Lutz Vahl <vahl@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80453}
2022-05-10 15:36:15 +00:00
Nico Hartmann
338c12b3af [turbofan] Fix length accessor for RAB/GSAB in compiled code
Bug: v8:11111, chromium:1307340
Change-Id: I7c68d4985c080bf5c595a4ae3360fc924b1bdefb
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3627595
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80452}
2022-05-10 15:34:25 +00:00
Camillo Bruni
d3ccf6bc89 [tools] Use python3 by default for gm.py
Change-Id: I16a090fc9af5447c5d36e7bbd4bece1537724678
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3637792
Auto-Submit: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80451}
2022-05-10 13:32:25 +00:00
Igor Sheludko
411a015758 Reland "[rwx][mac] Enable fast W^X on Apple Silicon (M1)"
This is a reland of commit e8cac3776e
Broken jitless mode is fixed in a separate CL.

Original change's description:
> [rwx][mac] Enable fast W^X on Apple Silicon (M1)
>
> Bug: v8:12797
> Change-Id: I53bb803dd77db5bdd42b1a1b4b568e63857adf31
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3598861
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Igor Sheludko <ishell@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#80396}

Bug: v8:12797
Change-Id: I5436ceced5d4673f3b80d9cacdb3d6e84012c6e7
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3635720
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80450}
2022-05-10 12:53:25 +00:00
jameslahm
abe1b97dd2 [web snapshot] Add support for sparse array
This CL adds the array type flag to distinguish between
sparse array and dense array and adds serialization
and deserialization for sparse array.

Bug: v8:11525
Change-Id: Ia302af017d6f52924256a2b3fa9e3d2b34caa442
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3629739
Commit-Queue: 王澳 <wangao.james@bytedance.com>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80449}
2022-05-10 12:40:58 +00:00
Igor Sheludko
1c94e7a94c [rwx][mac] Add missing CodePageHeaderModificationScopes
Bug: v8:12797
Change-Id: I93c786ac4b4a9b44d17f20e8d79544c4718d8fe6
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3637790
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Auto-Submit: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80448}
2022-05-10 11:57:55 +00:00
Dominik Inführ
d5245542c9 [heap] Remove unused sweeping for iterability mechanism
Since we now promote all young objects into old space on full GCs, we
don't need to sweep pages for iterability anymore in new space.

Minor MC doesn't need to make a page iterable when promoting the full
page into the new space. This is because maps are not reclaimed during
a minor GC.

Bug: v8:12760
Change-Id: I16d666e417d00ebf450453864cbd87afd6606afc
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3635723
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80447}
2022-05-10 11:45:16 +00:00
Camillo Bruni
7e233997b0 [serializer] Disable gc-stats during deserialisation
Objects might be in a partially initialized state during deserialization
which makes collecting gc-stats tricky.

Bug: v8:12678
Change-Id: I154328adda432bf8e3588c96455c1bd8d527ef43
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3635722
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80446}
2022-05-10 11:37:45 +00:00
Marja Hölttä
395350c064 [web snap] Fix: allow empty objects to have non-trivial prototypes
Bug: v8:11525
Change-Id: I226ba870cee7df20a7960defb0c03607d64e27b0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634962
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80445}
2022-05-10 10:29:16 +00:00
Patrick Thier
b086aa700c [csa] Load hash in TryToName with Acquire semantics
Add support to atomically load (untagged) values from objects to CSA.

Bug: v8:12007
Change-Id: If0c4f20f20e021ace3b1e3a874c0405574d313e1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3627513
Commit-Queue: Patrick Thier <pthier@chromium.org>
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80444}
2022-05-10 10:08:25 +00:00
Simon Zünd
30a8616ab9 [unwinder] Support 'restart frame' in the unwinder
Doc: https://bit.ly/revive-restart-frame

This CL implements support for the Debugger's "restart frame"
functionality in the unwinder. When the debugger wants to restart
a frame, we throw a termination exception. The unwinder checks if we
are currently in "restart frame mode", and if so, drops execution
into a special builtin instead of trying to find a catch handler.

Optimized frames are handled similarly, but the deoptimizer has to
materialize the frames first before also dropping into the
special builtin.

Drive-by: Rename `ShouldRestartFrame` to `IsRestartFrameScheduled`, so
we can reuse the name `ShouldRestartFrame` as a query method to check
if a specific frame is the frame we want to restart.

R=jarin@chromium.org, tebbi@chromium.org

Bug: chromium:1303521
Change-Id: Iff4f5761f970b65e22485f78ee0fd85da620ce66
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3613397
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Simon Zünd <szuend@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80443}
2022-05-10 09:40:05 +00:00
Igor Sheludko
7beb93cdff [rwx][mac] Fix jitless mode
In some cases we were still trying to change permissions of RWX pages
which is not allowed.

Bug: v8:12797
Change-Id: I9f4ca319d842c524fc6f60bfd3bb3726f8d3029d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3635719
Auto-Submit: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80442}
2022-05-10 09:00:23 +00:00
Samuel Groß
9a6a76bf13 Reland "Reland "[sandbox] Enable sandboxed pointers on Desktop""
This is a reland of commit 31d7838094

Issues related to GWP-ASan were fixed in https://crrev.com/c/3632490

Original change's description:
> Reland "[sandbox] Enable sandboxed pointers on Desktop"
>
> This is a reland of commit 48481a671a
>
> Original change's description:
> > [sandbox] Enable sandboxed pointers on Desktop
> >
> > Bug: chromium:1218005
> > Change-Id: I3df750ee9101779952d8b1ae630c4d3b7563084b
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3578645
> > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> > Commit-Queue: Samuel Groß <saelo@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#80376}
>
> Bug: chromium:1218005
> Change-Id: Iaf7bc81393da5c1381a361a9de129affaa019670
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3629348
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Samuel Groß <saelo@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#80394}

Bug: chromium:1218005
Change-Id: I98422c2577539e7025f3d6047855a63452ce3786
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3632306
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Samuel Groß <saelo@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80441}
2022-05-10 08:18:26 +00:00
Michael Achenbach
7e9715d8a9 Revert "[maglev] Turn on fuzzing for --maglev"
This reverts commit b8b7a3a2f9.

Reason for revert:
https://crbug.com/1324097
https://crbug.com/v8/12859

Let's maybe only reland the clusterfuzz_trials part until the rest
is sorted out.

Original change's description:
> [maglev] Turn on fuzzing for --maglev
>
> Turn on fuzzing for Maglev to get additional test coverage.
>
> Bug: v8:7700
> Change-Id: I5b72d851639e31dff1bd91361cd81ad448c2d69e
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3629334
> Auto-Submit: Jakob Linke <jgruber@chromium.org>
> Commit-Queue: Michael Achenbach <machenbach@chromium.org>
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Reviewed-by: Michael Achenbach <machenbach@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#80416}

Bug: v8:7700, chromium:1324097, v8:12859
Change-Id: I926319988c3b9a2bc6dd083c69691a6536838782
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634963
Auto-Submit: Michael Achenbach <machenbach@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@{#80440}
2022-05-10 08:01:14 +00:00
Camillo Bruni
57e0fa2efb [log] Increase CodeEventListener::NameBuffer size
URLs can be fairly long and the original 512 char limit is not enough
for many google pages.

Change-Id: Id4f81214e3fedebc80f26c49034c0997397e10fb
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634779
Reviewed-by: Marja Hölttä <marja@chromium.org>
Auto-Submit: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80439}
2022-05-10 07:41:45 +00:00
Dominik Inführ
234c904d97 [heap] Do not zap freed memory in NotifyObjectSizeChange
Avoid zapping freed memory in NotifyObjectSizeChange. This fixes the
linked performance regression introduced with
https://crrrev.com/c/3607992. Beginning with that CL we would always
zap freed memory on the main thread, while previously we only did this
in CreateFillerForArray when the FixedArray could actually contain
references.

While we could restore the previous behaviour as well, we simply stop
zapping freed memory in NotifyObjectSizeChange altogether for better
throughput. The reason for zapping was to reduce floating garbage.
However this is only relevant for incremental marking which is only
enabled for about <1% of the overall runtime.

Bug: v8:12578, chromium:1322882
Change-Id: I004ee712b924c53edac87810504d04aa7f4a50d8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634960
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80438}
2022-05-10 07:32:10 +00:00
Manos Koukoutos
eac584cda3 [wasm][refactor] Move WasmGraphAssembler to separate file
This way we can use it later in the pipeline for optimizations.

Change-Id: I0e97d061fd3d474ca7033ed2b68f43b52617d3e8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634961
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80437}
2022-05-10 07:22:25 +00:00
v8-ci-autoroll-builder
253d03dcb3 Update ICU
Rolling v8/third_party/icu: 85814e1..585942f

Cherry-pick PR2084 fix C++20 enum issues (Frank Tang)
https://chromium.googlesource.com/chromium/deps/icu/+/585942f

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

Change-Id: I390adb38bca23243559916323c966b90b1995b29
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634549
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@{#80436}
2022-05-10 05:56:25 +00:00
Frank Tang
1f09e46859 [Temporal] Change Parser from Maybe to Optional
Bug: v8:11544
Change-Id: I16b1fb2cb4f6f4104b2f972a06b8fe0798ac6835
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3632675
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Adam Klein <adamk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80435}
2022-05-10 05:31:24 +00:00
v8-ci-autoroll-builder
1a5c64da32 Update V8 DEPS.
Rolling v8/build: 9c02936..256e629

Rolling v8/buildtools/linux64: git_revision:53ef169800760fdc09f0773bf380fe99eaeab339..git_revision:bf4e17dc67b2a2007475415e3f9e1d1cf32f6e35

Rolling v8/buildtools/third_party/libc++abi/trunk: fb82ddb..ac1834f

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/0f76f22..406c287

Rolling v8/third_party/depot_tools: 6a1494e..1bc3cd2

Rolling v8/third_party/fuchsia-sdk/sdk: version:8.20220508.2.1..version:8.20220509.2.1

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

Change-Id: Ifc4c0c973afd69f66ae1a96e6e20f7d0e7a8c97b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634547
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@{#80434}
2022-05-10 03:52:17 +00:00
Frank Tang
988aa5139f [Temporal] Sync w/ PR2028
Sync to spec changes in
PR2028 Consistently call observable operations with undefined options
https://github.com/tc39/proposal-temporal/pull/2028

Bug: v8:11544
Change-Id: I850761e76ba1bb33f6c3b655a71163d1b68bb4c8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3633618
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80433}
2022-05-09 23:09:34 +00:00
Deepti Gandluri
e6b50eb017 [wasm-simd] Update new relaxed SIMD opcodes
Add new opcode numbers for relaxed-simd opcodes as in:
https://github.com/WebAssembly/relaxed-simd/pull/61, and updates
for decoded opcodes larger than two bytes.

Bug: v8:12284
Change-Id: I0bff22812243a39599bfeee3c0bc69171dd3c7d2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3625835
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80432}
2022-05-09 22:47:24 +00:00
Milad Fa
0e05d1b7e3 PPC/s390: [osr] Extend OSR tracing
Port 3e43010abb

Original Commit Message:

    New trace events:

    - finished OSR compilation.
    - entry into OSR code.

    Since the latter now happens without a trip into runtime, tracing is a
    bit more involved - we need to check FLAG_trace_osr in generated code,
    and call a runtime function if it is set.

R=jgruber@chromium.org, joransiu@ca.ibm.com, junyan@redhat.com, midawson@redhat.com
BUG=
LOG=N

Change-Id: I2f09eb755dd5986d94f736280ad38574129085e2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3635717
Reviewed-by: Junliang Yan <junyan@redhat.com>
Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
Cr-Commit-Position: refs/heads/main@{#80431}
2022-05-09 20:14:44 +00:00
Marja Hölttä
ce488c0156 Reland: [web snapshot] Recognize builtins
Builtins are not snapshotted, but instead we insert "builtin wrappers"
into the snapshot, and create references to the corresponding builtin
when deserializing.

Subclassing builtins will be implemented in a follow-up CL.

First version: https://chromium-review.googlesource.com/c/v8/v8/+/3630080
Fix: initialize builtin_objects_handle_

Bug: v8:11525,v8:12820
Change-Id: Ia2b5d41af5d7f577f1b02356b22a8760963009e4
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3635718
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80430}
2022-05-09 16:41:25 +00:00
henrika
fee2336535 [api] Adds script column number to code-creation events in CodeEventLogger
Bug: v8:11043
Change-Id: I8cbdd8a5f68bdadbe7fc44414c6d46cdd57e6802
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3627512
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Henrik Andreasson <henrika@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80429}
2022-05-09 14:29:24 +00:00
Peter Kasting
190fda57ee Remove "volatile" on arguments where deprecated in C++20.
Many uses of "volatile" are deprecated in C++20 because they don't
actually do anything.  Remove "volatile" in these cases.

Bug: chromium:1284275
Change-Id: I64a3989d73f25e0cd933375dd6fa0b3f2b3acb54
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3630343
Auto-Submit: Peter Kasting <pkasting@chromium.org>
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80428}
2022-05-09 14:15:44 +00:00
Camillo Bruni
d60d36a89f [log] Use v8_file_logger variable names more consistently
In preparation of renaming i::CodeEventDispatcher to i::Logger

Bug: v8:12795, chromium:1316443
Change-Id: I28e129130852d41cf5e464e083bc27cff97a0fff
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3623543
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80427}
2022-05-09 13:58:24 +00:00
Camillo Bruni
46ca99766c [tools] Fix run_perf.py --filter=<regexp>
In the previous refactoring --filter was accidentally filtering out
paths that matched <regexp>. This CL restores the original behavior
where only the matching paths are kept.

Bug: v8:12821, v8:11113
Change-Id: I7e7d7b793107fbf9b4944b1674874150803f4bb4
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3623539
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80426}
2022-05-09 13:34:50 +00:00
Clemens Backes
cba1501d70 [wasm] Reduce code space estimates on 32-bit
Multiple code spaces are cheaper on 32-bit systems, because we can
directly call between them. Over-reservation on the other hand increases
the chance for OOMs. Hence reduce the code space estimation (used for
the initial reservation) on 32-bit systems.

Numbers were obtained from an older Epic module, Photoshop, and AutoCAD.
I'll keep an eye on the {V8.WasmModuleNumberOfCodeSpaces} counter.

R=ahaas@chromium.org

Change-Id: Ide804eaf46e8ba9bb48fcb41f23f1facc910645e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634778
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80425}
2022-05-09 12:57:34 +00:00
Clemens Backes
44c7484742 [API] Add LegacyOOMErrorCallback
This adds a typedef for LegacyOOMErrorCallback, which is identical to
OOMErrorCallback. Embedders will need to switch to
LegacyOOMErrorCallback so that we can change the definition of
OOMErrorCallback (see https://crbug.com/1323177).

R=mlippautz@chromium.org

Bug: chromium:1323177
Change-Id: I92312a577ca49e0174f2bb6b914cc11c3a0b0fc1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3632305
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80424}
2022-05-09 12:32:51 +00:00
jameslahm
9e3f20b225 [test] Move cctest/test-log to unittests/logging/log-unittest
This is a reland of https://chromium-review.googlesource.com/c/v8/v8/+/3607389.
The previous revert is https://chromium-review.googlesource.com/c/v8/v8/+/3610448.
Reason for revert: https://crbug.com/v8/12838.

The original CL has merge conflicts and cannot be relanded,
so this CL is newly opened.

This CL moves cctest/test-log to unittests/logging/log-unittest
, fixes the flaky tests in https://bugs.chromium.org/p/v8/issues/detail?id=12838 and updates the unittests status for log-unittest.


Flaky Tests:
- https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux64%20TSAN%20-%20stress-incremental-marking/7287/overview
  - flaky LogTest.Issue539892 is caused by in stress-incremental-marking
    mode, Heap::MarkCompact will trigger CodeMovingGCEvent in https://source.chromium.org/chromium/chromium/src/+/main:v8/src/heap/heap.cc;l=2586;drc=52f06e6b43ff95eccf79e0a5df8d4d83c029130a for
    FakeCodeEventLogger which was already destructed
    when Heap::PerformGarbageCollection task was handled in
    DefaultPlatform::PumpMessageLoop. This should be fixed by removing
    FakeCodeEventLogger in LogTest.Issue539892.

  - flaky LogTest.LogAccessorCallbacks is caused by the data race in
    Sampler::DoSample. This should be fixed in https://chromium-
    review.googlesource.com/c/v8/v8/+/3616429.

-https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux64%20TSAN/41327/overview
  - flaky LogTest.ExternalLogEventListenerWithInterpretedFramesNativeStack
    is caused by the data race of i::FLAG_* which were written again after
    setting up the isolate. This should be fixed by only writting
    i::FLAG_* before setting up the Isolate.

- https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux64/47277/overview
  - flaky LogTest.BuiltinsNotLoggedAsLazyCompile is caused by the data
    race in Sampler::DoSample. This should be fixed in https://chromium-
    review.googlesource.com/c/v8/v8/+/3616429.

Bug: v8:12781
Change-Id: I3f736d4ffb3b8f147006bebe92285684b0c3952a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3616424
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: 王澳 <wangao.james@bytedance.com>
Cr-Commit-Position: refs/heads/main@{#80423}
2022-05-09 12:31:45 +00:00
Clemens Backes
d48558e6b7 Revert "[web snapshot] Recognize builtins"
This reverts commit 71dbb03e21.

Reason for revert: gc-stress failures: https://ci.chromium.org/p/v8/builders/ci/V8%20Linux%20-%20gc%20stress/38357

Original change's description:
> [web snapshot] Recognize builtins
>
> Builtins are not snapshotted, but instead we insert "builtin wrappers"
> into the snapshot, and create references to the corresponding builtin
> when deserializing.
>
> Subclassing builtins will be implemented in a follow-up CL.
>
> Bug: v8:11525,v8:12820
> Change-Id: If72695d46bdfc8bf7e477471be1264b668551854
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3630080
> Reviewed-by: Camillo Bruni <cbruni@chromium.org>
> Commit-Queue: Marja Hölttä <marja@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#80419}

Bug: v8:11525,v8:12820
Change-Id: I49f65103ad7b367c5bccb498f698e9afb29b1fec
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634799
Auto-Submit: Clemens Backes <clemensb@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Owners-Override: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80422}
2022-05-09 12:25:24 +00:00
jameslahm
4fb91a0f2b [logging] Fix tsan errro between Profiler::Insert and
... Profiler::Remove.

In Profiler::Insert and Profiler::Remove, TSAN cannot
figure out that when head_ and tail_ equals, Profiler::Insert
will always execute before Profiler::Remove, and tsan
will report data race between buffer_[head] write and
buffer_[base::Relaxed_Load(&tail_)]. This CL changes the
tail_ atomic load and store memory order to gurantee that
buffer_ read and write always after and before tail_ load
and store, which gives tsan more constraint.

Bug: v8:12838
Change-Id: I50296ffa4606b288e9ad9edc15d42f21ca1c7d2a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3626454
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: 王澳 <wangao.james@bytedance.com>
Cr-Commit-Position: refs/heads/main@{#80421}
2022-05-09 11:16:54 +00:00
Jakob Linke
3e43010abb [osr] Extend OSR tracing
New trace events:

- finished OSR compilation.
- entry into OSR code.

Since the latter now happens without a trip into runtime, tracing is a
bit more involved - we need to check FLAG_trace_osr in generated code,
and call a runtime function if it is set.

Drive-by: Slightly reorganize other OSR tracing.

Bug: v8:12161
Change-Id: I3096424ca7d47a19802281a0e0a39f7f3394c12b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3629331
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Auto-Submit: Jakob Linke <jgruber@chromium.org>
Commit-Queue: Jakob Linke <jgruber@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80420}
2022-05-09 11:13:24 +00:00
Marja Hölttä
71dbb03e21 [web snapshot] Recognize builtins
Builtins are not snapshotted, but instead we insert "builtin wrappers"
into the snapshot, and create references to the corresponding builtin
when deserializing.

Subclassing builtins will be implemented in a follow-up CL.

Bug: v8:11525,v8:12820
Change-Id: If72695d46bdfc8bf7e477471be1264b668551854
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3630080
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80419}
2022-05-09 10:45:44 +00:00
Camillo Bruni
40136c1b09 [flags] Introduce --max-opt
There are currently several flags to tune V8's optimisation level:
  --sparkplug, --maglev, --opt

This CL tries to make this simpler by introducing yet another flag.
--max-opt limits the maximum optimisation tier and avoids the common
error to mistake --no-opt with no dynamic optimisations.

Settings:
  --max-opt=999 Allow all optimisations, default configuration.
                Any number > 3 will do, as long as no other tier will be
                added.
  --max-opt=0   Allow only ignition
  --max-opt=1   Allow up to sparkplug
  --max-opt=2   Allow up to maglev
  --max-opt=3   Allow up to turbofan

Bug: v8:12825
Change-Id: Iff9a0fcccdf05e9770168053a1430303613a7299
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3605816
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Jakob Linke <jgruber@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80418}
2022-05-09 09:36:15 +00:00
Tobias Tebbi
cf804f269c [compiler] only emit constant loads for constant owner map
Bug: chromium:1323114
Change-Id: I2ec6c7d5eb5ef08914cfc1fac52d0128ecb27c53
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3630081
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Auto-Submit: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80417}
2022-05-09 09:25:04 +00:00
Jakob Linke
b8b7a3a2f9 [maglev] Turn on fuzzing for --maglev
Turn on fuzzing for Maglev to get additional test coverage.

Bug: v8:7700
Change-Id: I5b72d851639e31dff1bd91361cd81ad448c2d69e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3629334
Auto-Submit: Jakob Linke <jgruber@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80416}
2022-05-09 09:22:14 +00:00
Anton Bikineev
070b5f309f cppgc: young-gen: Return range size for AgeTable to 4KB
Allocation granularity (8 bytes on 64bit platforms) is already subsumed
by whatever range size we choose.

Bug: chromium:1029379
Change-Id: Iab95e6f36955c9ffbbe9ea0c98cb9d1f8dd0337b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3629869
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Auto-Submit: Anton Bikineev <bikineev@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80415}
2022-05-09 08:42:44 +00:00
Patrick Thier
8f1a5c8e29 [cleanup] Remove unused code introduced for concurrent string migrations
With the introduction of the StringForwardingTable, there are no
concurrent transitions of strings happening anymore.

- Remove String migration sentinel maps + helper methods
- Remove CanMigrateInParallel()
- Remove MigrateStringMapUnderLockIfNeeded() and simplify MakeThin()

There is still unused code I didn't remove in this CL, as we might need
it later for shared struct features: YIELD_PROCESSOR for spinlocks and
Relaxed_Memcmp().

Bug: v8:12007
Change-Id: Iaa09ef93d2ee612e42cd73395a06eada22fe7dae
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3629545
Commit-Queue: Patrick Thier <pthier@chromium.org>
Reviewed-by: Dominik Inführ <dinfuehr@chromium.org>
Reviewed-by: Shu-yu Guo <syg@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80414}
2022-05-09 08:17:54 +00:00
v8-ci-autoroll-builder
17a052b2ad Update V8 DEPS.
Rolling v8/build: 7b99cdb..9c02936

Rolling v8/third_party/fuchsia-sdk/sdk: version:8.20220507.2.1..version:8.20220508.2.1

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

Change-Id: Idf098b319032d00e79ef810dcdf0c0c6505e05b3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3634008
Bot-Commit: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: v8-ci-autoroll-builder <v8-ci-autoroll-builder@chops-service-accounts.iam.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#80413}
2022-05-09 03:51:54 +00:00
Frank Tang
c9ebb118a9 [Temporal] Fix GCC >= comparison error by cl/3624980.
Change kUTCTimeZoneIndex to int32_t from uint32_t
And compare index against 0.

Bug: v8:11544
Change-Id: Ib7dd55cab796d1d9a4b0e2869b098520265a04f0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3632678
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/main@{#80412}
2022-05-09 02:50:23 +00:00