Commit Graph

79728 Commits

Author SHA1 Message Date
Andreas Haas
b77287525d [wasm] Update spec tests
R=thibaudm@chromium.org

Change-Id: Ic0d953530118cec8933bd64ab2e40607975bc039
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4156057
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85236}
2023-01-11 19:59:14 +00:00
Shu-yu Guo
8267c7e12c [flags] Remove --harmony-array-find-last
The Array and TypedArray findLast and findLastIndex proposal has shipped
since M97.

Bug: v8:11990
Change-Id: Iece995c020c2b5535abc4dd2a47516265e445fc3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4144631
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Reviewed-by: Adam Klein <adamk@chromium.org>
Auto-Submit: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85235}
2023-01-11 19:52:46 +00:00
Shu-yu Guo
a216b3de4b [shared-struct] Mark shared constructors has_non_instance_prototype
Bug: v8:12547
Change-Id: I63cbb45565ec978a38726d993753f14bd6e7fbea
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4144662
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85234}
2023-01-11 19:31:54 +00:00
Shu-yu Guo
f1adbe2e44 [shared-struct] Fix shared value barrier in TF
This CL fixes a bug where TurboFan was incorrectly compiling away the
shared value barrier for shared arrays.

TurboFan should not be compiling accesses to objects in the shared heap
until it natively has support for the shared value barrier, because it
is an invariant that shared objects do not point to non-shared objects.

Bug: chromium:1404052, v8:12547
Change-Id: I5bd44ce5c44ad81a97421598e6d5b24fb5e210cd
Fixed: chromium:1404052
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4136980
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85233}
2023-01-11 19:28:45 +00:00
Michael Lippautz
24ca73004e cppgc: Implement slim write barrier
Introduces a slim write barrier for Oilpan behind
`cppgc_enable_slim_write_barrier` that is enabled by default. The slim
write barrier only performs a single approximate global check for
whether the write barrier is needed and delegates all other checks to
a slow path call. This is beneficial in configurations that do not need
many checks for the barrier overall, i.e., configurations without
young generation. Young generation is off by default which is why this
approach is beneficial.

On Speedometer the write barrier is hit 75M times with a fast bailout
of 99.3%. Progression on Speedometer2 is somewhere around 0.2-0.5%.

The resulting code embedded in another function is only 34 bytes
compared to 128 bytes before. See attached bug for detailed assembly
snippet.

Change-Id: I6869513186e7a26104c46f1f2ac2cfa855689f64
Bug: chromium:1406464
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152488
Reviewed-by: Anton Bikineev <bikineev@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85232}
2023-01-11 18:54:57 +00:00
Clemens Backes
080e281820 Reland "[x64] Make {Assembler::GrowBuffer} preserve most registers"
This is a reland of commit 8fe57bf641.
We restrict the use of "preserve_most" to x64 and arm64 in
non-component builds for now.

Original change's description:
> [x64] Make {Assembler::GrowBuffer} preserve most registers
>
> This makes many callers of {GrowBuffer} a lot slimmer, by avoiding the
> need to push and pop all values in otherwise caller-saved registers.
> E.g. {emit_mov(Register, Operand)} was measured to be ~2x faster (from
> 2.3% of Liftoff compilation time to 1.2%).
>
> R=bikineev@chromium.org
> CC=dlehmann@chromium.org
>
> Bug: v8:13565
> Change-Id: I681747a491548adf1374187cd9f37520c153ef1a
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4127230
> Reviewed-by: Leszek Swirski <leszeks@chromium.org>
> Commit-Queue: Clemens Backes <clemensb@chromium.org>
> Reviewed-by: Anton Bikineev <bikineev@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85147}

Bug: v8:13565
Change-Id: I273e222b423786fdc0338c7dfab3d95c8af6ff13
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147788
Reviewed-by: Anton Bikineev <bikineev@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85231}
2023-01-11 17:53:05 +00:00
Anton Bikineev
78717ce93d cppgc: Return empty pages right away when sweeping on allocation
This should save about 0.23% cycles on the JQuery Speedometer story.

