Commit Graph

63641 Commits

Author SHA1 Message Date
Maya Lekova
c63c7f6b80 [test] Disable mjsunit wasm test on all platforms
Bug: v8:9506
Change-Id: Ie343a4d49e769293d8a10d26bcfc3847b9d433ad
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2316109
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Auto-Submit: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69049}
2020-07-24 15:31:52 +00:00
Dominik Inführ
5bb49631b4 [heap] TryAllocatLinearlyAligned doesn't need to take pointer
We don't use the updated size anywhere.

Bug: v8:10315
Change-Id: Iba1fd484fef062d109aa4e5a2c1b40d0a838f80b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2317320
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69048}
2020-07-24 15:27:32 +00:00
Andreas Haas
93b2105fbe [wasm][ia32][liftoff] Implement AtomicCompareExchange
As there are not enough registers on ia32 to execute the platform-
independent code, the CL also adds ia32-specific code to
liftoff-compiler.cc. For this we first retrieve the memory index from
the stack, do a bounds check, and calculate the final address. Only
afterwards we pop all other values from the stack and pass them to the
platform-dependent code.

R=clemensb@chromium.org

Bug: v8:10108
Change-Id: I741266a9523c8b5c46acc0b29817fd143a75752e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2316305
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69047}
2020-07-24 14:16:12 +00:00
Tobias Tebbi
5e39557c2b [flags] Make --young-generation-large-objects readonly
This flag is already baked into the snapshot by enabling more
write-barrier elimination, so changing it at runtime would be a bug.

Change-Id: I3bc73f3c880285ec46b69b0c44934f64b49912ee
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2290856
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69046}
2020-07-24 13:40:32 +00:00
Ross McIlroy
6828e44be0 [TurboProp] Add support for intra-block allocation to fast reg alloc
Adds support for register allocation within a block to the fast
register allocator. Also adds some unittests covering basic
register allocation. No support yet for spill slot allocation,
so functions that spill don't work yet.

BUG=v8:9684

Change-Id: I91d0fc0660d7b65f59235242fd5e3b1a7618d813
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2297467
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69045}
2020-07-24 13:37:22 +00:00
Seth Brenith
de6bc11425 [torque] Show entire stack of inlined macros for Torque assertions
Otherwise, a failure message from a common macro like UnsafeCast<A> is
not particularly meaningful. With this change, the failure message would
show the line number in the top-level builtin and each in-between macro
that resulted in calling UnsafeCast<A>. This does not include plain CSA
macros, only those generated by Torque.

Bug: v8:7793
Change-Id: If0b9b7d2755f579ceacf47eef2440d97ec84a2ff
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2303598
Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69044}
2020-07-24 13:28:42 +00:00
Maya Lekova
93292424ec [turbofan] Cleanup of the fast API calls
This CL includes the following minor cleanups:
 * Renames MakeRaisesException -> MakeWithErrorSupport
 * Removes remaining WrapperTraits related code
 * Makes the public header follow the IWYU principle

Bug: chromium:1052746
Change-Id: I60e730fa15f9bde421a7b6273093c84870666a64
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2316296
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69043}
2020-07-24 12:14:05 +00:00
Ross McIlroy
959288e507 Reland "[TurboProp] Add PendingOperand for use by fast register allocator."
This is a reland of ab7e89f123

Original change's description:
> [TurboProp] Add PendingOperand for use by fast register allocator.
> 
> Adds a pending operand type for use with the fast register allocator.
> These operands chain together multiple operands together, enabling
> the allocator to keep track of multiple pending operands, then
> replace them all with the allocated operand in one go.
> 
> BUG=v8:9684
> 
> Change-Id: I5d8150f3f26549a747a2e89e32e31135e89dff9c
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2292302
> Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#69019}

Bug: v8:9684
Change-Id: I60b902be82b766d98c0f08c9394fcac72d3b914a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315994
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Commit-Queue: Tobias Tebbi <tebbi@chromium.org>
Auto-Submit: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69042}
2020-07-24 11:18:25 +00:00
Clemens Backes
6880a8ddd3 [wasm] Don't automatically remove breakpoints
Out of the four listed reasons, two are obsolete now, since stepping
does not modify the code table any more. The first reason also cannot
happen any more, since removing a breakpoint will also patch the stack
of the isolate, and even if not, removing a breakpoint which is not set
will have no effect (not even a stack rewriting). The same applies for
the last listed reason.

