Commit Graph

3244 Commits

Author SHA1 Message Date
Manos Koukoutos
455d38ff8d Reland "[wasm-gc] Introduce wasm null object"
This is a reland of commit 2e357c4814

Difference compared to original: Initialize wasm-null object's
payload.

Original change's description:
> [wasm-gc] Introduce wasm null object
>
> We introduce a wasm null object, separate from JS null. Its purpose is
> to support trapping null accesses for wasm objects.
> This will be achieved by allocating a large payload for it (larger than
> any wasm struct) and memory-protecting it (see linked CL). The two null
> objects get mapped to each other at the wasm-JS boundary.
> Since externref objects live on the JS side of the boundary,
> null-related instructions in wasm now need an additional type argument
> to handle the correct null object.
>
> Bug: v8:7748
> Change-Id: I06da00fcd279cc5376e69ab7858e3782f5b5081e
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4200639
> Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85648}

Bug: v8:7748
Change-Id: I46413d05f0213229f1d19277ae98dbb8df5afdf9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4224011
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85705}
2023-02-07 11:19:47 +00:00
Dave Tapuska
0253c3a979 [ios] Fix an additional build failure on iOS.
- Adjust an is_mac to is_apple

Bug: chromium:1411704
Change-Id: I2456f8b4f793b37f4b64782e8403dd4fc84b0807
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4221871
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Dave Tapuska <dtapuska@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85652}
2023-02-03 17:55:42 +00:00
Nico Hartmann
79efc8f090 Revert "[wasm-gc] Introduce wasm null object"
This reverts commit 2e357c4814.

Reason for revert: Speculative revert for https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Clusterfuzz%20Linux%20MSAN%20no%20origins/33231/overview

Original change's description:
> [wasm-gc] Introduce wasm null object
>
> We introduce a wasm null object, separate from JS null. Its purpose is
> to support trapping null accesses for wasm objects.
> This will be achieved by allocating a large payload for it (larger than
> any wasm struct) and memory-protecting it (see linked CL). The two null
> objects get mapped to each other at the wasm-JS boundary.
> Since externref objects live on the JS side of the boundary,
> null-related instructions in wasm now need an additional type argument
> to handle the correct null object.
>
> Bug: v8:7748
> Change-Id: I06da00fcd279cc5376e69ab7858e3782f5b5081e
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4200639
> Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85648}

Bug: v8:7748
Change-Id: Ie53febf49b946217e0057959c757d811a97ca1eb
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4219105
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Owners-Override: Nico Hartmann <nicohartmann@chromium.org>
Auto-Submit: Nico Hartmann <nicohartmann@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85649}
2023-02-03 16:57:44 +00:00
Manos Koukoutos
2e357c4814 [wasm-gc] Introduce wasm null object
We introduce a wasm null object, separate from JS null. Its purpose is
to support trapping null accesses for wasm objects.
This will be achieved by allocating a large payload for it (larger than
any wasm struct) and memory-protecting it (see linked CL). The two null
objects get mapped to each other at the wasm-JS boundary.
Since externref objects live on the JS side of the boundary,
null-related instructions in wasm now need an additional type argument
to handle the correct null object.

Bug: v8:7748
Change-Id: I06da00fcd279cc5376e69ab7858e3782f5b5081e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4200639
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85648}
2023-02-03 16:06:12 +00:00
Victor Gomes
ff1dba398d [codegen] Merge Turbo and Macro assemblers
There is no real difference between MacroAssembler and TurboAssembler
anymore. Initially the idea was to differentiate thread-safe
operations, but it got out of hand. With LocalHeaps we could ensure
differently by passing a local_isolate.

In this CL:

TurboAssemblerBase was renamed to MacroAssemblerBase
The file containing it also renamed from turbo-assembler to macro-assembler-base.

TurboAssembler and MacroAssembler were merged into MacroAssembler
in each of the architectures.

turbo-assembler-unittests-arch were included in
macro-assembler-unittests-arch

tasm renamed to masm

Bug: v8:13707
Change-Id: I716bbfc51b33ac890c72e8541e01af0af41b6770
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4212396
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Jakob Linke <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85610}
2023-02-02 09:27:45 +00:00
Shu-yu Guo
15cc02b4e8 [shared-struct] Disallow property redefinition
Shared objects have fixed layout (i.e. immutable maps) and start off
sealed. Ordinary JS objects allow writable properties to be redefined to
be non-writable. This violates the fixed layout invariant and needs to
be disallowed.

Also contains a drive-by fix removing
@highestInstanceTypeWithinParentClassRange, which is unneeded.

