Commit Graph

67242 Commits

Author SHA1 Message Date
Clemens Backes
b526d8c29f [liftoff] Use SpillRegisters method consistently
This removes a redundant SpillRegisters implementation in
liftoff-assembler-ia32.h, and uses the existing platform-independent
method in liftoff-assembler.h consistently.

R=ahaas@chromium.org

Bug: v8:11384
Change-Id: I20f0417c248e06557dc1fe8bab834a99257940de
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695399
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72750}
2021-02-15 15:11:58 +00:00
Junliang Yan
7131234f51 s390: [wasm][debug] Implement instrumentation breakpoints
Port 15f3392a7e

Original Commit Message:

    This CL adds support for instrumentation breakpoints in wasm. The
    request for "break on entry" is set on the script, and we need to
keep
    it stored there because there might not be any instances of that
wasm
    module yet. Once instances get created, the flag value is
transferred to
    all instances. The flag stored there is then checked in the function
    prologue in Liftoff debugging code. This ensures that we will stop
at
    the first valid break position in any function within that module.
    Hitting that instrumentation breakpoint will then clear the flag
from
    the script and from all other live instances (in the same isolate).

    A first basic test is contained in this CL. More tests will be added
    later.

R=clemensb@chromium.org, midawson@redhat.com, mfarazma@redhat.com
BUG=
LOG=N

Change-Id: I892eec22aa804abb8b22f3bdd811664f9a2605d6
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695606
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Junliang Yan <junyan@redhat.com>
Cr-Commit-Position: refs/heads/master@{#72749}
2021-02-15 15:05:42 +00:00
Ross McIlroy
f9366e7689 Revert "[build] Enable external flag header with defines"
This reverts commit 1370b29e75.

Reason for revert: Breaks some targets that lack a dependency onto v8-gn.h, see https://crbug.com/1178409.

Original change's description:
> [build] Enable external flag header with defines
>
> Due to some unusual build failures on some trybots,
> v8_generate_external_defines_header was reverted to false. This turns it
> back on but changes the behaviour so that defines are added to the
> command line as well as to the header. Because the generated header
> checks that flags that should be unset are actually unset and flags that
> should be set are either unset or set to 1, this will cause build
> failures on many types of mismatches, although it will not detect where a
> flag is not set on the command line when it is set by the header.
>
> If no further failures show up with this, the hybrid part can be removed
> and the v8-gn.h header can stand on its own.
>
> Bug: v8:11292, v8:11341
> Change-Id: I1deeeebec58f79607e68a28f808649e884810923
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2649041
> Commit-Queue: Dan Elphick <delphick@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#72327}

TBR=mlippautz@chromium.org,delphick@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Bug: v8:11292
Bug: v8:11341
Change-Id: I6cf57014ef8be73c286ad9c5ebf597915f183717
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695400
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72748}
2021-02-15 15:00:53 +00:00
Toon Verwaest
48aa80185d [sparkplug] Drop TODO to inline fast ToString path
We could revisit this later, but right now the direction we're going is
simply keeping fast paths in the called builtins and not generating more
custom inline code.

Bug: v8:11429
Change-Id: I2e3a67e1a2a2ab62e8c785dd9bdf2de3e7215f60
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695405
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72747}
2021-02-15 14:59:28 +00:00
Leszek Swirski
1e42a05ab6 [sparkplug] Collect feedback for ToNumber/ToNumeric
Add (ToNumber|ToNumeric)_Baseline builtins which get the feedback vector
and context from the stack, perform ToNumber/ToNumeric, and update
feedback. These share C++ code with Builtins::kToNumber, but don't call
it directly, as they need to collect feedback as part of the conversion.

Bug: v8:11420, v8:11429
Change-Id: Idca1281004ec27096cbe9204653fdd72386ab52b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692573
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72746}
2021-02-15 14:46:26 +00:00
pthier
0b16593da4 [sparkplug] Remove feedback vector check in verify-heap.
The check was a leftover from a debugging session.
We don't have a feedback vector even though we have baseline code,
e.g. when we share baseline code across realms. In this case
the feedback vector will be allocated upon the first invocation
of the function.