Bug: chromium:1406296
Change-Id: Ib2b76325c6441eb5da8051c3701291abf347c56d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152952
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Anton Bikineev <bikineev@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85230}
2023-01-11 16:57:55 +00:00
Leszek Swirski
c617c553a6 Revert "[turbofan] Properly perform range check for array access"
This reverts commit ec4f19d530.

Reason for revert: Speculative revert for speculative-lowering failures in the roll (e.g. https://ci.chromium.org/ui/p/chromium/builders/try/linux_optional_gpu_tests_rel/b8792253516032578097/test-results?q=ExactID%3Aninja%3A%2F%2Fchrome%2Ftest%3Atelemetry_gpu_integration_test%2Fgpu_tests.webgl2_conformance_integration_test.WebGL2ConformanceIntegrationTest.deqp%2Ffunctional%2Fgles3%2Ffbocolorbuffer%2Fblend.html+VHash%3Aa55ece39ab587dea&clean=&sortby=&groupby=)

Original change's description:
> [turbofan] Properly perform range check for array access
>
> Turbofan optimized array access returned incorrect values in some cases
> when a negative index was provided. This CL fixes this by changing the
> way those bounds checks are performed in JSNativeContextSpecialization.
>
> Bug: chromium:1320641
> Change-Id: Id1f06680ccf7964994d179f7fb44199a0b1245b1
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147622
> Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
> Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85207}

Bug: chromium:1320641
Change-Id: I4e7899eb89ec8ef5541a57f7a0fb8fe6a452371a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4156871
Owners-Override: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@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@{#85229}
2023-01-11 16:20:06 +00:00
Michael Lippautz
38a4042c05 Reland "[heap] Move methods from LocalEmbedderHeapTracer to CppHeap"
This is a reland of commit 40b002ffbc

Original change's description:
> [heap] Move methods from LocalEmbedderHeapTracer to CppHeap
>
> Move methods around tracing to CppHeap and simplifies overall tracing
> logic.
>
> Bug: v8:13207
> Change-Id: I539fba924ba3f8f329405e084b999b18a7adfe7e
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147610
> Reviewed-by: Omer Katz <omerkatz@chromium.org>
> Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85152}

Bug: v8:13207
Change-Id: I42834edd7a0a84d01df60e8dfdfe7a1c0cac5533
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4155912
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85228}
2023-01-11 15:51:30 +00:00
Victor Gomes
169bdfe408 [maglev] Fix CheckJSDataViewBounds clobbered argument
If the register allocator assigns kJavaScriptCallArgCountRegister
to {object}, we were clobbering the object, before pushing it to
the stack.

Additionally, we use PushReverse instead of Push to indicate
that kDataViewPrototypeGetByteLength has a JS call convention
(arguments are reversed). This is a no-op for x64, but it guarantees
the correct order of the padding in arm64.

Fixed: chromium:1406456
Bug: v8:7700, v8:13645
Change-Id: Ia9126ff5315ab4ab08ae733f138a1e0cb2d021a2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4156053
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85227}
2023-01-11 14:42:46 +00:00
Darius M
8dd716db16 [maglev] Re-enable in-heap Typed Arrays
Bug: v8:7700
Change-Id: Iaccce419f5269ab7a6bd257bf952e3226143c32d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154422
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Darius Mercadier <dmercadier@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85226}
2023-01-11 14:16:25 +00:00
Matthias Liedtke
177bfd1502 [wasm-gc] Remove deprecated array.len
Rmove the deprecated array.len 0xfb17 variant which takes a type
immediate.
This has been superseded by 0xfb19 which does not need the type.

Bug: v8:7748
Change-Id: I7d4620423c786462444512abe40ee006aab99cf2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4110831
Reviewed-by: Manos Koukoutos <manoskouk@chromium.org>
Commit-Queue: Matthias Liedtke <mliedtke@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85225}
2023-01-11 14:11:23 +00:00
Hannes Payer
32f82d0f48 Disable page permission flipping of code pages
Code protection based on page permission flipping is inherently unsafe since it does not prevent concurrent modification of unprotected pages. It also comes with a significant performance cost. Going forward we will rely on per-thread page permission mechanisms (e.g. PKEYS) to protect code memory.