Bug: chromium:1407595, v8:12547
Change-Id: I0257fa19f59ccfaaf0e07cb42aeedd71e132d21a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4190525
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85570}
2023-01-31 18:42:46 +00:00
Dave Tapuska
d3f27e067e [ios] Enable ability to run V8 in jitless mode on iOS device
Forcibly enable jitless mode since we do not have access to executable
code pages. This will also disables wasm.

Do not enable JSCVT based on the compiler since older iPhones may not
have the JSVCT instruction. This will eventually need to be done
dynamically.

Use the host toolchain when compiling on M1 Macbooks for iOS devices.

Ensure we use 16k alignment for pages.

Bug: chromium:1411704
Change-Id: I0019a2fc7b645b96ae105504d915cd0c3e3eafdf
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4206250
Commit-Queue: Dave Tapuska <dtapuska@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85569}
2023-01-31 18:41:43 +00:00
Maya Lekova
8ce2c87338 Revert "[turboshaft] Implement structural optimization reducer"
This reverts commit 596e56868d.

Reason for revert: Breaks JetStream2 on perf bots.

Original change's description:
> [turboshaft] Implement structural optimization reducer
>
> This CL adds a new Turboshaft reducer that is suitable for changing the
> graph in a way that doesn't reduce individual operations, rather changes
> the structure of the graph. The first such reduction we support is
> transforming if-else cascades that check if a given value is equal to
> any constant from a given set into a switch with cases corresponding to
> the constants in the set.
>
> Bug: v8:12783
> Change-Id: Iee1e5581a334c3dc255d673d2178f76706e6dae2
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4106752
> Commit-Queue: Maya Lekova <mslekova@chromium.org>
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Reviewed-by: Clemens Backes <clemensb@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85561}

Bug: v8:12783
Change-Id: Ic9ded7f4e18258346f547600cb541b2fa094fb8d
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4210088
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Auto-Submit: Maya Lekova <mslekova@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85566}
2023-01-31 17:11:51 +00:00
Maya Lekova
596e56868d [turboshaft] Implement structural optimization reducer
This CL adds a new Turboshaft reducer that is suitable for changing the
graph in a way that doesn't reduce individual operations, rather changes
the structure of the graph. The first such reduction we support is
transforming if-else cascades that check if a given value is equal to
any constant from a given set into a switch with cases corresponding to
the constants in the set.

Bug: v8:12783
Change-Id: Iee1e5581a334c3dc255d673d2178f76706e6dae2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4106752
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85561}
2023-01-31 14:27:23 +00:00
Marja Hölttä
1f349da554 [web snapshots] Remove web snapshots
Bug: v8:11525
Change-Id: I0931408eefa4f55b0c9e8c0973787edfb903083a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4205917
Commit-Queue: Marja Hölttä <marja@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85559}
2023-01-31 12:43:03 +00:00
Nico Hartmann
c334837594 [turboshaft] Build skeleton for EffectControlLinearizer port
Bug: v8:12783
Change-Id: Id20476383709db4fe2acc90e073bd3a8e21244c8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4194718
Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85491}
2023-01-26 12:37:28 +00:00
Victor Gomes
52cbf1dfe4 [maglev] MaglevAssembler Scratch Register Scope
An unified scratch scope for Maglev.
- For arm64 we reuse the architecture scope.
- For x64, we create a simple linked list scope.

DeferredCode carries the same temporary scope.

The node temporaries registers now represents the available
temporary registers (i.e., minus fixed/specific ones).

Also refactor some shared code to maglev-assembler-inl.h, so
that DeferredCode can use scratch scopes.

Bug: v8:7700
Change-Id: I1019a03627f390aa8a69916a227e0007229d63ae
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4178817
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85397}
2023-01-19 13:07:47 +00:00
Nikolaos Papaspyrou
472429e623 [heap] Fix saving the callee-saved registers on stack
This CL reinstates the trampoline for pushing the values of
callee-saved registers on the stack, which is used for stack scanning.
It reintroduces the set of architecture-specific functions
PushAllRegistersAndIterateStack, removed in crrev.com/c/3989143.
The reason for this change is that the simpler architecture-specific
functions SaveCalleeSavedRegisters failed to correctly save the
values of the registers, in the presence of C++ compiler optimizations.

It also removes the stack context, introduced in crrev.com/c/4017512,
and uses again the trampoline for iterating through the stack.

Bug: v8:13257
Change-Id: I9e656a9b3ba6616168602300f2180b4f340593f3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4171639
Commit-Queue: Nikolaos Papaspyrou <nikolaos@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85394}
2023-01-19 12:29:05 +00:00
Michael Lippautz
ba401bb42b [heap] Remove LocalEmbedderHeapTracer
Bug: v8:13207
Change-Id: I54c6f501337a502407f8c137ec59f55a6f8d3416
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4174081
Reviewed-by: Dominik Inführ <dinfuehr@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85358}
2023-01-18 09:36:32 +00:00
Michael Achenbach
2a20b228ef [gcmole] Run gcmole on bots with matching architecture
This does:
- Move gcmole runs to bots with matching arch.
- Update mb_configs to enable gcmole on the bots that run it.
- Add a GN target that extracts some compiler flags from a
ninja file of one of V8's other targets.
- Use the extracted flags in the gcmole script and remove other
hard-coded arch-specific flags.