Bug: chromium:1177217
Change-Id: Ia5cde35b0f5d746c2ba64d3ca2083acdfaf286bb
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695396
Auto-Submit: Patrick Thier <pthier@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72745}
2021-02-15 14:43:46 +00:00
Georg Neis
eb2906ae73 [compiler] Don't try to inline allocate large arguments arrays
... otherwise we'd abort at runtime.

Bug: chromium:1178076
Change-Id: Ic7b4a3b27379ec0d42419e2695ab487904eabd72
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695395
Reviewed-by: Michael Stanton <mvstanton@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72744}
2021-02-15 14:41:58 +00:00
Leszek Swirski
053d1e0dce [frames] Add UnoptimizedFrame
Add a new StackFrame class for unoptimized frames (which are either
interpreted or baseline). BaselineFrame becomes a subclass of this
rather than InterpretedFrame, and the various frame constants helpers
are similarly amended.

Bug: v8:11420, v8:11429
Change-Id: I87e9368aef48ef06a39476bf826f379ce1441528
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692208
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72743}
2021-02-15 14:35:04 +00:00
Toon Verwaest
3b0a743ae0 [sparkplug] Remove unused sparkplug_inline_smi flag
Bug: v8:11420
Change-Id: I61182b0b1b3ee8d1ea55df48577077dbd3a36ec5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695397
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72742}
2021-02-15 14:22:38 +00:00
Victor Gomes
b4050a76b6 [baseline] Fix DCHECK in PrologueFillFrame
Change-Id: I8b5c6347ab22d2578bd8975cf10b5508832fd0c0
Bug: v8:11429
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2695398
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72741}
2021-02-15 14:02:00 +00:00
Thibaud Michaud
620afd2387 [wasm][eh] Add metrics for total EH event counts
R=ahaas@chromium.org

Bug: v8:8091
Change-Id: I3d1053b3a11bf81ed2e58098f8429683d4e753ed
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2690597
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Thibaud Michaud <thibaudm@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72740}
2021-02-15 13:28:32 +00:00
Thibaud Michaud
4f7aff2dde [wasm][interpreter][eh] Add delegate
R=clemensb@chromium.org

Bug: v8:8091
Change-Id: Ic01ccc2978642b70c603b1666137ad5f587a152f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2690604
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Thibaud Michaud <thibaudm@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72739}
2021-02-15 13:27:28 +00:00
Kim-Anh Tran
312a3fbec0 [debugger] Re-compile top level functions for SharedFunctionInfos
This adds a call to re-compile top level functions in case
no shared function info could be found. We ran into a bug
where it was not possible to set a breakpoint on the
top-level function since it was already removed by the GC.

Bug: chromium:1137141
Change-Id: I5bb6984825eee8ebcb44619e15b3acf3d118b9bb
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2672181
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Kim-Anh Tran <kimanh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72738}
2021-02-15 13:00:15 +00:00
Thibaud Michaud
04441c4407 [wasm][eh] Misc fixes found by local fuzzing
- Add missing EnsureStackSpace before unpacking the exception (decoder)
- Pop current catch when delegating to the caller (graph builder)
- Mark throw opcode as unconditional jump

R=clemensb@chromium.org

Bug: v8:8091, v8:11449
Change-Id: I702f6a99581476e77d254e2ea91f9c463ceed444
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692688
Commit-Queue: Thibaud Michaud <thibaudm@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72737}
2021-02-15 12:16:30 +00:00
Benedikt Meurer
987a7f4ae4 [inspector] Send type as description for WasmValueObject.
Also block sending "type" as part of the ObjectPreview, but only send
the "value" property. The front-end will be updated to display
WasmValueObject's similar to what we do for wrapper objects (i.e.
StringWrapper and the like). The matching front-end change is still
pending.

Also refactor the WasmValueObject to have dedicated constructors for
the individual types (i32, i64, f32, f64, externref and v128). This
way we can just reuse the existing logic in descriptionForObject()
and we also don't need to store the "type" on the object itself (not
really performance sensitive, but fewer moving parts / things that
can go wrong).