Change-Id: I28e15899cd6316fbe146f3725b9e0c81a668e1dd
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4156051
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Samuel Groß <saelo@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85224}
2023-01-11 14:10:20 +00:00
Matthias Liedtke
b77e704a74 [wasm-gc] Remove deprecated callref variant
This removes the deprecated callref variant 0x17 which has been
superseded by 0x14.

Bug: v8:7748
Change-Id: I8e3704f5b302428eb175df2d59896a1b6c6a1323
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4118868
Commit-Queue: Matthias Liedtke <mliedtke@chromium.org>
Reviewed-by: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85223}
2023-01-11 14:05:19 +00:00
Milad Fa
880f8208ef PPC/s390: [static-roots] Use static roots in CSA
Port 643b458b07

Original Commit Message:

    Like in https://chromium-review.googlesource.com/c/v8/v8/+/4130075
    we add the same optimizations to non-C++ builtins.

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

Change-Id: I46ea828bc6c2cea395a20e1d7748e96a87bcaee2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4150961
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Junliang Yan <junyan@redhat.com>
Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
Reviewed-by: Joran Siu <joransiu@ca.ibm.com>
Cr-Commit-Position: refs/heads/main@{#85222}
2023-01-11 13:43:31 +00:00
Omer Katz
2a5e1878a5 Reland "Reland "[heap] Adjust pretenuring heuristic for MinorMC""
This is a reland of commit 47405154da

Original change's description:
> Reland "[heap] Adjust pretenuring heuristic for MinorMC"
>
> This is a reland of commit a614ccb8f7
>
> This CL will cause a performance regression when running with MinorMC on
> the bots. However this regression is expected (due to delaying pretenuring
> decisions) and we anyway result from relanding crrev.com/c/4092734.
>
> Original change's description:
> > [heap] Adjust pretenuring heuristic for MinorMC
> >
> > MinorMC needed to process pretenuring feedback both after sweeping and
> > at the end of the atomic pause, despite having no new feedback at the
> > end of the atomic pause, because the heuristics didn't hold after
> > sweeping. This CL adjusts the heuristics for MinorMC so that processing
> > twice is no longer needed.
> >
> > Bug: v8:12612
> > Change-Id: I4d3ebaeaa6e7868bcdcae6fbdb3bcecb0ebcb8bf
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4085983
> > Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> > Commit-Queue: Omer Katz <omerkatz@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#84730}
>
> Bug: v8:12612
> Change-Id: I3101f8c8b4c1d34ff95802fbc8c8d1fff81e8ddd
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147607
> Commit-Queue: Omer Katz <omerkatz@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85161}

Bug: v8:12612
Change-Id: I9de00799fb79403289d6ec3d47f1696b0410cf28
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4155013
Auto-Submit: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85221}
2023-01-11 13:36:31 +00:00
Mikhail Khokhlov
c3c8c86850 Fix v8_snapshot build in Chromium with v8_use_perfetto=true
We're migrating Chrome tracing to Perfetto SDK, and the first step is
to make everything build with perfetto library.

Example build errors:
https://ci.chromium.org/ui/p/chromium/builders/ci/linux-headless-shell-rel/52404