This is done for DEFINES and includes for now. Other compiler flags
are still a TODO.

Bug: v8:9287
Change-Id: Icba9ce59e0bfffd138d9207b1c2ad64d42bf6a91
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4055629
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85341}
2023-01-17 13:56:18 +00:00
Leszek Swirski
6ca23f83ee Reland^2 "[maglev] Test maglev on Mac Arm64 bots"
This is a reland of commit b791f4f040

More bugs have been fixed.

Original change's description:
> Reland "[maglev] Test maglev on Mac Arm64 bots"
>
> This is a reland of c6e96cf622
>
> Various bugs have been fixed since the revert and we're ready to try
> again.
>
> Original change's description:
> > [maglev] Test maglev on Mac Arm64 bots
> >
> > Also remove unnecessary maglev runs on x64 FYI bots, since maglev runs
> > on the main waterfall's x64 bots already.
> >
> > Bug: v8:7700
> > Change-Id: I5bb23c3ba7696b48f2fe1af4036a3de8c5b1801a
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4128092
> > Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
> > Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#85174}
>
> Bug: v8:7700
> Change-Id: I969e6ae7bd01adb12da0f1240e152232cca00f33
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4156056
> Auto-Submit: Leszek Swirski <leszeks@chromium.org>
> Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
> Commit-Queue: Alexander Schulze <alexschulze@chromium.org>
> Reviewed-by: Victor Gomes <victorgomes@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85275}

Bug: v8:7700
Change-Id: I274d6cac2f39cb4bffcf346649fb9b9676b7d93f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4164681
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Alexander Schulze <alexschulze@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85305}
2023-01-16 09:36:47 +00:00
Junliang Yan
592fa769fe ppc64: [ptr-cage] Enable in BUILD.gn
Change-Id: Iaa905d7ec6e390eb3e963bd934783ac0627a8c1c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4162551
Commit-Queue: Junliang Yan <junyan@redhat.com>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85300}
2023-01-16 01:57:32 +00:00
Andrew Grieve
f7fe84b317 Delete android_assets() target for snapshot.bin
Chromium now defines its own android_assets() rather than using this
target (assets are about how things are packaged, so make more sense
living in embedders).

Bug: chromium:1402705
Change-Id: I95ff828393cec4e1e388776ed2e6be09c67b1e30
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4157274
Auto-Submit: Andrew Grieve <agrieve@chromium.org>
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Adam Klein <adamk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85298}
2023-01-13 21:16:45 +00:00
Victor Gomes
d7d5049cfa [maglev] Create DataViewGetVariableLength builtin
kDataViewGetVariableLength has JS linkage, and so it has a strong
requirement to what should be in the stack and in the registers
(including having a JSFunction for kDataViewGetVariableLength).

These were missing before, which would crash when checking the frame.

Fixed: chromium:1406727
Bug: v8:7700
Change-Id: Iad878cbc06d46403e21162dfdfd3bcd1a2a063d3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4162926
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85284}
2023-01-13 14:59:03 +00:00
Leszek Swirski
d53540be77 Revert "Reland "[maglev] Test maglev on Mac Arm64 bots""
This reverts commit b791f4f040.

Reason for revert: Nope, still not yet: https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Mac%20-%20arm64%20-%20debug/10154/overview

Original change's description:
> Reland "[maglev] Test maglev on Mac Arm64 bots"
>
> This is a reland of c6e96cf622
>
> Various bugs have been fixed since the revert and we're ready to try
> again.
>
> Original change's description:
> > [maglev] Test maglev on Mac Arm64 bots
> >
> > Also remove unnecessary maglev runs on x64 FYI bots, since maglev runs
> > on the main waterfall's x64 bots already.
> >
> > Bug: v8:7700
> > Change-Id: I5bb23c3ba7696b48f2fe1af4036a3de8c5b1801a
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4128092
> > Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
> > Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#85174}
>
> Bug: v8:7700
> Change-Id: I969e6ae7bd01adb12da0f1240e152232cca00f33
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4156056
> Auto-Submit: Leszek Swirski <leszeks@chromium.org>
> Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
> Commit-Queue: Alexander Schulze <alexschulze@chromium.org>
> Reviewed-by: Victor Gomes <victorgomes@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85275}