This also addresses the crash in https://crbug.com/1166077#c16 since
the WasmValueObject instances now have a proper JSFunction in their
maps' constructor_or_backpointer slot and are thus able to locate
their creation context. Note that this doesn't generally address
https://crbug.com/1166077 itself, but only the WasmValueObject case.

Screenshot: https://imgur.com/kbd3bix.png
Bug: chromium:1170282, chromium:1071432
Bug: chromium:1159402, chromium:1166077
Change-Id: Iae649cad155efd774cfb1f4eea8cf406e413c03a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692574
Reviewed-by: Philip Pfaffe <pfaffe@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72736}
2021-02-15 11:41:50 +00:00
Clemens Backes
ed02eca6b6 [liftoff][cleanup] Use constant instance parameter register
Instead of looking up the register holding the instance parameter, and
checking that this is the constant we expected, do it the other way
around: Use the constant, and check that this matches the information in
the CallDescriptor. This saves a few instructions on every Liftoff
function compilation.

Drive-by: Move comments, checks, and code emission closer together.

R=thibaudm@chromium.org

Bug: v8:11384
Change-Id: If51425479ded4f271de231479c21e24acefe7f35
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692575
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72735}
2021-02-15 10:49:51 +00:00
Frank Emrich
c91352ed7b [dict-proto] C++ implementation of SwissNameDictionary, pt. 2
This CL is part of a series that adds the C++ implementation of
SwissNameDictionary, a deterministic property backing store based on
Swiss Tables.

This CL adds swiss-hash-table-helpers.h, which contains helpers
that are mostly independent from a particular swiss table
implementation (like SwissNameDIctionary) and can therefore be re-used
by potential other Swiss Table implementations in the future. As a
consequence of that, those helpers are largely taken unchanged from
Abseil.

Bug: v8:11388
Change-Id: I27636731c2166cb10240b847a1d7df0412aa0a33
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2687752
Commit-Queue: Frank Emrich <emrich@google.com>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72734}
2021-02-15 10:45:25 +00:00
Gus Caplan
518b3633de [fastcall] support float return types on x64
Bug: chromium:1052746
Change-Id: I79f58aa3f732f8569654f0d5751ae89a5b6f547d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2686667
Commit-Queue: Georg Neis <neis@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72733}
2021-02-15 10:41:24 +00:00
Victor Gomes
83867ef69e [cleanup] Rename DeoptimizeBaseline to DiscardBaselineCode
- Baseline is to be consider non-optimized code, so for consistency we rename these functions to DiscardBaselineCode.
- Move to debug/, since discarding baseline code is only used by the debugger.
- %DeoptimizeNow and %DeoptimizeFunction are not to be used to tier down from Sparkplug to Ignition

Change-Id: I050607d4d6978907c589e54c57e940979b0a9a15
Bug: v8:11429
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692699
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72732}
2021-02-15 10:40:19 +00:00
Michael Lippautz
6b8ddeb96d Revert "[build] Remove V8_GN_HEADER hybrid mode"
This reverts commit 6beed8d544.

Reason for revert: Breaks some targets that lack a dependency onto v8-gn.h, see https://crbug.com/1178409.


Original change's description:
> [build] Remove V8_GN_HEADER hybrid mode
>
> v8_generate_external_defines_header has been enabled for a couple of
> weeks now with no problems, so this removes the hybrid state where
> V8_GN_HEADER was defined on the command line along with the other
> defines.
>
> Bug: v8:11292, v8:11341
> Change-Id: Ie78f00afe5d1cbca751101a7beb61a18c7d86d04
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2681947
> Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
> Auto-Submit: Dan Elphick <delphick@chromium.org>
> Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#72597}

TBR=mlippautz@chromium.org,delphick@chromium.org

# Not skipping CQ checks because original CL landed > 1 day ago.