Bug: chromium:1006766
Change-Id: I5da38f421b742be41a9cf1993a3cf463ec3cb801
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152474
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Mikhail Khokhlov <khokhlov@google.com>
Cr-Commit-Position: refs/heads/main@{#85220}
2023-01-11 13:14:37 +00:00
Victor Gomes
f73f3b3b51 [maglev] Remove MaglevGraphHasUnimplementedNode
Bug: v8:7700
Change-Id: Ic7bd3cef4b4fd29d7b03b8a3896b8ed6675c518a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154424
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85219}
2023-01-11 13:06:39 +00:00
Darius M
7e169e2052 [maglev] Fix liveness hole bug in register allocator
Bug: v8:7700, v8:13639, chromium:1403893
Change-Id: Ie49b4bce1a5fe406a2bec31e307968cc29929430
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152479
Commit-Queue: Darius Mercadier <dmercadier@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85218}
2023-01-11 12:51:56 +00:00
Victor Gomes
e17d443bfb [maglev][arm64] Fix initialization of stack slots loop
Bug: v8:7700
Change-Id: I923f45f7e3821062bd0af5086bcf086de988f604
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154423
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Patrick Thier <pthier@chromium.org>
Commit-Queue: Patrick Thier <pthier@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85217}
2023-01-11 12:49:54 +00:00
Victor Gomes
20aad404d0 [maglev] Share JumpLoopProgolue IR
Bug: v8:7700
Change-Id: I738523b02e2700438a179e00f252d3fce53a0066
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4131403
Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85216}
2023-01-11 12:44:14 +00:00
pthier
9685f44f51 [static-roots][arm64] Avoid using a scratch register in LoadRoot
The immediate value for a read-only root can be larger than 12-bit and
therefore can't be encoded directly on arm64. To avoid using an
additional scratch register, we can use the destination for the prepared
immediate operand.

Bug: v8:13466
Change-Id: I7904770c4a155a876793c029e3ad321825517a8e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154420
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Patrick Thier <pthier@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85215}
2023-01-11 12:38:08 +00:00
Simon Zünd
c16405e82e [cleanup] Remove experimental flag for [[Scopes]] removal
After we received feedback about some legitmate use-cases of the
internal [[Scopes]] property, we decided to not go ahead with its
removal.

This CL removes the corresponding experimental flag.

R=kimanh@chromium.org

Bug: chromium:1365858
Change-Id: I6744889b4e2e960695838648e2f4902cbdb75890
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154416
Auto-Submit: Simon Zünd <szuend@chromium.org>
Commit-Queue: Simon Zünd <szuend@chromium.org>
Commit-Queue: Kim-Anh Tran <kimanh@chromium.org>
Reviewed-by: Kim-Anh Tran <kimanh@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85214}
2023-01-11 11:51:48 +00:00
Simon Zünd
705c8406a5 [cleanup] Remove the '--experimental-reuse-locals-blocklists' flag
The feature shipped with M109 so we'll remove the flag with M111.

R=jarin@chromium.org

Bug: chromium:1363561
Change-Id: Ia9b276f6c56fb3f57c57f5da1abe02dda8dc36e8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154418
Reviewed-by: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Simon Zünd <szuend@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85213}
2023-01-11 11:50:44 +00:00
Michael Achenbach
424e51c106 [foozzie] Add more contradiction configs after readonly-flags introduction
No-Try: true
Bug: v8:10577, chromium:1406056
Change-Id: If4204cadc2647931c55ec81e83080e7eb3b5a2b1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154419
Auto-Submit: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Jakob Linke <jgruber@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85212}
2023-01-11 11:13:48 +00:00
Matthias Liedtke
a54fc340b1 [wasm-gc] Remove structref as dataref compatibility fallback
Currently structref is interpreted as dataref by default for backwards
compatibility reasons.
This behavior is now being removed with this change.

Bug: v8:7748
Change-Id: I610fd04187b1bda53c83a82345eae09f23d99731
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4111171
Auto-Submit: Matthias Liedtke <mliedtke@chromium.org>
Reviewed-by: Manos Koukoutos <manoskouk@chromium.org>
Commit-Queue: Matthias Liedtke <mliedtke@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85211}
2023-01-11 11:11:31 +00:00
Jakob Linke
539b50f5ae [turbofan] Add the v8_enable_turbofan build option
When disabled, Turbofan is fully excluded from the compilation result.
This is expected to reduce V8's contribution to chromium's binary size
by roughly 20%.

If Turbofan is disabled, Maglev and Webassembly must also be disabled
(since both depend on TF).

Note this new configuration (v8_enable_turbofan=false) is not yet
used anywhere - we'll probably enable it for lite_mode bots in an
upcoming CL for test coverage.

Changes in detail:
- Split out all src/compiler files from the main source sets. This
  was mostly done already, here we only clean up the few files that
  were left.
- Define a new main TF entry point in turbofan.h. `NewCompilationJob`
  replaces `Pipeline::NewCompilationJob`.