Bug: v8:7700
Change-Id: I39ff626e799511d79665b4a9e9fb0f8ef7ae1b7f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4164679
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Owners-Override: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85277}
2023-01-13 10:19:32 +00:00
Leszek Swirski
b791f4f040 Reland "[maglev] Test maglev on Mac Arm64 bots"
This is a reland of c6e96cf622

Various bugs have been fixed since the revert and we're ready to try
again.

Original change's description:
> [maglev] Test maglev on Mac Arm64 bots
>
> Also remove unnecessary maglev runs on x64 FYI bots, since maglev runs
> on the main waterfall's x64 bots already.
>
> Bug: v8:7700
> Change-Id: I5bb23c3ba7696b48f2fe1af4036a3de8c5b1801a
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4128092
> Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
> Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85174}

Bug: v8:7700
Change-Id: I969e6ae7bd01adb12da0f1240e152232cca00f33
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4156056
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
Commit-Queue: Alexander Schulze <alexschulze@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85275}
2023-01-13 09:38:20 +00:00
Andrew Grieve
b234e2e747 Remove GN visibility restriction for run_mksnapshot_default
This will allow embedders to build the snapshot file without building
all of v8.

Bug: chromium:1402705
Change-Id: I5049c18a803fd664e10036adcaef93503f013304
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4157273
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Andrew Grieve <agrieve@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85268}
2023-01-12 17:56:21 +00:00
Manos Koukoutos
90c972bb52 [wasm-gc][turbofan] Introduce wasm load elimination
We introduce high-level typed load elimination for wasm. It is based
on CSALoadElimination. It operates on wasm struct.set/get and
array.length operators (with array operations pending). Wasm types are
used to refine the may-alias analysis ran for stores.

Drive-by:
- Type more nodes in wasm-compiler and wasm-gc-operator-reducer.
- Remove an unsafe-cast test which now hits an Unreachable Turbofan
  node.

Bug: v8:7748
Change-Id: I309e4af4d9f9c584e27ff79804a776666b5dc3c1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4146430
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85255}
2023-01-12 14:45: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
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
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
Nico Hartmann
d25d23f54d [turboshaft] Type-based reduction verification
Bug: v8:12783
Change-Id: Icb0ff1ff228acf84c8fd4e5a0896ef6558f57248
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4120260
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85179}
2023-01-10 13:26:47 +00:00
Leszek Swirski
d18fc97189 Revert "[maglev] Test maglev on Mac Arm64 bots"
This reverts commit c6e96cf622.

Reason for revert: Not yet... https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux%20-%20arm64%20-%20sim%20-%20MSAN/47672/overview

Original change's description:
> [maglev] Test maglev on Mac Arm64 bots
>
> Also remove unnecessary maglev runs on x64 FYI bots, since maglev runs
> on the main waterfall's x64 bots already.
>
> Bug: v8:7700
> Change-Id: I5bb23c3ba7696b48f2fe1af4036a3de8c5b1801a
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4128092
> Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
> Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85174}

Bug: v8:7700
Change-Id: Ic9318aacc16086ab5bc31e7c24926121e7096964
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4152250
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Owners-Override: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85177}
2023-01-10 12:39:09 +00:00
Leszek Swirski
c6e96cf622 [maglev] Test maglev on Mac Arm64 bots
Also remove unnecessary maglev runs on x64 FYI bots, since maglev runs
on the main waterfall's x64 bots already.

Bug: v8:7700
Change-Id: I5bb23c3ba7696b48f2fe1af4036a3de8c5b1801a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4128092
Reviewed-by: Alexander Schulze <alexschulze@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85174}
2023-01-10 11:48:50 +00:00
Jakob Linke
6e1b9141ec Reland "[flags,testrunner] Consider readonly flags for conflict detection"
This is a reland of commit ebd933037e

Original change's description:
> [flags,testrunner] Consider readonly flags for conflict detection
>
> Flag conflict detection 1) bails out on incompatible flag values (e.g.
> --jitless and --turbofan) and 2) handles such bailouts transparently in
> the test runner by marking affected tests as OUTCOMES_FAIL.
>
> This CL adds full support for readonly flags to this system, together
> with required additional annotations in variants.py.
>
> Drive-by: assert proper use of v8_enable_slow_dchecks, and add
> support when dcheck_always_on is set.
> Drive-by: introduce has_maglev build variable detection based on
> v8_enable_maglev and use that for .status file annotations.
> Drive-by: protect against unintended overwrites of build variables
> in statusfile.py.
>
> Cq-Include-Trybots: luci.v8.try:v8_linux64_fyi_rel
> Bug: v8:13629,v8:10577
> Change-Id: I04de399139a0490806df8bfee7e75e2ec767b4b5
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4135879
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Reviewed-by: Victor Gomes <victorgomes@chromium.org>
> Commit-Queue: Jakob Linke <jgruber@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85130}