So overall, this code is not needed any more, since it has no effect.

R=thibaudm@chromium.org

Bug: v8:10611
Change-Id: I773ac2515b66e8bf66cb035c315db552024485c3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2316299
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69041}
2020-07-24 10:41:15 +00:00
Manos Koukoutos
fa74cd18fd [wasm-gc][unittests] FunctionBodyDecoderTests for rtt.canon, rtt.sub
Change-Id: I920a7b8aeda0d92eb0301962589a78e0258f33e5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315986
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69040}
2020-07-24 10:15:25 +00:00
Dominik Inführ
189ed62ca6 [heap] Store start of LinearAllocationArea
Right now the allocation observer counters are increased by the LAB size
when allocating the LAB and are decreased later when retiring the rest
of the LAB. In the future counters will be monotonic by increasing them
by the actual used size when retiring a LAB. The start of the LAB is
required for that.

Bug: v8:10315
Change-Id: Ibeca34914f61abcea2a1c1a7b9a042c9be14a589
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2316100
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69039}
2020-07-24 09:36:45 +00:00
Santiago Aboy Solanes
5f4a90aefc [csa][cleanup] Remove ParameterMode from array allocation methods
Remove ParameterMode from:
 * AllocatePropertyArray
 * InitializePropertyArrayLength
 * GetPropertyArrayAllocationSize

Bug: v8:9708, v8:6949
Change-Id: I6b596a52bf06a0e126fa3cf2dd0e4ddedd526c52
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2310354
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Reviewed-by: Mythri Alle <mythria@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69038}
2020-07-24 09:33:54 +00:00
Manos Koukoutos
db6f0440f6 [wasm-gc][tests] Add supertype argument to WASM_RTT_SUB
Change-Id: I6a2ef3d1c46ea57b17234d050b8f0be12e27a197
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315985
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69037}
2020-07-24 09:06:35 +00:00
Igor Sheludko
2f839277dc [zone-compr] Add kCompressGraphZone constant
... that controls whether the TF graph zones should support compression.

Bug: v8:9923
Change-Id: Ifbe237b75e9c92e62eb32b69d6b3b1a818269b83
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2308347
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69036}
2020-07-24 08:50:11 +00:00
Igor Sheludko
06b2e89d2d [zone-compr] Initial support for zone pointer compression
* Added GN flag v8_enable_zone_compression.
* AccountingAllocator supports allocation of zone segments via both
  malloc/free and bounded page allocator. The latter implementation is
  known to be not efficient yet. This issue will be addressed in a
  follow-up CLs.
* Add support_compression flag to Zone constructor/instance.

Bug: v8:9923
Change-Id: I12ee2d85267dd16f455b1b47edc425dc90c57bcf
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2308345
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69035}
2020-07-24 08:27:21 +00:00
Benedikt Meurer
b886e153e9 [inspector] Add internal property to identify detached ArrayBuffers.
This adds an internal property [[IsDetached]] to the inspector preview
of ArrayBuffer instances, which indicates whether the ArrayBuffer was
detached (i.e. transfered via `postMessage`). Previously it was rather
impossible to tell whether an ArrayBuffer was detached, you had to know
that V8 violates the ECMAScript specification and simply sets the
byteLength accessor to 0 upon detaching an ArrayBuffer (but even then it
was still impossible to tell whether that ArrayBuffer wasn't simply an
empty one from the get go).

Before: https://imgur.com/UcOF83c
After: https://imgur.com/WjmTehZ

Fixed: chromium:1109102
Change-Id: I8fb6e2be2fbfe5c62b05dc9d2a0f18378eb4de6c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2316075
Commit-Queue: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Yang Guo <yangguo@chromium.org>
Auto-Submit: Benedikt Meurer <bmeurer@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69034}
2020-07-24 08:12:21 +00:00
Dominik Inführ
734c34e57a [heap] Move GetNextInlineAllocationStepSize() into AllocationCounter
Bug: v8:10315
Change-Id: I124642564d6644f864235c7fa89687e64b1e79c7
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315995
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69033}
2020-07-24 07:50:21 +00:00
Leszek Swirski
198deea289 [compiler] Off-thread finalize each function immediately
Allow "iterative" finalization when off-thread finalization is enabled,
meaning that each compiled function is finalized immediately after
compilation, rather than all functions being first compiled and then
finalized.