- When TF is enabled, turbofan-enabled.cc implements the above.
- When disabled, turbofan-disabled stubs out the above with a runtime
  FATAL message.
- The build process is modified s.t. mksnapshot always has TF
  available since it's needed to generate builtins. When disabled,
  TF is removed from other components, in particular it is no longer
  included in v8_compiler and transitively in v8_base.
- When disabled, v8_for_testing no longer has v8_initializers
  available. These were only needed for test-serialize.cc, which
  is now excluded from this build mode.
- When disabled, remove all related cctest/ und unittest/ files from
  the build.

Bug: v8:13629
Change-Id: I63ab7632f03d0ee4a787cfc01574b5fdb08fd80b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4128529
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Auto-Submit: Jakob Linke <jgruber@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Jakob Linke <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85210}
2023-01-11 10:57:54 +00:00
Leszek Swirski
93165a6721 [maglev] Add maglev config to foozzie
Bug: v8:7700
Change-Id: I2e20d457e303bf4cd4338ff45bb47c8f863885c3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152473
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85209}
2023-01-11 10:56:28 +00:00
Andreas Haas
5482480488 [perf] Add file to js-perf-test resources list
The file `at.js` was missing in the resources list, and did therefore
not get uploaded to the perf bot. This caused an error on the perf bot.

R=machenbach@chromium.org
CC=dmercadier@chromium.org

Bug: v8:12926
Change-Id: I199591444da651854633a37e7164756981b9353f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154414
Auto-Submit: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85208}
2023-01-11 10:50:45 +00:00
Nico Hartmann
ec4f19d530 [turbofan] Properly perform range check for array access
Turbofan optimized array access returned incorrect values in some cases
when a negative index was provided. This CL fixes this by changing the
way those bounds checks are performed in JSNativeContextSpecialization.

Bug: chromium:1320641
Change-Id: Id1f06680ccf7964994d179f7fb44199a0b1245b1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147622
Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85207}
2023-01-11 10:49:41 +00:00
Leszek Swirski
ce59644aab Revert "[heap] Move methods from LocalEmbedderHeapTracer to CppHeap"
This reverts commit 40b002ffbc.

Reason for revert: Speculative revert for roll failures (e.g. https://chromium-swarm.appspot.com/task?id=5fb7fceb6da89111)

Original change's description:
> [heap] Move methods from LocalEmbedderHeapTracer to CppHeap
>
> Move methods around tracing to CppHeap and simplifies overall tracing
> logic.
>
> Bug: v8:13207
> Change-Id: I539fba924ba3f8f329405e084b999b18a7adfe7e
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147610
> Reviewed-by: Omer Katz <omerkatz@chromium.org>
> Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85152}

Bug: v8:13207
Change-Id: Icf20310eaf3bbb7b11cd136f6ed242f98659d863
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4155014
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Owners-Override: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85206}
2023-01-11 10:34:54 +00:00
Michael Achenbach
0199cde71f [trials] Add new contradictions after readonly-flags introduction
No-Try: true
Bug: v8:10577
Change-Id: I9d17d907f900dbb734ed6e6c22bf7a75766082c0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154412
Commit-Queue: Jakob Linke <jgruber@chromium.org>
Auto-Submit: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Jakob Linke <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85205}
2023-01-11 10:17:41 +00:00
Manos Koukoutos
08eb7fec3d [wasm-gc] Fix typing of phis
Phis should be typed correctly in the wasm typer even if the branch of
the first phi input is unreachable.

Bug: v8:7748
Change-Id: I9276127c0f92f9b74f61dd19502790c779ae3393
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151198
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85204}
2023-01-11 10:05:36 +00:00
Leszek Swirski
734795c1a0 Revert "Reland "[heap] Adjust pretenuring heuristic for MinorMC""
This reverts commit 47405154da.