No-try: true
Bug: v8:11292
Bug: v8:11341
Bug: chromium:1178409
Change-Id: Ic730ae1bdfe09b13cc0bec96a092822b1874fb0f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692702
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72731}
2021-02-15 10:02:49 +00:00
Michael Achenbach
a7d7c3c37d Whitespace change to trigger bots
Change-Id: I72964af375a5dbaaa8a52df0c042422803aabf75
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692700
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72730}
2021-02-15 09:15:36 +00:00
Michael Achenbach
91e1d6e159 Whitespace change to trigger bots
Change-Id: I0e17d34f7c1350291c40320a1a95ea140a7d937c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692698
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72729}
2021-02-15 08:46:41 +00:00
Andreas Haas
bd03a395a7 [cleanup] Rename Code::has_tagged_params to has_tagged_outgoing_params
This flag name caused misunderstanding in CLs, so it's better to
rename it. With the new name it's clear that this flag is talking about
the outgoing parameters and not about the incoming parameters.

R=jgruber@chromium.org

Bug: v8:11384
Change-Id: Ib371ce4e1eae9a20e61ac2cda67dff48a120144f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2690596
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72728}
2021-02-15 07:16:43 +00:00
v8-ci-autoroll-builder
3146e7f739 Update V8 DEPS.
Rolling v8/build: 6071297..aca4b0d

TBR=v8-waterfall-sheriff@grotations.appspotmail.com

Change-Id: I573fcc7b5ce0804592db9c887c9dba30e8239c9d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2694956
Reviewed-by: 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/master@{#72727}
2021-02-15 03:49:42 +00:00
v8-ci-autoroll-builder
2d052b01f2 Update V8 DEPS.
Rolling v8/build: f306685..6071297

Rolling v8/third_party/aemu-linux-x64: FC12QGMdCPb7lf3NBC6KhslYMLXQvJuO0VQnTiEAKxAC..AFb5I0J9LTvrxaixyFmiKgTuOLLQ3YJ_FAEwRZq1basC

Rolling v8/tools/clang: fea4246..dbe0d80

TBR=v8-waterfall-sheriff@grotations.appspotmail.com

Change-Id: I3803cff0833ff1f71d06d2c2f8bb6315abd2cad1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2694112
Reviewed-by: 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/master@{#72726}
2021-02-14 04:06:34 +00:00
v8-ci-autoroll-builder
07f385d1f2 Update V8 DEPS.
Rolling v8/build: d1fa78c..f306685

Rolling v8/buildtools: 7e85fef..228b1c1

Rolling v8/buildtools/linux64: git_revision:55ad154c961d8326315b1c8147f4e504cd95e9e6..git_revision:dfcbc6fed0a8352696f92d67ccad54048ad182b3

Rolling v8/third_party/aemu-linux-x64: zN4Wm-IY1Nd2ZF2IFXt3kLaxI1cDiwANew4sQzpVRSgC..FC12QGMdCPb7lf3NBC6KhslYMLXQvJuO0VQnTiEAKxAC

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/d2aa569..e4328db

Rolling v8/third_party/depot_tools: 398091b..7386a1e

Rolling v8/tools/clang: 35e7868..fea4246

TBR=v8-waterfall-sheriff@grotations.appspotmail.com

Change-Id: Id8600af539ce4eb95cc8da5da2ba39048c789d1f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2694108
Reviewed-by: 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/master@{#72725}
2021-02-13 03:51:15 +00:00
Ng Zhi An
5e80333806 [wasm-simd][ia32] Implement i64x2.abs
Same code sequence as x64.

Bug: v8:11416
Change-Id: Ibbd4cbf75e10b0ce876d42809d909868fdb86b87
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2686309
Reviewed-by: Bill Budge <bbudge@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72724}
2021-02-12 23:03:30 +00:00
Omer Katz
b804a54bc0 cppgc: Fix ObjectSizeTrait
HeapObjectHeader::GetSize returns object size including
HeapObjectHeader. This is find for our internal usages since we want to
know the actual size consumed by the object.
ObjectSizeTrait should report object size for external users for which
the HeapObjectHeader should be invisible. The sizes returned by the
trait should exclude the header.

Bug: chromium:1056170
Change-Id: I75111b9a3d0d27d0a39df4abdacaa84f1cee3a5a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692689
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Auto-Submit: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72723}
2021-02-12 21:28:40 +00:00
Ross McIlroy
f5305393f0 [Turboprop] Ensure constant operands are only used when allowed.
Previously it was possible for a slot operand to be allocated a
constant operand which is not valid. This CL adds support to the
mid-tier register allocator to keep track of whether spilled operands
can support constant operands, and if not to instead move the constant
to a spill slot at it's definition point, and use that spill slot
instead.

In the process of doing this, we can cleanup the hack that
required constants to always be allocated to a register for
REGISTER_OR_SLOT operator policies.

BUG=chromium:10772,v8:10772,v8:9684

Change-Id: I975ea2c481b45fc0855e175bc6dc2bd0a83f509a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692569
Reviewed-by: Santiago Aboy Solanes <solanes@chromium.org>
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72722}
2021-02-12 20:40:36 +00:00
Ng Zhi An
c5fd776de5 Reland "[wasm-simd][ia32] Implement i64x2 signed compares"
This is a reland of a16add806d.