Bug: v8:13629,v8:10577
Change-Id: I49ce322c3fda00a1e1e280d99d2d818772533927
Cq-Include-Trybots: luci.v8.try:v8_linux64_fyi_rel
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4151087
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Auto-Submit: Jakob Linke <jgruber@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85172}
2023-01-10 10:52:11 +00:00
Olivier Flückiger
7f9197883d Reland "Reland "Reland "[static-roots] Enable static roots on supported configurations"""
This is a reland of commit 4bbbb521f4

The issue was that the hash of the static roots table was not stable
across cross-compilation.

Original change's description:
> Reland "Reland "[static-roots] Enable static roots on supported configurations""
>
> This is a reland of commit b247270178
>
> But with static roots disabled on non-external code space builds.
>
>
> Original change's description:
> > Reland "[static-roots] Enable static roots on supported configurations"
> >
> > This is a reland of commit c04ca9cc63
> >
> > Original change's description:
> > > [static-roots] Enable static roots on supported configurations
> > >
> > > The static root values are not actually used yet.
> > >
> > > Bug: v8:13466
> > > Change-Id: I85fc99277c31e0dd4350a305040ab25456051046
> > > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4101880
> > > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> > > Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> > > Cr-Commit-Position: refs/heads/main@{#84850}
> >
> > Bug: v8:13466
> > Change-Id: Id65bb5b19df999dfe930a78993e4bf3343d9f996
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4111641
> > Auto-Submit: Olivier Flückiger <olivf@chromium.org>
> > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> > Commit-Queue: Toon Verwaest <verwaest@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#84991}
>
> Bug: v8:13466
> Change-Id: Id1f55c1cf8d349338fd49f6cb0ed7dc2e1054a72
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4123534
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85037}

Bug: v8:13466
Change-Id: Ifbf26347da293bb465e837a0a914d3f0b393cfad
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4139138
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Auto-Submit: Olivier Flückiger <olivf@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85154}
2023-01-09 16:39:08 +00:00
Nico Hartmann
88eac4b870 [turboshaft] Basic TypedOptimization and new DeadCodeElimination
This CL introduces typed optimizations for Turboshaft, which replaces all operations that produce a constant output (and don't have side effects) by the corresponding constant.

In addition, a new pass for eliminating dead code is introduced that cannot only remove dead operations, but also rewrite branches that are not required into GotoOps.

Drive-by: Introduce -0 as a "special value" for Float32Type and Float64Type to fix a few issues where 0 and -0 have been treated as identical.

Bug: v8:12783
Change-Id: Ia1450ad7a9abb5d58c7d753596ed08a33a73184f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4110993
Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85143}
2023-01-09 13:23:56 +00:00
Leszek Swirski
cebcd8c51b Revert "[flags,testrunner] Consider readonly flags for conflict detection"
This reverts commit ebd933037e.

Reason for revert: Breaks a test: https://logs.chromium.org/logs/v8/buildbucket/cr-buildbucket/8792462319927467985/+/u/OptimizeForSize/CreateIsolateFromReadOnlySnapshot

Original change's description:
> [flags,testrunner] Consider readonly flags for conflict detection
>
> Flag conflict detection 1) bails out on incompatible flag values (e.g.
> --jitless and --turbofan) and 2) handles such bailouts transparently in
> the test runner by marking affected tests as OUTCOMES_FAIL.
>
> This CL adds full support for readonly flags to this system, together
> with required additional annotations in variants.py.
>
> Drive-by: assert proper use of v8_enable_slow_dchecks, and add
> support when dcheck_always_on is set.
> Drive-by: introduce has_maglev build variable detection based on
> v8_enable_maglev and use that for .status file annotations.
> Drive-by: protect against unintended overwrites of build variables
> in statusfile.py.
>
> Cq-Include-Trybots: luci.v8.try:v8_linux64_fyi_rel
> Bug: v8:13629,v8:10577
> Change-Id: I04de399139a0490806df8bfee7e75e2ec767b4b5
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4135879
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Reviewed-by: Victor Gomes <victorgomes@chromium.org>
> Commit-Queue: Jakob Linke <jgruber@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85130}

Bug: v8:13629,v8:10577
Change-Id: I0cb072c6c9f05d92894cc0af83c4d1a28df100d5
Cq-Include-Trybots: luci.v8.try:v8_linux64_fyi_rel
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4147098
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85133}
2023-01-09 08:51:33 +00:00
Jakob Linke
ebd933037e [flags,testrunner] Consider readonly flags for conflict detection
Flag conflict detection 1) bails out on incompatible flag values (e.g.
--jitless and --turbofan) and 2) handles such bailouts transparently in
the test runner by marking affected tests as OUTCOMES_FAIL.