This is what we do on the main thread, and it reduces peak Zone memory
usage by being able to discard empty compilation Zones earlier.

One necessary functionality for this was being able to defer the
finalization of asm.js functions until the main thread pause, since
they can't be finalized off-thread -- previously we would just bail
out of doing the off-thread finalization if any inner function was
asm.js.

Bug: chromium:1011762
Change-Id: I21ff69d62eaa93b5ff908624b7115601e36f70f1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2282536
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69032}
2020-07-24 07:39:11 +00:00
Zeynep Cankara
fddd23c0bd [tools] Add link to v8.dev tools and margin fix
This CL adds a link to v8.dev/tools to direct
to all available versions of the tool. Also
fixes margin in between text and card div.

Bug: v8:10664

Change-Id: I8c0b137ffbdd88c4a41fd1ab8038985595056ada
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315988
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Commit-Queue: Zeynep Cankara <zcankara@google.com>
Cr-Commit-Position: refs/heads/master@{#69031}
2020-07-24 07:21:05 +00:00
Milad Farazmand
0f35ee7851 PPC/s390x: Use INT32_MIN s an overflow indicator
To match the behaviour of other architectures, Float32ToInt32
needs to return INT32_MIN as an overflow indicator instead of 0.

Change-Id: I68140daf06f8575fc38fb857033b5c56fec6bb2f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2316398
Reviewed-by: Junliang Yan <jyan@ca.ibm.com>
Commit-Queue: Milad Farazmand <miladfar@ca.ibm.com>
Cr-Commit-Position: refs/heads/master@{#69030}
2020-07-24 07:20:00 +00:00
v8-ci-autoroll-builder
020fcb77a3 Update V8 DEPS.
Rolling v8/build: 7e2f4d2..bdbc779

TBR=machenbach@chromium.org,tmrts@chromium.org,v8-waterfall-sheriff@grotations.appspotmail.com

Change-Id: I8bd1a6c205ca1edae9040e1b3a2fca7efed2fc81
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315053
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@{#69029}
2020-07-24 07:18:50 +00:00
Michael Lippautz
34e211b939 cppgc: Add basic operations for JSMember
The following adds support for JSMember through the existing
GlobalHandles implementation also used for TracedReference.

In addition, JSMember now supports set, clear, copy, move, comparison
and interaction with Local.

Bug: chromium:1056170
Change-Id: Ia50218bcfe4c056b3533a5b14eea954ade1da243
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2310357
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Anton Bikineev <bikineev@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69028}
2020-07-23 20:57:13 +00:00
Clemens Backes
a4ce8e3efd [liftoff][x64] Use cmov for the select opcode
cmov is often much faster than branches (in particular if the branches
cannot be predicted). It also has a much more predictable performance,
and is shorter.
This CL uses cmov on x64 for now. Other platforms (maybe using other
instructions than cmov) can be added later.

R=thibaudm@chromium.org

Bug: v8:10740
Change-Id: Ifab3d570b8eea784376e1f768d6ba3828efcc01a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315978
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69027}
2020-07-23 14:04:02 +00:00
Dominik Inführ
8403d5f1cd [heap] Move allocation_observers_paused_ into AllocationCounter
Bug: v8:10315
Change-Id: Ie36035db0a1a2fa32bfec17eca7cf3ed0c91ca29
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315991
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Dominik Inführ <dinfuehr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69026}
2020-07-23 13:09:22 +00:00
Leszek Swirski
9458d625d2 Reland "[offthread] Add a write lock to the string table"
This is a reland of 6af09b1b02

Relanding without changes after fixing the root cause in
https://crrev.com/c/2315987

Original change's description:
> [offthread] Add a write lock to the string table
>
> Adds an initial implementation of a concurrency support for the string
> table, allowing it to be read without holding a lock, and written to
> while holding a lock.
>
> This is an initial prototype of _roughly_ how the concurrency would
> work; there are still a few holes (e.g. around deserialization). This
> is predominantly to assess the main-thread runtime impact of the more
> complex string table access.
>
> Bug: v8:10729
> Change-Id: I5c6c35e6fca309efd6ee79804c16972aae1ab3ab
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2306804
> Reviewed-by: Toon Verwaest <verwaest@chromium.org>
> Reviewed-by: Igor Sheludko <ishell@chromium.org>
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Commit-Queue: Leszek Swirski <leszeks@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#68985}