The fixes are adding disassembly for pcmpgtq and vpcmpgtq.
While fixing also noticed a mistake in assembler for pcmpgtq,
which flipped dst and src.
Also realized that we don't detect SSE4.2, so adding that in.

PS2 contains these changes.

Original change's description:
> [wasm-simd][ia32] Implement i64x2 signed compares
>
> The code sequence is exactly the same as x64.
>
> Bug: v8:11415
> Change-Id: I53ed2723eda29c0a250cff514372a3d45b203476
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2683495
> Reviewed-by: Bill Budge <bbudge@chromium.org>
> Commit-Queue: Zhi An Ng <zhin@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#72637}

Bug: v8:11415
Change-Id: If6a18af2d7de20ac8ad38f94b6d0220769397194
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2688119
Reviewed-by: Bill Budge <bbudge@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72721}
2021-02-12 19:30:01 +00:00
Deepti Gandluri
9ac0fed424 Add zhin@ to src/codegen OWNERS
Change-Id: Ia8eed6717385c7f662677ff8a117b04bf64aa452
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2693287
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Bill Budge <bbudge@chromium.org>
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72720}
2021-02-12 19:28:58 +00:00
Ross McIlroy
d02223f111 [Turboprop] Ensure deopt return point is after branch poisoning
If we return to code after a dynamic map check bailout, ensure the
return point is after the branch poisoning logic, since we might
cause the speculation poisoning register to be cleared otherwise.

Change-Id: Ia003aac16196857218fdfcdc7c2a4c9e8f02b1c9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692576
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Mythri Alle <mythria@chromium.org>
Reviewed-by: Mythri Alle <mythria@chromium.org>
Auto-Submit: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72719}
2021-02-12 18:43:01 +00:00
Junliang Yan
28bda04617 s390: [wasm-gc] Implement optional-depth rtts
Port 3a2ae154f9

Original Commit Message:

    As per the latest wasm-gc spec, rtts now have optional depth, with
    (rtt n type) <: (rtt type) for every depth n. Liftoff compilation
for
    type checks without depth are not supported yet.

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