Reason for revert: Speculative revert for roll failures: (https://ci.chromium.org/ui/p/chromium/builders/try/linux_chromium_tsan_rel_ng/1395090/overview and others)

Original change's description:
> Reland "[heap] Adjust pretenuring heuristic for MinorMC"
>
> This is a reland of commit a614ccb8f7
>
> This CL will cause a performance regression when running with MinorMC on
> the bots. However this regression is expected (due to delaying pretenuring
> decisions) and we anyway result from relanding crrev.com/c/4092734.
>
> Original change's description:
> > [heap] Adjust pretenuring heuristic for MinorMC
> >
> > MinorMC needed to process pretenuring feedback both after sweeping and
> > at the end of the atomic pause, despite having no new feedback at the
> > end of the atomic pause, because the heuristics didn't hold after
> > sweeping. This CL adjusts the heuristics for MinorMC so that processing
> > twice is no longer needed.
> >
> > Bug: v8:12612
> > Change-Id: I4d3ebaeaa6e7868bcdcae6fbdb3bcecb0ebcb8bf
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4085983
> > Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> > Commit-Queue: Omer Katz <omerkatz@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#84730}
>
> Bug: v8:12612
> Change-Id: I3101f8c8b4c1d34ff95802fbc8c8d1fff81e8ddd
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147607
> Commit-Queue: Omer Katz <omerkatz@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85161}

Bug: v8:12612
Change-Id: Ib3efee6a75f4267dcdee74cac97d2ee785f35361
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151748
Owners-Override: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85203}
2023-01-11 09:25:08 +00:00
Manos Koukoutos
f918193221 [wasm-gc] Optimize call_indirect type checks
Remove type check if declared signature exactly matches table
signature. Remove null check if the table is non-nullable.

Bug: v8:7748
Change-Id: Ie42bb77a40d76855dfa8379d58d9accd1e1c6d6d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4136074
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85202}
2023-01-11 09:24:04 +00:00
Olivier Flückiger
77f99a6bb6 [static-roots] Expose static roots as symbols
Create names for each static root. This is useful for debugging. It
might also be useful to track changing names and ensure static-roots.h
agrees with the actual name of the static root.

Bug: v8:13466
Change-Id: I32e2b370d99aabe42c87e2a3db7a8e5ebaae3e04
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151189
Reviewed-by: Jakob Linke <jgruber@chromium.org>
Commit-Queue: Olivier Flückiger <olivf@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85201}
2023-01-11 09:16:41 +00:00
Jakob Linke
355d6941d9 Remove jgruber from the maglev WATCHLISTS
Change-Id: Id12d6f1e2470494731a18bbcb38f556947e8716e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154410
Auto-Submit: Jakob Linke <jgruber@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85200}
2023-01-11 09:13:44 +00:00
Victor Gomes
92c9a4a84b [maglev][arm64] Missing number load in CheckedObjectToIndex
Bug: v8:7700
Change-Id: I841293e6a5190ed008e3e0d95bd0b9e8d304c770
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152478
Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85199}
2023-01-11 08:32:44 +00:00
Michael Achenbach
8fe2791b37 [infra] Update Windows-10 version for testing
No-Try: true
Bug: chromium:1406448
Change-Id: Ife4643913e340c382eaf8738b13bdb47b4b6f46d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4154411
Auto-Submit: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Alexander Schulze <alexschulze@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85198}
2023-01-11 08:26:56 +00:00
Clemens Backes
cb004862a3 [wasm] Mark validated functions as such
Functions validated during streaming compilation (via
{ValidateSingleFunction}) should get marked as validated, to avoid
unnecessary re-validation before compiling them.

R=ahaas@chromium.org

Change-Id: If0285e41774158c018adfc1041c27bd9302fbb86
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152483
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85197}
2023-01-11 06:43:57 +00:00
Simon Zünd
b0861973d5 [inspector] Fix catch prediction in async generators
This CL adds some tests for async generators to ensure that we
correctly report caught/uncaught exceptions.

Most of the cases were fixed by the for-of fix:
https://crrev.com/c/4146420

The remaining broken test cases contain a throw directly
after a `yield`. For each ".next" call we create a new promise
that we need to push on the promise stack before we actually
resume the generator.

R=bmeurer@chromium.org