Tbr: verwaest@chromium.org,ishell@chromium.org,ulan@chromium.org
Bug: v8:10729
Change-Id: I9ce8882cfbdd40fbe1c7478e171c0785bf2e64d6
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315989
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69025}
2020-07-23 12:34:12 +00:00
Leszek Swirski
185389fae3 [string] Fix casting around external internalized string thinning
When an external string matches and internalized external string, we
want to deduplicate them. As part of that de-duplication, we check if
either a) the internalized string's resource is null (it's freshly
created because the original string was in new space) or b) they point
to the same data (in which case we don't want to dispose of the data).

However, when doing these checks we cast both the initial and the
internalized external string to the same type (one or two byte). So,
if a two-byte string finds a one-byte internalized string with
equivalent data, this cast will fail.

Since we only care about the external string resource being null or
equal to another during the above deduplication, the solution is
casting first to the more general ExternalString type, comparing
resources by address, and only casting to the more specific type
when needed (and we know that the types have to match by other
construction).

Change-Id: Id34a02eb1900d8aa492c030488afaffd0d035454
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315987
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Igor Sheludko <ishell@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69024}
2020-07-23 12:19:27 +00:00
Maya Lekova
c3e651219d Revert "[TurboProp] Add PendingOperand for use by fast register allocator."
This reverts commit ab7e89f123.

Reason for revert: Breaks GCC build - https://ci.chromium.org/p/v8/builders/ci/V8%20Linux64%20gcc%20-%20debug/8442?

Original change's description:
> [TurboProp] Add PendingOperand for use by fast register allocator.
> 
> Adds a pending operand type for use with the fast register allocator.
> These operands chain together multiple operands together, enabling
> the allocator to keep track of multiple pending operands, then
> replace them all with the allocated operand in one go.
> 
> BUG=v8:9684
> 
> Change-Id: I5d8150f3f26549a747a2e89e32e31135e89dff9c
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2292302
> Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
> Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#69019}

TBR=rmcilroy@chromium.org,tebbi@chromium.org

Change-Id: If689956f873f05bcd920090143769a0d4686d804
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:9684
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315992
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69023}
2020-07-23 12:18:24 +00:00
Manos Koukoutos
b7e33d0424 [wasm] Do not inline error code in Pop()
This is to mitigate a binary size increase caused by
https://chromium-review.googlesource.com/c/v8/v8/+/2243215.
This CL reduces binary size by 102kB.

Change-Id: Idd106efab0c2b974b4f90bf6ca3e1c321de06aea
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315984
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69022}
2020-07-23 12:03:02 +00:00
Clemens Backes
4aa185bcb1 [api] Don't provide a default PostJob implementation
The default implementation just returns {nullptr}, which is not a
correct implementation. Since we rely on the implementation of {PostJob}
since https://crrev.com/c/2301933, and embedders can just use
{NewDefaultJobHandle} since https://crrev.com/c/2304812 (backported to
8.5), we should stop providing this dangerous default.

R=ulan@chromium.org

Bug: v8:10723, v8:10740, chromium:1101340
Change-Id: I6e34c584cbed186ddf6cfa4a9c5a7e8caa3b61c8
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315981
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69021}
2020-07-23 11:48:02 +00:00
Clemens Backes
c6be438f51 [d8] Implement Platform::PostJob on all platforms
PostJob is used for wasm compilation since https://crrev.com/c/2301933,
so all platforms need to implement it.

R=ulan@chromium.org

Bug: v8:10745, chromium:1101340
Change-Id: Idf88a1305ab3f33ce3980ca7f82d4fc02b0e2443
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315980
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69020}
2020-07-23 11:32:27 +00:00
Ross McIlroy
ab7e89f123 [TurboProp] Add PendingOperand for use by fast register allocator.
Adds a pending operand type for use with the fast register allocator.
These operands chain together multiple operands together, enabling
the allocator to keep track of multiple pending operands, then
replace them all with the allocated operand in one go.

BUG=v8:9684