This CL adds full support for readonly flags to this system, together
with required additional annotations in variants.py.

Drive-by: assert proper use of v8_enable_slow_dchecks, and add
support when dcheck_always_on is set.
Drive-by: introduce has_maglev build variable detection based on
v8_enable_maglev and use that for .status file annotations.
Drive-by: protect against unintended overwrites of build variables
in statusfile.py.

Cq-Include-Trybots: luci.v8.try:v8_linux64_fyi_rel
Bug: v8:13629,v8:10577
Change-Id: I04de399139a0490806df8bfee7e75e2ec767b4b5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4135879
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Jakob Linke <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85130}
2023-01-09 07:09:34 +00:00
Clemens Backes
aa5f2e5c43 Revert "[x64] Add support for "cold calls" in hot paths"
This reverts commit 31ccfed461.

Reason for revert: Fails compilation on: https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux64%20-%20cfi%20-%20builder/6527/overview

Original change's description:
> [x64] Add support for "cold calls" in hot paths
>
> This makes (specially annotated) calls to "cold functions" in hot paths
> more efficient by hiding the fact that we are actually calling a
> function here. Clang would otherwise unconditionally spill and reload
> registers that might be clobbered by the call. This would slow down the
> fast path.
>
> This CL allows to reverse priorities here: The fast path can stay fast
> (no spills and loads), but the slow path gets even slower. The inline
> assembly that implements the cold call spills and reloads *all*
> registers, because we do not know which registers are in use in the
> scope where the cold call is being emitted.
>
> I.e. this behaves like a custom calling convention with no caller-saved
> registers.
>
> The `preserve_all` attribute (experimental in clang, and incomplete for
> C++) would also solve this, but it is not production-ready yet (leads to
> crashes of clang and crashes of the generated code).
>
> R=​leszeks@chromium.org
> CC=​​dlehmann@chromium.org
>
> Bug: v8:13565, v8:13570
> Change-Id: I2b54a480da1c689113a67c601c29d73239b0ff2b
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4116584
> Commit-Queue: Clemens Backes <clemensb@chromium.org>
> Reviewed-by: Anton Bikineev <bikineev@chromium.org>
> Reviewed-by: Leszek Swirski <leszeks@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85127}

Bug: v8:13565, v8:13570
Change-Id: I2f5b3343eb372fea13d2c4ab6354f2bc52e2c338
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4145819
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Auto-Submit: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#85128}
2023-01-08 21:03:06 +00:00
Clemens Backes
31ccfed461 [x64] Add support for "cold calls" in hot paths
This makes (specially annotated) calls to "cold functions" in hot paths
more efficient by hiding the fact that we are actually calling a
function here. Clang would otherwise unconditionally spill and reload
registers that might be clobbered by the call. This would slow down the
fast path.

This CL allows to reverse priorities here: The fast path can stay fast
(no spills and loads), but the slow path gets even slower. The inline
assembly that implements the cold call spills and reloads *all*
registers, because we do not know which registers are in use in the
scope where the cold call is being emitted.

I.e. this behaves like a custom calling convention with no caller-saved
registers.

The `preserve_all` attribute (experimental in clang, and incomplete for
C++) would also solve this, but it is not production-ready yet (leads to
crashes of clang and crashes of the generated code).

R=leszeks@chromium.org
CC=​dlehmann@chromium.org

Bug: v8:13565, v8:13570
Change-Id: I2b54a480da1c689113a67c601c29d73239b0ff2b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4116584
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Anton Bikineev <bikineev@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85127}
2023-01-08 18:44:18 +00:00
Michael Lippautz
6eb0a668c2 [heap] Move wrappable extraction logic out of LocalEmbedderHeapTracer
Bug: v8:13207
Change-Id: I5d96454c7335e698ff79572706cf0c16640fdd53
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4136711
Reviewed-by: Anton Bikineev <bikineev@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85100}
2023-01-04 17:04:15 +00:00
Al Muthanna Athamina
d7fa9b66dc [infra] Add TSAN CQ and CI builders with debug/dchecks
Bug: v8:13548
Change-Id: I4d0acf20ec27870540782fc7c2555286b8d7a4c5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4066480
Commit-Queue: Almothana Athamneh <almuthanna@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85074}
2023-01-03 13:20:30 +00:00
Leszek Swirski
0621eaff2c Revert "Reland "Reland "[static-roots] Enable static roots on supported configurations"""
This reverts commit 4bbbb521f4.

Reason for revert: Speculative revert for broken roll.