Change-Id: Iba3d5184be1e69fae805873f832670ed33a41247
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2693326
Reviewed-by: Milad Fa <mfarazma@redhat.com>
Commit-Queue: Junliang Yan <junyan@redhat.com>
Cr-Commit-Position: refs/heads/master@{#72718}
2021-02-12 18:05:06 +00:00
Junliang Yan
5ad83ebe23 s390x: [liftoff] implement rounding for liftoff
Change-Id: Id823d29cc0827ee3df5e3ae0c1bf5efdd3d405cb
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692847
Reviewed-by: Milad Fa <mfarazma@redhat.com>
Commit-Queue: Junliang Yan <junyan@redhat.com>
Cr-Commit-Position: refs/heads/master@{#72717}
2021-02-12 17:08:54 +00:00
Milad Fa
02c80dbff9 PPC/s390: [debug] Fix extra arguments when restarting frame
Port 94b294b349

Original Commit Message:

    Before the removal of the arguments adaptor frame, we could set {actual arguments count} = {formal parameter count} before restarting a live frame to avoid re-entering in the adaptor frame trampoline.
    This does not work anymore, since we now need the correct value of the {actual argument count} to be pushed in the callee frame to be used in its epilogue.

    This CL calls InvokeCall with the correct argument count and the kDontAdaptArgumentsSentinel to skip arguments adaptation.

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

Change-Id: Idc7f712d1860192dc0306366ca77230ed8ad3455
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2693046
Reviewed-by: Junliang Yan <junyan@redhat.com>
Commit-Queue: Milad Fa <mfarazma@redhat.com>
Cr-Commit-Position: refs/heads/master@{#72716}
2021-02-12 17:07:14 +00:00
Benedikt Meurer
a9b6f3f7e6 [inspector][stack-traces] Remove support for "displayName".
As outlined in the design document linked below, we're removing the
support for the non-standard Function.displayName property for the
purpose of Error.stack and DevTools Inspector stack traces. The
motivation here is that the negative lookup is costly, and we have
Function.name as a standard alternative (configurable since ES6 for
exactly this reason).

I dediced to go with JSFunction::GetDebugName(), since
JSFunction::GetName() was confusing in that it'd only get the "name"
property's value if it's a data property, but not with accessors.
JSFunction::GetDebugName() makes it clear that this is really a debug
helper function and might not give you the "name" property value.

Doc: https://bit.ly/devtools-function-displayName-removal
Bug: v8:8742, chromium:1177685, chromium:1077657, chromium:17356
Change-Id: I7717585cbace626174b2f2ed2a4f68f75429eca1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692189
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72715}
2021-02-12 16:56:23 +00:00
Michael Lippautz
695a449032 cppgc: Check ephemerons for unset key
Ephemerons are based around WeakMember which may just be null at the
time the pair is considered for liveness. Bail out of marking for null
keys, as they write barrier would anyways make the value strong when
marking the key.

Bug: chromium:1056170
Change-Id: If8775a370824b88fc67fa479a0c0893985fbf5f4
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692571
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72714}
2021-02-12 16:55:00 +00:00
Thibaud Michaud
0df0d7ab67 [wasm][interpreter][eh] Add implicit rethrow
If the exception tag does not match any of the catch blocks and there is
no catch_all block, it should be rethrown.

R=clemensb@chromium.org

Bug: v8:8091
Change-Id: I8df80f51340fc6265f5ef4308ee3b0f892ee3a90
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2690599
Commit-Queue: Thibaud Michaud <thibaudm@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72713}
2021-02-12 16:22:45 +00:00
Victor Gomes
203a060501 [baseline] Baseline code does not need to be marked for deopt
Change-Id: Ib108067c78e3e47c1ac3738e8c4889fab486dbc9
Bug: v8:11429
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692686
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72712}
2021-02-12 16:07:37 +00:00
Victor Gomes
02e477e341 [cleanup] Create Factory::NewBaselineData
Change-Id: Ia115a8dfd35c935fa4356dd32dcd2e035574f7d1
Bug: v8:11429
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692566
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72711}
2021-02-12 16:02:03 +00:00
Benedikt Meurer
c5cf7db1f2 [api] Deprecate Function::GetDisplayName().
Mark Function::GetDisplayName() as deprecated, scheduled for removal
with M92.

Bug: chromium:1177685, chromium:17356
Change-Id: Iedb905d2d5ab6f8ec95f47bbc982e4f03891fd48
Doc: https://bit.ly/devtools-function-displayName-removal
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2690601
Reviewed-by: Yang Guo <yangguo@chromium.org>
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72710}
2021-02-12 16:00:40 +00:00
Leszek Swirski
cd139abbf8 [sparkplug] Change TODO into a comment
The TODO around range checks for LAST_JS_RECEIVER_TYPE is guarded
by a STATIC_ASSERT, so it can be a comment rather than a TODO.