Change-Id: I5d8150f3f26549a747a2e89e32e31135e89dff9c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2292302
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69019}
2020-07-23 11:23:12 +00:00
Jakob Gruber
9414d53980 Extract JSFunction code into dedicated files
A small step for a JSFunction, one giant leap for V8.

Tbr: clemensb@chromium.org
Bug: v8:8888
Change-Id: I968bb819763994ec611cde7e502adea30339a387
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315979
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Michael Stanton <mvstanton@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69018}
2020-07-23 11:00:33 +00:00
Anton Bikineev
1a9c73c3c9 cppgc: github: Add initial version of cmake generator
The parser is capable of processing full GN grammar. The generator uses
the visitor and the builder patterns. The visitor handles call expressions
(e.g. target declarations), GN expressions (e.g. is_clang && !is_win),
conditional and assignment statements. Builder is used to generate a
particular output. For example, this CL brings in CMakeBuilder for cmake
generation, but same infrastructure can be reused for generation of
amalgamated sources.

Things that are not yet automatically generated:
1) Automatic generation of config variables (from declare_args).
2) Dependency scanning. Since we only have limited number of targets,
   this is not a big issue at the moment.

Followup CLs will include:
- test targets;
- sample targets.

Bug: v8:10724
Change-Id: I0b31910aca67f0e02ab142b2d35f4338345e7f29
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2306790
Commit-Queue: Anton Bikineev <bikineev@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69017}
2020-07-23 10:15:22 +00:00
Anton Bikineev
e68ff8e2ea cppgc: Add DefaultPlatform and standalone sample
Standalone sample doesn't use libplatform for default platform
implementation. This is needed for Oilpan GitHub mirror, which won't
contain libplatform.

Bug: v8:10724
Change-Id: I2e20ad157263a5073d0ba9ae8a2e211b2fcb35ed
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2310362
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Yang Guo <yangguo@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Commit-Queue: Anton Bikineev <bikineev@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69016}
2020-07-23 09:54:32 +00:00
Zeynep Cankara
938ed34159 [tools][system-analyzer] Emit fileuploadstart event that toggles panels
This CL enables the hide panel functionality
upon uploading a new file. File reader emits
fileuploadstart event when it receives a new file
which hides the panels.

Bug: v8:10644

Change-Id: Ic26cce1a92559efd494f2ef1e32b514897a73324
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2305892
Commit-Queue: Zeynep Cankara <zcankara@google.com>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69015}
2020-07-23 09:06:04 +00:00
Zeynep Cankara
f9dd24a561 [tools][system-analyzer] Decouple the timeline view from map view
This CL decouples the timeline panel view handling
from map panel view handling. Having separate panel view
handling for each panel aims to encapsulate panel behaviours
force panels to emit events rather than depending on other
panels.

Bug: v8:10644, v8:10735

Change-Id: Icd6e8ee8a0e8d1fdbbaaf2754f272300e0499bf7
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2305894
Commit-Queue: Zeynep Cankara <zcankara@google.com>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69014}
2020-07-23 07:00:14 +00:00
v8-ci-autoroll-builder
2b4efe9092 Update V8 DEPS.
Rolling v8/build: 87bba5b..7e2f4d2

Rolling v8/third_party/aemu-linux-x64: z8GNdg7f5KxXikavCn-MhfAAg7LXnterp9s7Cgr5_BoC..-zGqW99um_GNQKURMgzhK855VvGi_CfraQRvXhNduEQC

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/8af044e..b2282fe

Rolling v8/third_party/depot_tools: 6081b23..cebfb4e

TBR=machenbach@chromium.org,tmrts@chromium.org,v8-waterfall-sheriff@grotations.appspotmail.com