Fixed: chromium:1270780
Change-Id: I8365d20490451be37cc6973d8d91aeffed7e3511
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4146421
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Simon Zünd <szuend@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85196}
2023-01-11 05:41:25 +00:00
Jaroslav Sevcik
b5c727768e [inspector] Fix calculation of breakpoint hint offset
Bug: chromium:1406169
Bug: chromium:1404643
Change-Id: I03fa130e64cd84f1559c123ca77eb740e424cc70
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152475
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Jaroslav Sevcik <jarin@chromium.org>
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85195}
2023-01-11 05:18:31 +00:00
John Paul Adrian Glaubitz
3cea5d5425 [runtime] Avoid {Object::operator->} for 32-bit big endian targets
878ccb33bd converted the runtime code to avoid {Object::operator->}
but missed the conversion of 32-bit big endian targets. Fix this.

Change-Id: Idf3a08f03995136a7cabd5cc136412f25de2ea32
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4124995
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85194}
2023-01-10 20:19:08 +00:00
Jakob Kummerow
fe7f2350de Only install conditional features if global is extensible
Fixed: chromium:1404076
Change-Id: I6af834ff3b6082b01ea192a7792268c4c8e764f0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151206
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Auto-Submit: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85193}
2023-01-10 20:16:47 +00:00
Shu-yu Guo
b0be4f8ddb [shared-struct] Fix shared barrier for always shared objects
Currently the shared value barrier manually fast paths instance types
for objects that are always in the shared heap. This CL makes a common
superclass, AlwaysSharedSpaceJSObject, and uses that for the fast path.

Bug: chromium:1402920, v8:12547
Fixed: chromium:1402920
Change-Id: I84421802791a4dc72925341eeb0cfc5949b8938a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4134475
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85192}
2023-01-10 19:07:40 +00:00
Omer Katz
59657281c2 [heap] Fix false OLD_TO_OLD remembered set in MinorMC
A MinorMC in a client isolate while incremental marking is active in the
main isolate may observe an object in the shared heap as residing on an
evacuation candidate. It would then treat it as OLD_TO_OLD rather than
OLD_TO_SHARED.
This logic is obsolete and no longer needed since MinorMC is not
interleaved with full GCs and only need to record OLD_TO_NEW and
OLD_TO_SHARED slots.
Fix by removing OLD_TO_OLD and OLD_TO_CODE recording.

Bug: chromium:1402660
Change-Id: I5482d3fe7d7a4eeb00be13445d66f178a3ffe2fb
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152485
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85191}
2023-01-10 19:05:47 +00:00
Victor Gomes
12a2fc2aad [maglev][arm64] Add MaterialiseValueNode
Drive-by fixes:
1. On x64, avoid reloading from memory a value already in a register.
2. On arm64, pop has the wrong order of the padding/value.

Bug: v8:7700
Change-Id: I3baedcc280f5c544cc9d44b37aaf80e4eb8bd636
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152472
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Patrick Thier <pthier@chromium.org>
Commit-Queue: Patrick Thier <pthier@chromium.org>
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85190}
2023-01-10 17:05:01 +00:00
Leszek Swirski
41e79f0f24 [maglev] Re-enable on foozie
Bug: v8:7700
Change-Id: I96a43e1497245cddf17e898fe36dd67ce88b8874
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151202
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85189}
2023-01-10 15:37:17 +00:00
Jakob Kummerow
6bc1c1f2b6 [wasm] Drop overly aggressive DCHECK in TriggerTierUp
Fixed: chromium:1404074
Change-Id: Ic8171d035f5eb758a6f60674a21635d0dceff23c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151205
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Auto-Submit: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85188}
2023-01-10 14:55:40 +00:00
Qifan Pan
5cf5e8184b [js-perf-test] Clean up BigInt perf tests
This CL removes

- redundant perf tests for addition and subtraction
- deprecated perf tests of addition without optimization
- perf tests for error throwing

Bug: v8:9407
Change-Id: Ib6c6015e1547ed87de071c430661cb2ad084c9ca
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151201
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Commit-Queue: Qifan Pan <panq@google.com>
Cr-Commit-Position: refs/heads/main@{#85187}
2023-01-10 14:52:10 +00:00