Bug: v8:11429
Change-Id: Id0d7fc9526448319d89cba43d793accf022a949b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692567
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72709}
2021-02-12 15:46:57 +00:00
Santiago Aboy Solanes
88de5b0f4f [objects] Remove RawFastPropertyAtPut
After after double field unboxing deletion, there was no need for this
method.

Bug: v8:11422
Change-Id: I540ffc80ad21c4cfec62fd8c80a343b8b8eed4bc
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2691047
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72708}
2021-02-12 15:44:37 +00:00
Michael Achenbach
bc403dcb97 [test] Temporarily drop no-sse flags from differential fuzzing
No-Try: true
Bug: v8:11442
Change-Id: I13849c9fa90fa5a971c24694db56a07cc1cccc24
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692570
Auto-Submit: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72707}
2021-02-12 15:29:46 +00:00
Michael Achenbach
76ce5bbb1d [test] Temporarily skip no-sse flags on flag fuzzer.
No-Try: true
Bug: v8:11442
Change-Id: I856470d95cf0b70e98e09a0ce4e8d80377e7a92a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2691052
Auto-Submit: Michael Achenbach <machenbach@chromium.org>
Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72706}
2021-02-12 15:14:48 +00:00
Santiago Aboy Solanes
ee1b6415bb [csa][cleanup] Simplify StoreElementBigIntOrTypedArray
BigInts are considered in the typed array elements kind, there's no need
to special case them.

Bug: v8:6949, v8:11384
Change-Id: I0b231d3ba2ca53236b2005d200b8a208bc57ed0e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2690595
Reviewed-by: Dan Elphick <delphick@chromium.org>
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72705}
2021-02-12 15:12:39 +00:00
Victor Gomes
94b294b349 [debug] Fix extra arguments when restarting frame
Before the removal of the arguments adaptor frame, we could set {actual arguments count} = {formal parameter count} before restarting a live frame to avoid re-entering in the adaptor frame trampoline.
This does not work anymore, since we now need the correct value of the {actual argument count} to be pushed in the callee frame to be used in its epilogue.

This CL calls InvokeCall with the correct argument count and the kDontAdaptArgumentsSentinel to skip arguments adaptation.

Bug: v8:11431, v8:11441
Change-Id: I3698891f07274e8ab95c82b9dd35f53bd78632d9
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2675927
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72704}
2021-02-12 15:08:18 +00:00
Santiago Aboy Solanes
b309b9ae7f [csa][cleanup] TNodify LoadElementAndPrepareForStore's return value
Bug: v8:6949, v8:11384
Change-Id: Ief5a14e5c4327adb8fe9c12fd4af72596a1ba20a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692209
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72703}
2021-02-12 15:03:08 +00:00
Mike Stanton
3393378b3b [compiler] Create canonical handles in JSTypedArrayRef::buffer()
Bug: chromium:1177368, chromium:1177369, v8:7790
Change-Id: Ice0b1b3fbc0b15d2b0b80255b7bb4a8c61f855e3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2692246
Reviewed-by: Georg Neis <neis@chromium.org>
Commit-Queue: Michael Stanton <mvstanton@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72702}
2021-02-12 14:52:35 +00:00
Clemens Backes
15f3392a7e [wasm][debug] Implement instrumentation breakpoints
This CL adds support for instrumentation breakpoints in wasm. The
request for "break on entry" is set on the script, and we need to keep
it stored there because there might not be any instances of that wasm
module yet. Once instances get created, the flag value is transferred to
all instances. The flag stored there is then checked in the function
prologue in Liftoff debugging code. This ensures that we will stop at
the first valid break position in any function within that module.
Hitting that instrumentation breakpoint will then clear the flag from
the script and from all other live instances (in the same isolate).

A first basic test is contained in this CL. More tests will be added
later.

R=thibaudm@chromium.org, bmeurer@chromium.org

Bug: chromium:1151211
Change-Id: I5442d4044934988269becececc03699b850d51d7
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2690588
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72701}
2021-02-12 14:37:16 +00:00