Change-Id: I4ff787b8713bdb8d58613682a63146a5d56b09df
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2315041
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@{#69013}
2020-07-23 03:40:24 +00:00
v8-ci-autoroll-builder
5f3d2a2af5 Update V8 DEPS.
Rolling v8/build: e2b8e15..87bba5b

Rolling v8/third_party/aemu-linux-x64: 53Ps2Qo0mizBNjRI9qS90a_RTYhxglcY6H9yccc0ckcC..z8GNdg7f5KxXikavCn-MhfAAg7LXnterp9s7Cgr5_BoC

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/a30bbb6..8af044e

Rolling v8/third_party/depot_tools: 9949ab7..6081b23

Rolling v8/tools/clang: 6412135..2eaa59d

TBR=machenbach@chromium.org,tmrts@chromium.org,v8-waterfall-sheriff@grotations.appspotmail.com

Change-Id: I2fac70741b4b951b4451720ed3908e081b3cfd0f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2314082
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@{#69012}
2020-07-22 19:37:23 +00:00
Michael Achenbach
67cf72dc25 [foozzie] Cluster more .caller issues
This summarizes more dupes of https://crbug.com/1042556

TBR=mslekova@chromium.org

No-Try: true
Bug: chromium:1108048,chromium:1108322
Change-Id: If572b5eeeac9c2750eb1a630dd76490529e60d4a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2314476
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69011}
2020-07-22 19:20:23 +00:00
Ross McIlroy
c092c081c9 [TurboProp] Add initial DefineOutput phase for fast register allocator
Adds the first phase of the fast register allocator, which runs through

the instruction stream and defines a VirtualRegisterData for each
virtual register based on how that virtual register is produced. Also
adds logic to pipeline.cc to allocate and use FastRegistorAllocatorData
for use throughout the fast register allocation phases.

BUG=v8:9684

Change-Id: I2f4533467346d5f3fdf50a0a1fedd7e4082f0187
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2295364
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69010}
2020-07-22 18:05:43 +00:00
Frank Tang
3962a0f788 Fix crash in dateStyle and unsupported nu
Bug: chromium:1107661
Change-Id: I6c55fb74bc009d2af2ae00e34fee9e1ee709a805
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2311352
Commit-Queue: Frank Tang <ftang@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69009}
2020-07-22 17:37:53 +00:00
Seth Brenith
922983dfd3 Profile-guided optimization of builtins
Design doc:
https://docs.google.com/document/d/1szInbXZfaErWW70d30hJsOLL0Es-l5_g8d2rXm1ZBqI/edit?usp=sharing

V8 can already collect data about how many times each basic block in the
builtins is run. This change enables using that data for profile-guided
optimization. New comments in BUILD.gn describe how to use this feature.

A few implementation details worth mentioning, which aren't covered in
the design doc:

- BasicBlockProfilerData currently contains an array of RPO numbers.
  However, this array is always just [0, 1, 2, 3, ...], so this change
  removes that array. A new DCHECK in BasicBlockInstrumentor::Instrument
  ensures that the removal is valid.

- RPO numbers, while useful for printing data that matches with the
  stringified schedule, are not useful for matching profiling data with
  blocks that haven't been scheduled yet. This change adds a new array
  of block IDs in BasicBlockProfilerData, so that block counters can be
  used for PGO.

- Basic block counters need to be written to a file so that they can be
  provided to a subsequent run of mksnapshot, but the design doc doesn't
  specify the transfer format or what file is used. In this change, I
  propose using the existing v8.log file for that purpose. Block count
  records look like this:

  block,TestLessThanHandler,37,29405

  This line indicates that block ID 37 in TestLessThanHandler was run
  29405 times. If multiple lines refer to the same block, the reader
  adds them all together. I like this format because it's easy to use:
  - V8 already has robust logic for creating the log file, naming it to
    avoid conflicts in multi-process situations, etc.
  - Line order doesn't matter, and interleaved writes from various
    logging sources are fine, given that V8 writes each line atomically.
  - Combining multiple sources of profiling data is as simple as
    concatenating their v8.log files together.

- It is a good idea to avoid making any changes based on profiling data
  if the function being compiled doesn't match the one that was
  profiled, since it is common to use profiling data downloaded from a
  central lab which is updated only periodically. To check whether a
  function matches, I propose using a hash of the Graph state right
  before scheduling. This might be stricter than necessary, as some
  changes to the function might be small enough that the profile data is
  still relevant, but I'd rather err on the side of not making incorrect
  changes. This hash is also written to the v8.log file, in a line that
  looks like this:

  builtin_hash,LdaZeroHandler,3387822046

Bug: v8:10470
Change-Id: I429e5ce5efa94e01e7489deb3996012cf860cf13
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2220765
Commit-Queue: Seth Brenith <seth.brenith@microsoft.com>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Tobias Tebbi <tebbi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69008}
2020-07-22 17:12:23 +00:00
Frank Tang
6f356f799b [Intl] Remove flag for fractionalSecondDigits
DateTimeFormat's fractionalSecondDigits shipped in M84, so we
can drop the --harmony_intl_dateformat_fractional_second_digits
flag now.