Original change's description:
> Reland "Reland "[static-roots] Enable static roots on supported configurations""
>
> This is a reland of commit b247270178
>
> But with static roots disabled on non-external code space builds.
>
>
> Original change's description:
> > Reland "[static-roots] Enable static roots on supported configurations"
> >
> > This is a reland of commit c04ca9cc63
> >
> > Original change's description:
> > > [static-roots] Enable static roots on supported configurations
> > >
> > > The static root values are not actually used yet.
> > >
> > > Bug: v8:13466
> > > Change-Id: I85fc99277c31e0dd4350a305040ab25456051046
> > > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4101880
> > > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> > > Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> > > Cr-Commit-Position: refs/heads/main@{#84850}
> >
> > Bug: v8:13466
> > Change-Id: Id65bb5b19df999dfe930a78993e4bf3343d9f996
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4111641
> > Auto-Submit: Olivier Flückiger <olivf@chromium.org>
> > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> > Commit-Queue: Toon Verwaest <verwaest@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#84991}
>
> Bug: v8:13466
> Change-Id: Id1f55c1cf8d349338fd49f6cb0ed7dc2e1054a72
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4123534
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#85037}

Bug: v8:13466
Change-Id: I54a9d68871e0ce2c0faeb49fd9947921073a6873
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4128090
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Owners-Override: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#85055}
2023-01-02 14:20:19 +00:00
Olivier Flückiger
4bbbb521f4 Reland "Reland "[static-roots] Enable static roots on supported configurations""
This is a reland of commit b247270178

But with static roots disabled on non-external code space builds.


Original change's description:
> Reland "[static-roots] Enable static roots on supported configurations"
>
> This is a reland of commit c04ca9cc63
>
> Original change's description:
> > [static-roots] Enable static roots on supported configurations
> >
> > The static root values are not actually used yet.
> >
> > Bug: v8:13466
> > Change-Id: I85fc99277c31e0dd4350a305040ab25456051046
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4101880
> > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> > Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#84850}
>
> Bug: v8:13466
> Change-Id: Id65bb5b19df999dfe930a78993e4bf3343d9f996
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4111641
> Auto-Submit: Olivier Flückiger <olivf@chromium.org>
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Toon Verwaest <verwaest@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#84991}

Bug: v8:13466
Change-Id: Id1f55c1cf8d349338fd49f6cb0ed7dc2e1054a72
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4123534
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Olivier Flückiger <olivf@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85037}
2022-12-29 09:19:11 +00:00
Shu-yu Guo
5c7fca4a61 [string-iswellformed] Implement String#{is,to}WellFormed
Bug: v8:13557
Change-Id: I6fa772c70d8307eca047fd839058279ce244f0e0
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4118066
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/main@{#85002}
2022-12-22 18:04:40 +00:00
Shu-yu Guo
c74a6cd257 Revert "Reland "[static-roots] Enable static roots on supported configurations""
This reverts commit b247270178.

Reason for revert: Breaking Fuchsia build and blocking roll:
https://ci.chromium.org/ui/p/chromium/builders/try/fuchsia-binary-size/186323/overview

Original change's description:
> Reland "[static-roots] Enable static roots on supported configurations"
>
> This is a reland of commit c04ca9cc63
>
> Original change's description:
> > [static-roots] Enable static roots on supported configurations
> >
> > The static root values are not actually used yet.
> >
> > Bug: v8:13466
> > Change-Id: I85fc99277c31e0dd4350a305040ab25456051046
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4101880
> > Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> > Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> > Cr-Commit-Position: refs/heads/main@{#84850}
>
> Bug: v8:13466
> Change-Id: Id65bb5b19df999dfe930a78993e4bf3343d9f996
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4111641
> Auto-Submit: Olivier Flückiger <olivf@chromium.org>
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Toon Verwaest <verwaest@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#84991}

Bug: v8:13466
Change-Id: I9a930649d5c5531f2b8d8472300f6efe3f75ae28
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4122795
Auto-Submit: Shu-yu Guo <syg@chromium.org>
Owners-Override: Shu-yu Guo <syg@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Cr-Commit-Position: refs/heads/main@{#85001}
2022-12-22 17:45:08 +00:00
Olivier Flückiger
b247270178 Reland "[static-roots] Enable static roots on supported configurations"
This is a reland of commit c04ca9cc63

Original change's description:
> [static-roots] Enable static roots on supported configurations
>
> The static root values are not actually used yet.
>
> Bug: v8:13466
> Change-Id: I85fc99277c31e0dd4350a305040ab25456051046
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4101880
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#84850}

Bug: v8:13466
Change-Id: Id65bb5b19df999dfe930a78993e4bf3343d9f996
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4111641
Auto-Submit: Olivier Flückiger <olivf@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/main@{#84991}
2022-12-22 13:06:38 +00:00
Andrew Grieve
fd81728f2e Depend direclty on run_mksnapshot_default rather v8 for v8_external_startup_data_assets
This will prevent building v8 arm code when all we want is the snapshot
file.

Bug: chromium:1402705
Change-Id: If8137e8ef79ff1943c24d5bd71d8374e59bdf561
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4117695
Commit-Queue: Adam Klein <adamk@chromium.org>
Auto-Submit: Andrew Grieve <agrieve@chromium.org>
Reviewed-by: Adam Klein <adamk@chromium.org>
Cr-Commit-Position: refs/heads/main@{#84981}
2022-12-21 18:40:14 +00:00
Nico Hartmann
41628b52fc [turboshaft] Implement %CheckTurboshaftTypeOf intrinsic to test typer
This CL implements a new %CheckTurboshaftTypeOf(e, type_string)
intrinsic allowing tests to express that the expression e is supposed
to have the turboshaft type expressed by type_string eventually during
lowering.

Test that use this intrinsic are verifying implementation details and
are thus somewhat brittle and potentially platform depedent. This
intrinsic is not supposed to be used broadly, but rather to write
some tests that check the precision of turboshaft's new type system.

This intrinsic may be removed once the type system is shipped and gets
coverage in other ways.

Bug: v8:12783
Change-Id: I4cc2582273f3d668601a3203c400a8461b470cac
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4061889
Reviewed-by: Darius Mercadier <dmercadier@chromium.org>
Commit-Queue: Nico Hartmann <nicohartmann@chromium.org>
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/main@{#84894}
2022-12-16 10:10:58 +00:00
Victor Gomes
9c2ac00eb1 [maglev][arm64] Add StringFromCharCode
... and any other node needed to test it.

Bug: v8:7700
Change-Id: Ia37fdcb1db3b6fb986f026696454d443236d011c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4111600
Reviewed-by: Patrick Thier <pthier@chromium.org>
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Patrick Thier <pthier@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/main@{#84893}
2022-12-16 10:06:21 +00:00
jiepan
256546319c [wasm][revec] Add RevectorizePhase in WASM compilation pipeline
Bug: v8:12716

Change-Id: I7ef53709e9757b58951086fc01af6b2eda296b27
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3411357
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Reviewed-by: Deepti Gandluri <gdeepti@chromium.org>
Commit-Queue: Jie Pan <jie.pan@intel.com>
Cr-Commit-Position: refs/heads/main@{#84888}
2022-12-16 07:19:53 +00:00
Jakob Kummerow
2427a3bad1 [wasm] Move i64<->BigInt CallDescriptors to WasmEngine
This stores the CallDescriptors used for i64 <-> BigInt conversion
builtins as process-globals on the WasmEngine, instead of creating
them as temporaries whenever they're needed.
The primary purpose of this change is to simplify the interface to
the Int64Lowering by eliminating its "special case" parameter, in
preparation for moving that lowering to a different point in the
compilation pipeline.
A minor secondary benefit is that this will save a little bit of
(repeated) Zone memory usage.
Bonus change: drop the Int64Lowering from 64-bit builds, where it
isn't used, but was compiled in up to now. This saves ~17 KiB on
Android-arm64 builds.

Change-Id: Ib35d2e0f772110652eb05abd4c42d848108164b9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4110898
Auto-Submit: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/main@{#84884}
2022-12-15 19:40:17 +00:00
Adam Klein
89f82e97d5 Revert "[static-roots] Enable static roots on supported configurations"
This reverts commit c04ca9cc63.

Reason for revert: failures on arm64 msan:
https://ci.chromium.org/ui/p/v8/builders/ci/V8%20Linux%20-%20arm64%20-%20sim%20-%20MSAN/47385/overview

Original change's description:
> [static-roots] Enable static roots on supported configurations
>
> The static root values are not actually used yet.
>
> Bug: v8:13466
> Change-Id: I85fc99277c31e0dd4350a305040ab25456051046
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4101880
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Commit-Queue: Olivier Flückiger <olivf@chromium.org>
> Cr-Commit-Position: refs/heads/main@{#84850}

Bug: v8:13466
Change-Id: Iebf3c4eadb874f7ebc4d9382d454e63a63e9d977
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4107729
Auto-Submit: Adam Klein <adamk@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@{#84852}
2022-12-14 17:55:06 +00:00
Olivier Flückiger
c04ca9cc63 [static-roots] Enable static roots on supported configurations
The static root values are not actually used yet.

Bug: v8:13466
Change-Id: I85fc99277c31e0dd4350a305040ab25456051046
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/4101880
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Olivier Flückiger <olivf@chromium.org>
Cr-Commit-Position: refs/heads/main@{#84850}
2022-12-14 17:00:42 +00:00