Bug: v8:10485
Change-Id: If7a1a8599722073d7382635219a6fb46cdc47474
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2311410
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Frank Tang <ftang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69007}
2020-07-22 16:57:43 +00:00
Zeynep Cankara
b1761b06f7 [tools][system-analyzer] Handle IC Panel time filtering and emit events
This CL redesigns the IC Panel to emit events
upon time range selection. IC entry time range specified
from the input fields and entries falling into the selected
time range bubbled up to the App controller. The IC panel
emits events upon selection of a map or a source file location.

Bug: v8:10644

Change-Id: I468dc52b7a6c62dbdee096e80cc6110ceb994f69
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2305893
Commit-Queue: Zeynep Cankara <zcankara@google.com>
Reviewed-by: Sathya Gunasekaran  <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69006}
2020-07-22 16:41:23 +00:00
Maya Lekova
1a5cd1120a [turbofan] Fix effect chain for fast calls
This CL fixes passing the receiver of a fast call as an effect input
only in cases where the opcode supports it.

It also introduces a test for callbacks without fallback support and a
test where ConvertReceiver is not introduced.

Bug: chromium:1052746
Change-Id: I6f396f4c9cbaab7ae915c908a9f805d9770f8946
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2312777
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69005}
2020-07-22 16:07:53 +00:00
Zeynep Cankara
e607d54a0e [tools][system-analyzer] Add map-details and map-transitions
This CL encapsulates map panel behaviour with custom
web components map-details for displaying information
and map-transitions to show map transition tree. The
web components emit/receive events to interact with
the app.

Bug: v8:10644

Change-Id: Ic61c2794ed7ab854ee61fa1e7c8fe9b1c3c31b7e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2305889
Commit-Queue: Zeynep Cankara <zcankara@google.com>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Sathya Gunasekaran  <gsathya@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69004}
2020-07-22 15:41:33 +00:00
Maya Lekova
09de3e9cc9 Revert "[liftoff][tail-call] Add indirect tail calls"
This reverts commit 06bdd8d6b0.

Reason for revert: Speculative revert for arm64 sim CFI - https://ci.chromium.org/p/v8/builders/ci/V8%20Linux%20-%20arm64%20-%20sim%20-%20CFI/1474?

Original change's description:
> [liftoff][tail-call] Add indirect tail calls
> 
> R=​clemensb@chromium.org
> 
> Bug: v8:10693
> Change-Id: Ic71d873bf7099ba671b9db1e87392d54aeebd7cf
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2312096
> Reviewed-by: Clemens Backes <clemensb@chromium.org>
> Commit-Queue: Thibaud Michaud <thibaudm@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#68996}

TBR=clemensb@chromium.org,thibaudm@chromium.org

Change-Id: Ibdc64e20247758fb6bc96b4e5d13406adab968a7
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:10693
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2312786
Reviewed-by: Maya Lekova <mslekova@chromium.org>
Commit-Queue: Maya Lekova <mslekova@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69003}
2020-07-22 15:32:45 +00:00
Jakob Kummerow
ae7b6fcdaf [wasm-gc] Implement br_on_cast
Bug: v8:7748
Change-Id: I6e226888d84a790efc36ac6e7c2a32bc3426bd84
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2308341
Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69002}
2020-07-22 15:05:18 +00:00
Richard Stotz
51b53dd3ee [turbofan][wasm][arm] Improved saturated conversions float32 to int32.
Bug: v8:10720
Change-Id: I7a05bfb3c87c4f0f5516608da5d42fdaff466536
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2304572
Commit-Queue: Richard Stotz <rstz@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69001}
2020-07-22 15:04:13 +00:00
Nico Weber
a6f31733c5 mac/arm64: When cross-building the snapshot, use page size of the target ISA instead of the host.
Bug: chromium:1107945
Change-Id: I0f721ccaf06c7ddaf0213448c29f48f5c57ccc6e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2310575
Auto-Submit: Nico Weber <thakis@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Commit-Queue: Nico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#69000}
2020-07-22 15:03:08 +00:00