Commit Graph

65915 Commits

Author SHA1 Message Date
Leszek Swirski
f0df9b606a [gcmole] Python conversion followup
Fix the python call to sys.executable, and sort imports

Change-Id: I948291e0835c79445108f215e55885fdb2c01052
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560592
Commit-Queue: Michael Achenbach <machenbach@chromium.org>
Auto-Submit: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71423}
2020-11-26 09:40:45 +00:00
Jakob Kummerow
e82a3b4d47 [bigint] Fix possibly-uninitialized leading digit on right shift
Fixed: chromium:1151890
Change-Id: I26f5c76494a9ff3f5a141f381e1c9a543e368571
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2561618
Auto-Submit: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Georg Neis <neis@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71422}
2020-11-26 09:24:15 +00:00
Omer Katz
f8fa0edf16 cppgc: Fix and merge cppgc samples
Both sample are essentially the same up to string constants since
cppgc's default platform started using libplatform.
The only diff between the sample is whether we call
v8::V8::IntializePlatform or cppgc::InitializeProcess.

Drive-by: replace CPPGC_BUILD_IN_V8 with CPPGC_IS_STANDALONE which is
          more descriptive.

Bug: chromium:1056170
Change-Id: I8fdeb59c3345af77f1bccd8b93255ab39b4d3181
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557516
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71421}
2020-11-26 09:12:35 +00:00
Omer Katz
aec92aed6e cppgc: Add owners for cppgc samples
Bug: chromium:1056170
Change-Id: I3779ed504235e3aa3fbecb5f14dd2d43d9907c07
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560201
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Commit-Queue: Omer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71420}
2020-11-26 09:09:55 +00:00
Liu Yu
5b03998e46 [mips][cleanup] Replace all remaining Min/Max uses with std::min/max
Port: 3836aeb039
Change-Id: I2d852f3dbbb74ebd7ee176cdd398cf3e6b207772
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2561422
Auto-Submit: Liu yu <liuyu@loongson.cn>
Reviewed-by: Zhao Jiazhong <zhaojiazhong-hf@loongson.cn>
Commit-Queue: Zhao Jiazhong <zhaojiazhong-hf@loongson.cn>
Cr-Commit-Position: refs/heads/master@{#71419}
2020-11-26 08:01:15 +00:00
v8-ci-autoroll-builder
5da82d0740 Update V8 DEPS.
Rolling v8/build: 29207aa..33f080d

Rolling v8/third_party/depot_tools: 8820ab8..b9a5e83

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

Change-Id: Ic0a241223c26cdfb3ebe26d2588c150cfb95ef7c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560687
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@{#71418}
2020-11-26 03:38:15 +00:00
Shu-yu Guo
a9cc5fe306 Staging relative indexing methods
Bug: v8:10961
Change-Id: I3bd51fa1eaa448e08a99395f30c0322f23677fcf
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2559138
Reviewed-by: Marja Hölttä <marja@chromium.org>
Commit-Queue: Shu-yu Guo <syg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71417}
2020-11-25 22:34:35 +00:00
Milad Fa
8201f02716 PPC: [wasm-simd] Implement Load Transform on PPC LE
Change-Id: I3bb6a6822dea5ce6aa3e12f3137861a2f93bbb68
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560604
Reviewed-by: Junliang Yan <junyan@redhat.com>
Commit-Queue: Milad Fa <mfarazma@redhat.com>
Cr-Commit-Position: refs/heads/master@{#71416}
2020-11-25 18:44:55 +00:00
Dominik Inführ
ff4129195e [heap] Remove unused scopes in GCTracer::BackgroundScope
Scopes aren't used anymore.

Change-Id: Id233974e3b9760560deb85d822218efe9ab9f896
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560199
Auto-Submit: Dominik Inführ <dinfuehr@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71415}
2020-11-25 18:15:55 +00:00
Hannes Payer
d5bafd8180 [heap] Remove unused methods in SemiSpace.
Change-Id: I6146f5e566884b1d24ecb9ee6f154ad581ef2b66
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560722
Commit-Queue: Ulan Degenbaev <ulan@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71414}
2020-11-25 17:36:54 +00:00
Etienne Pierre-Doray
23935d9c9e Revert "Reland "Reland "[Heap]: Convert Sweep to Job"""
This reverts commit 873e5aa32a.

Reason for revert: Flaky cctest/test-incremental-marking/IncrementalMarkingUsingTasks

Original change's description:
> Reland "Reland "[Heap]: Convert Sweep to Job""
>
> This is a reland of b16c7e5b1c
>
> Issue: ShouldYield is called multiple time.
> Fix: ConcurrentSweepSpace returns false if not done (yielding), to avoid
> calling it again.
>
> Issue: failing test-streaming-compilation
> Safe to reland after
> https://chromium-review.googlesource.com/c/v8/v8/+/2507379
>
> Original change's description:
> > Reland "[Heap]: Convert Sweep to Job"
> >
> > This is a reland of 795c0b1c7b
> > Reason for revert:
> > TSAN failures https://ci.chromium.org/p/v8/builders/ci/V8%20Linux64%20TSAN/33884
> > Safe to reland as-is with fix to EagerUnmappingInCollectAllAvailableGarbage
> > https://chromium-review.googlesource.com/c/v8/v8/+/2502809
> >
> > Original change's description:
> > > [Heap]: Convert Sweep to Job
> > >
> > > max concurrency is inferred from queue size for OLD_SPACE & MAP_SPACE.
> > > Extra Sweeper::TearDown() in MarkCompactCollector::TearDown() is needed
> > > to cancel job.
> > >
> > > Change-Id: Iafba7d7d24e8f6e5c5a1d5c0348dea731f0ac224
> > > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2480783
> > > Commit-Queue: Etienne Pierre-Doray <etiennep@chromium.org>
> > > Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> > > Cr-Commit-Position: refs/heads/master@{#70767}
> >
> > Change-Id: Id9a5baceed4664f53da39597af56a2067e4f3c6f
> > Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2502808
> > Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> > Commit-Queue: Etienne Pierre-Doray <etiennep@chromium.org>
> > Cr-Commit-Position: refs/heads/master@{#70845}
>
> Change-Id: I32de9faebdbd2f7f6d7f9a9525871fc691fb3f2c
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2507378
> Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
> Commit-Queue: Etienne Pierre-Doray <etiennep@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#71347}

TBR=ulan@chromium.org,etiennep@chromium.org

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

Issue: ShouldYield is called multiple time.
Issue: failing test-streaming-compilation
Change-Id: Ic82221d118d7a1f6ea98021e03f4d4b95368b01c
Bug: v8:11198
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2561198
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71413}
2020-11-25 17:29:44 +00:00
Clemens Backes
77c83be45f [inspector] Remove functionality to dump function tables
Function tables have been removed from the scope object in
https://crrev.com/c/2507696, hence the code for printing them is dead
now.

R=bmeurer@chromium.org

Change-Id: Ib36fb314ae54468239737f100a6594d8d2031218
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557982
Reviewed-by: Benedikt Meurer <bmeurer@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71412}
2020-11-25 16:58:54 +00:00
Clemens Backes
0854d353fb Reland: [wasm][memory64] Decode memory offset as 64-bit LEB
After preparing Liftoff, TurboFan, and the interpreter for this change,
we now store the memory offset as uint64_t. {LoadLane} and {StoreLane}
were added after the TurboFan refactoring, so those two are adapted
similar to the other memory operations.

TBR=manoskouk@chromium.org

Bug: v8:10949
Cq-Include-Trybots: luci.v8.try:v8_win64_msvc_rel_ng
Change-Id: I8f3084c21a7d99f72df1bc18c2b507c4e84570cd
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560720
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71411}
2020-11-25 16:21:35 +00:00
Vasili Skurydzin
5053751bc0 aix: Return false from ThreadTicks::IsSupported() in PASE
Change-Id: I63446404789a33b97db2bacee2faf3a04e137ed5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558973
Reviewed-by: Milad Fa <mfarazma@redhat.com>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Vasili Skurydzin <vasili.skurydzin@ibm.com>
Cr-Commit-Position: refs/heads/master@{#71410}
2020-11-25 16:15:25 +00:00
Leszek Swirski
f4085c8e70 Revert "[wasm] Reduce job priority once baseline compilation finishes"
This reverts commit cf9a28b6ae.

Reason for revert: TSAN failures: https://ci.chromium.org/p/v8/builders/ci/V8%20Linux64%20TSAN/34374?

Original change's description:
> [wasm] Reduce job priority once baseline compilation finishes
>
> This Cl changes the priority of baseline compilation from kUserVisible
> to kUserBlocking. Once baseline compilation finishes, the priority is
> reduced to kUserVisible. The reason for using kUserBlocking is that
> thereby TurboFan compilation cannot block Liftoff compilation anymore.
> Additionally, kUserBlocking is quite appropriate, as the initial
> compilation does block a whole section of a web app from execution.
>
> R=​clemensb@chromium.org
>
> Bug: v8:11088
> Change-Id: Ifde42d20f36d4c0a5122b0008311ccdffbb60e48
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2519559
> Commit-Queue: Andreas Haas <ahaas@chromium.org>
> Reviewed-by: Clemens Backes <clemensb@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#71404}

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

Change-Id: I9a975c4c43189015491b08d3a98de991d8167daf
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:11088
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560200
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71409}
2020-11-25 16:06:47 +00:00
Vasili Skurydzin
83edea07fb aix: AmountOfPhysicalMemory test unsupported on PASE, skip on Aix
platform

Change-Id: I644970a5dfe3794d2b9c90719b3a1b2b87c2f5e3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558971
Reviewed-by: Milad Fa <mfarazma@redhat.com>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Commit-Queue: Vasili Skurydzin <vasili.skurydzin@ibm.com>
Cr-Commit-Position: refs/heads/master@{#71408}
2020-11-25 15:50:34 +00:00
Michael Lippautz
e881304978 cppgc: Refactor write barriers
Refactor write barriers and split calls, as e.g. DijkstraWriteBarrier
also contained logic for recording slots (cards) for the young
generation.

The new API exposes the following:
- GetWriteBarrierType(): Retrieving the type of barrier that must be
  emitted;
- DijkstraWriteBarrier(), DijkstraWriteBarrierRange(): Dijkstra-style
  write barriers;
- SteeleWriteBarrier(): Steele-style write barrier;
- GenerationalBarrier(): Barrier for recording slots when using
  multiple generations;

Compilers running with -O3 optimize the DijkstraWriteBarrierPolicy
down to the same instructions as before the split.

Change-Id: If68839cc6357b2f568986c9ce8ca753b1e96a70a
Bug: chromium:1056170
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557514
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71407}
2020-11-25 15:29:24 +00:00
Andreas Haas
73a35c3555 [wasm][generic-wrapper] Fix number of parameters popped off the stack
In the generic wrapper we popped the wrong number of parameters off the
stack. We always popped the number of parameters needed by the generic
wrapper, according to the signature. The correct number though is
max(parameters provide, parameters needed).

R=victorgomes@chromium.org, thibaudm@chromium.org
CC=vkont@google.com

Bug: v8:10982
Change-Id: If9b8d4dbe093eb6df08ddf9f3594d5c60b9be33f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558317
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Reviewed-by: Victor Gomes <victorgomes@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71406}
2020-11-25 15:27:14 +00:00
Mythri A
7f15f3e7ad [turboprop] Don't use concurrent inlining for TurboFan compilations
With concurrent inlining, the inlining phase happens on the background
thread and the data needed for the inlining phase is serialized on
the main thread. The serialization phase tries to gather data about
functions called which is sometimes more expensive than inlining phase
itself. So it's better not to use concurrent inlining for TurboFan
compilations when tiering up from Turboprop to TurboFan. Turboprop
compilations don't inline and hence it is OK to continue using
concurrent inlining for Turboprop compilations.

Bug: v8:9684
Change-Id: Ib529905213fa7f0df84ee52218adc27f7c219f60
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557504
Commit-Queue: Mythri Alle <mythria@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71405}
2020-11-25 15:15:24 +00:00
Andreas Haas
cf9a28b6ae [wasm] Reduce job priority once baseline compilation finishes
This Cl changes the priority of baseline compilation from kUserVisible
to kUserBlocking. Once baseline compilation finishes, the priority is
reduced to kUserVisible. The reason for using kUserBlocking is that
thereby TurboFan compilation cannot block Liftoff compilation anymore.
Additionally, kUserBlocking is quite appropriate, as the initial
compilation does block a whole section of a web app from execution.

R=clemensb@chromium.org

Bug: v8:11088
Change-Id: Ifde42d20f36d4c0a5122b0008311ccdffbb60e48
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2519559
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71404}
2020-11-25 15:13:05 +00:00
Sylvain Defresne
c23d93c472 [ios] Remove override of ios_use_goma_rbe gn variable
The gn variable ios_use_goma_rbe is ignored since the CL
https://crrev.com/c/2555117 landed, so stop overriding
it on the bots (it is now always enabled which is what
the bots want).

Bug: none
Change-Id: Iaa085dd1fd0559a41372744ed4c4491c4b5d9908
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558218
Reviewed-by: Michael Achenbach <machenbach@chromium.org>
Commit-Queue: Sylvain Defresne <sdefresne@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71403}
2020-11-25 15:06:54 +00:00
Hannes Payer
a549ff5648 [heap] Allocation buffer parking in NewSpace.
Change-Id: If01a247f2bae3c90708f9f8355325fa5b7113913
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560196
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Hannes Payer <hpayer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71402}
2020-11-25 14:17:34 +00:00
Eric Seckler
ff8258bcae cppgc: Fix chromium build with v8_use_perfetto.
The dependency on v8_tracing supplies include paths &
dependencies on the tracing library when built with
v8_use_perfetto.

This is an attempt to fix the linux-perfetto-rel builder [1], which is
currently erroring:

FAILED: obj/v8/cppgc_base/sweeper.o
/b/s/w/ir/cache/goma/client/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF...(too long)
In file included from ../../v8/src/heap/cppgc/sweeper.cc:24:
In file included from ../../v8/src/heap/cppgc/stats-collector.h:17:
In file included from ../../v8/src/heap/cppgc/trace-event.h:9:
In file included from ../../v8/src/tracing/trace-event.h:12:
gen/third_party/perfetto/protos/perfetto/trace/track_event/debug_annotation.pbzero.h:9:10: fatal error: 'perfetto/protozero/message.h' file not found
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

[1] https://ci.chromium.org/p/chromium/builders/ci/linux-perfetto-rel

Bug: chromium:1056170
Change-Id: Id5a382d472139f7abe5ead67ec6eed2f8395e6b5
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2560257
Commit-Queue: Eric Seckler <eseckler@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Reviewed-by: Michael Lippautz <mlippautz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71401}
2020-11-25 12:47:04 +00:00
Manos Koukoutos
1010724ed2 [wasm] Use BrOrRet in Interface for conditional branches
The logic to detect if a 'br' instruction is a branch or a return was
duplicated in function-body-decoder-impl.h and in both interfaces.
Apart from code duplication, this structure also made it hard to
implement planned compiler improvements.
This CL removes this duplication by upgrading BrOrRet (that already
existed in both Liftoff and Turbofan interfaces) to an interface
function and using it for unconditional branches.

Change-Id: Ia04952cce621335268fc40ef9544a99b61dc7da3
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557515
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71400}
2020-11-25 12:34:54 +00:00
Clemens Backes
46be2f2696 [wasm][debug] Simplify stepping interface
This is a minor refactoring before fixing actual issues.

1) The update of the {per_isolate_data_} is moved into
   {FloodWithBreakpoints}, which is already taking the mutex.
2) The {PrepareStep} method takes a {WasmFrame*} directly instead of its
   ID. In most cases, this prevents the creation of an additional stack
   frame iterator.

R=thibaudm@chromium.org

Bug: chromium:1145176
Change-Id: I1a6cd15550bbb4ef78ba522427bed1c23185569e
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558318
Reviewed-by: Simon Zünd <szuend@chromium.org>
Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71399}
2020-11-25 12:19:24 +00:00
Leszek Swirski
f1e97412a5 [offthread] Fix StringTable/WriteToFlat performance
Pass the Isolate/LocalIsolate through to StringTable matchers and
WriteToFlat, so avoid having to get the Isolate via the String, and to
avoid locking on the main thread entirely. This allows us to remove the
String overload of the SharedStringAccessGuardIfNeeded constructor
entirely, to avoid this anti-pattern in the future.

Bug: chromium:1146972
Change-Id: I53bba126b105e1c9629d6e64d8bb574e62e3ad45
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557988
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Santiago Aboy Solanes <solanes@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71398}
2020-11-25 12:13:54 +00:00
Santiago Aboy Solanes
03a940ebee [config] Add [[nodiscard]] as an attribute to v8config
This allows us to assert at compile time that a class instance is
assigned, which is particularly useful for Guard classes.

Change-Id: Id16b2bb70d29573566e821c908c1169d49ec57af
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2552415
Commit-Queue: Santiago Aboy Solanes <solanes@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71397}
2020-11-25 11:49:05 +00:00
Milad Fa
f290177fb4 PPC: [cleanup] Replace all remaining Min/Max uses with std::min/max
Port 3836aeb039

Original Commit Message:

    Apart from removing Min and Max (utils.h), this is mostly a renaming.

    In a few cases I had to add a cast. In a bunch of cases I had to use
    initializer lists to force call-by-value for static member constants
    because call-by-reference wouldn't compile (like in the previous CL).
    In a few places I used initializer lists in place of nested min/max
    operations.

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

Change-Id: Iecb43c19b8e16721e942553d7d811daf74bedc02
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557570
Commit-Queue: Georg Neis <neis@chromium.org>
Reviewed-by: Georg Neis <neis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71396}
2020-11-25 08:49:53 +00:00
Michael Lippautz
e3d6433ba8 cppgc: Expose feature defines to embedders
Bug: chromium:1056170
Change-Id: I303715630c79213d5b0dc34ff7107e8ffa973539
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557991
Commit-Queue: Michael Lippautz <mlippautz@chromium.org>
Reviewed-by: Omer Katz <omerkatz@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71395}
2020-11-25 08:16:02 +00:00
Zhi An Ng
c0c6078aef [wasm-simd][ia32] Prototype load lane
Prototype v128.load{8,16,32,64}_lane on IA32 (stores will come later).

This is pretty similar to x64 version, except that there is no signal
handler for OOB access, so kProtected is not a valid access mode.

Left some TODOs for myself to merge the new instruction codes
(kIA32Pinsrb) with the replace lane Wasm instructions.

Bug: v8:10975
Change-Id: I5c9f9a45e2e7f06e8fab4a28cdfe1857ccc35880
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557063
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Reviewed-by: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71394}
2020-11-25 06:28:02 +00:00
Zhi An Ng
063ee2349a Revert "[wasm-simd][arm] Prototype i64x2.bitmask"
This reverts commit 21e479441e.

Reason for revert: Broke build https://ci.chromium.org/p/v8/builders/ci/V8%20Arm%20-%20debug/16872?

Original change's description:
> [wasm-simd][arm] Prototype i64x2.bitmask
>
> Cleanup to simulator to remove repetitive logic to get instruction
> fields.
>
> Bug: v8:10997
> Change-Id: I01f0b99f85788b41e4cab505fc94362d637c396f
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2554256
> Commit-Queue: Zhi An Ng <zhin@chromium.org>
> Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
> Reviewed-by: Bill Budge <bbudge@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#71391}

TBR=bbudge@chromium.org,jkummerow@chromium.org,v8-arm-ports@googlegroups.com,zhin@chromium.org

Change-Id: I15513cc5923db7d189d08a9faf5051e57af7190b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:10997
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558260
Reviewed-by: Zhi An Ng <zhin@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71393}
2020-11-25 04:55:56 +00:00
v8-ci-autoroll-builder
62f64204d6 Update V8 DEPS.
Rolling v8/build: 356ef25..29207aa

Rolling v8/third_party/aemu-linux-x64: qDJOg4W2RuPZ92H6d33I9kLLWjqfYuMr_gFsPRodSQAC..b5ckZyVJ3XwwvnxV2J_ybKfLyiHfOj81r9Llym22_UsC

Rolling v8/third_party/catapult: https://chromium.googlesource.com/catapult/+log/a629d81..ae003f5

Rolling v8/third_party/depot_tools: 260eb0f..8820ab8

Rolling v8/tools/luci-go: git_revision:6cbe3f56e9f00b8f65eae21f01838a8b58191a47..git_revision:1a022d3a4c50be4207ee93451255d71896416596

Rolling v8/tools/luci-go: git_revision:6cbe3f56e9f00b8f65eae21f01838a8b58191a47..git_revision:1a022d3a4c50be4207ee93451255d71896416596

Rolling v8/tools/luci-go: git_revision:6cbe3f56e9f00b8f65eae21f01838a8b58191a47..git_revision:1a022d3a4c50be4207ee93451255d71896416596

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

Change-Id: I56abc6880884805075c73201c3c871c1ceedf284
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558979
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@{#71392}
2020-11-25 03:51:32 +00:00
Zhi An Ng
21e479441e [wasm-simd][arm] Prototype i64x2.bitmask
Cleanup to simulator to remove repetitive logic to get instruction
fields.

Bug: v8:10997
Change-Id: I01f0b99f85788b41e4cab505fc94362d637c396f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2554256
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Reviewed-by: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71391}
2020-11-25 03:35:42 +00:00
Zhi An Ng
9e13573e9d [ia32] Small cleanup of repetitive modrm decoding
Bug: v8:11074
Change-Id: I41a62490b3abe9ff00905fd9ea7e4bfff5f23a48
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557064
Reviewed-by: Bill Budge <bbudge@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71390}
2020-11-25 02:59:02 +00:00
Zhi An Ng
89314801c0 [cleanup][parsing] Remove uses of DISALLOW_COPY_AND_ASSIGN
Bug: v8:11074
Change-Id: I01ffd94290aa5deafa0953a86ff555147b813bf4
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557069
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71389}
2020-11-25 02:07:32 +00:00
Zhi An Ng
fc61c38add [cleanup] Remove uses of DISALLOW_COPY_AND_ASSIGN
Also remove a comment referring to using the macro.

Bug: v8:11074
Change-Id: Ib56a0360b28812833b372738f4956ef41c59a97b
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557058
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Zhi An Ng <zhin@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71388}
2020-11-25 01:46:32 +00:00
Daniel Clark
f588c889a4 [modules] Add refactored API to get ModuleRequests and expose import assertions
This change refactors the v8.h API as discussed in
https://docs.google.com/document/d/1yuXgNHSbTAPubT1Mg0JXp5uTrfirkvO1g5cHHCe-LmY/edit#heading=h.q0c9h4p928mn
such that a v8::Module exposes module requests as a FixedArray of
ModuleRequest objects, which can then be used to obtain their module
specifier and source code offset.  This replaces the old functions that
passed back individual specifier Strings and Locations via repeated
calls to getters that take an index.  These are marked as deprecated.

The new ModuleRequest interface includes a getter for an
ImportAssertions FixedArray, which will contain the import assertions
for the request if --harmony-import-assertions is set, and will be
empty otherwise.

One notable change here is that the APIs now return source code offsets
rather than v8::Locations.  The host must then call the new
Module::SourceOffsetToLocation to convert these offsets into line/column
numbers. This requires a bit more back-and-forth, but allows the host to
defer the cost of converting from source offset to line/column numbers
until an error needs to be reported, potentially skipping the work
altogether.

Bug: v8:10958
Change-Id: I181639737c701e467324e6c781aa4d7bdd87ae8c
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2545577
Commit-Queue: Dan Clark <daniec@microsoft.com>
Reviewed-by: Camillo Bruni <cbruni@chromium.org>
Reviewed-by: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71387}
2020-11-24 21:16:02 +00:00
Sara Tang
9750bda3df (Step 3 of 3): Prepping Wasm events in the Recorder interface
Removed wall_clock_time_in_us field.

Bug: v8:11109
Change-Id: Ib3efa74fc741b793ef064c1d12ca1797be3a10c1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2550280
Reviewed-by: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Commit-Queue: Sara Tang <sartang@microsoft.com>
Cr-Commit-Position: refs/heads/master@{#71386}
2020-11-24 21:02:32 +00:00
Leszek Swirski
52cfffde97 [utils] Add CompareCharsEqual
Add a CompareCharsEqual to complement CompareChars, where we only care
about equality and not ordering. For such cases, we can memcmp for two-
byte as well as one-byte strings (we can't for CompareChars because the
ordering would be incorrect on little-endian systems).

Replace uses of CompareChars that only compare the result against zero,
with CompareCharsEqual. Additionally, use some template magic to
simplify the "make unsigned" operation in these methods.

Change-Id: I0d65bee81b98d3938d15daa4af331c90558ea84f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557980
Commit-Queue: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Igor Sheludko <ishell@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71385}
2020-11-24 20:10:32 +00:00
Camillo Bruni
546939fe77 [api] Simplify ScriptOrigin
- Use C++ primitives (int, bool) for the ScriptOrigin constructor.
- Deprecate the old accessors and constructor

Bug: v8:11195
Change-Id: I739edd6b4c58e19a8a16ddce863eea14ec933697
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2555005
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71384}
2020-11-24 19:51:42 +00:00
Bill Budge
52892c1aef Revert "[wasm][memory64] Decode memory offset as 64-bit LEB"
This reverts commit 44efa00b04.

Reason for revert: Breaks MSVC with warning as error:
https://ci.chromium.org/p/v8/builders/ci/V8%20Win64%20-%20msvc/15903

Original change's description:
> [wasm][memory64] Decode memory offset as 64-bit LEB
>
> After preparing Liftoff, TurboFan, and the interpreter for this change,
> we now store the memory offset as uint64_t. {LoadLane} and {StoreLane}
> were added after the TurboFan refactoring, so those two are adapted
> similar to the other memory operations.
>
> R=​manoskouk@chromium.org
>
> Bug: v8:10949
> Change-Id: Iba66ce448904e23b152fcb8612d171124e615473
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2555006
> Commit-Queue: Clemens Backes <clemensb@chromium.org>
> Reviewed-by: Manos Koukoutos <manoskouk@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#71382}

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

Change-Id: Ia0f46a0b6fd2102a61c7664d7cdd86a2cf8ddb24
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:10949
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558752
Reviewed-by: Bill Budge <bbudge@chromium.org>
Commit-Queue: Bill Budge <bbudge@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71383}
2020-11-24 19:10:14 +00:00
Clemens Backes
44efa00b04 [wasm][memory64] Decode memory offset as 64-bit LEB
After preparing Liftoff, TurboFan, and the interpreter for this change,
we now store the memory offset as uint64_t. {LoadLane} and {StoreLane}
were added after the TurboFan refactoring, so those two are adapted
similar to the other memory operations.

R=manoskouk@chromium.org

Bug: v8:10949
Change-Id: Iba66ce448904e23b152fcb8612d171124e615473
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2555006
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71382}
2020-11-24 18:00:41 +00:00
Michael Lippautz
3b82f4c686 cppgc: Expose write barriers
Exposes an opaque handle for uniformly (cppgc and V8) referring to an
instance of a heap.

Exposes a set of raw write barriers for advances embedders through
subtle::HeapConsistency which is a mirror into write barrier internals.
The following barriers are exposed:
- DijkstraWriteBarrier: Regular Dijkstra-style write barrier (add to
  wavefront);
- DijkstraWriteBarrierRange: Same as DijkstraWriteBarrier but
  operating on a range of slots that are composite (inlined) objects;
- SteeleWriteBarrier: Regular Steele-style write barrier (retreating
  wavefront);

Change-Id: Ib5ac280204686bf887690f72df1cdb506ea6ef70
Bug: chromium:1056170
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2554601
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@{#71381}
2020-11-24 17:41:11 +00:00
Georg Neis
3836aeb039 [cleanup] Replace all remaining Min/Max uses with std::min/max
Apart from removing Min and Max (utils.h), this is mostly a renaming.

In a few cases I had to add a cast. In a bunch of cases I had to use
initializer lists to force call-by-value for static member constants
because call-by-reference wouldn't compile (like in the previous CL).
In a few places I used initializer lists in place of nested min/max
operations.

Bug: v8:11074
Change-Id: I53a5411be6334ff41e7a8517e6b87fb46f14d086
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2545523
Commit-Queue: Georg Neis <neis@chromium.org>
Reviewed-by: Hannes Payer <hpayer@chromium.org>
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Ulan Degenbaev <ulan@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71380}
2020-11-24 17:32:01 +00:00
Milad Fa
957516489f PPC/s390: [wasm][liftoff] Don't reserve space for the stack marker twice
Port 2180e20f49

Original Commit Message:

    The total frame size returned by GetTotalFrameSize includes the frame
    marker. However, the frame marker is pushed on the stack with a push
    instruction. Therefore it is not needed to allocate memory for it again
    on the stack. This CL therefore reduces the memory allocated on the
    stack by the size of the frame marker.

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

Change-Id: I76e259d54703265fcf1a84857365997af008e16a
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2558257
Reviewed-by: Junliang Yan <junyan@redhat.com>
Commit-Queue: Milad Fa <mfarazma@redhat.com>
Cr-Commit-Position: refs/heads/master@{#71379}
2020-11-24 16:36:31 +00:00
Leszek Swirski
0df6a20899 [string] Unify String::IsEqualTo
Make String::IsEqualTo use a direct string shape dispatch and a direct
call to CompareChars, rather than splitting the behaviour over
IsOneByte/IsTwoByte/HasOneBytePrefix. Avoiding GetFlatContent will make
this method easier to make efficient while staying string-access-lock
safe.

Also, redefines the sequential string table key's matcher in terms of
this IsEqualTo method.

Change-Id: Iab71246e12044ebaeff06f0dbc14d28b3482dcbe
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557979
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@{#71378}
2020-11-24 16:16:01 +00:00
Gus Caplan
20b417503a Add 'at' to Array.prototype[@@unscopables]
Bug: v8:10961
Change-Id: I3746dca570de005d203a2648dcffedd81122f215
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2553157
Reviewed-by: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: Shu-yu Guo <syg@chromium.org>
Commit-Queue: Gus Caplan <snek@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71377}
2020-11-24 15:41:11 +00:00
Clemens Backes
c229abea6d [wasm][memory64] Prepare interpreter for memory64
This CL prepares the interpreter for 64-bit addresses. The offset (in
the memory immediate) can now be 64-bit, and also the index (from the
stack) will be 64-bit if memory64 is enabled.
memory.size will return a 64-bit constant under memory64.
memory.grow is a bit more involved and requires more refactorings in the
called functions. I left a TODO in the interpreter for now.

R=manoskouk@chromium.org

Bug: v8:10949
Change-Id: I47ab7e38a7356239c827619325f4583069e46669
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2555000
Commit-Queue: Clemens Backes <clemensb@chromium.org>
Reviewed-by: Manos Koukoutos <manoskouk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71376}
2020-11-24 15:25:31 +00:00
Vicky Kontoura
fa9ee22ec1 Revert "[wasm] Enable --wasm-generic-wrapper"
This reverts commit f2034bf507.

Reason for revert: Issue on the generic wrapper

Original change's description:
> [wasm] Enable --wasm-generic-wrapper
>
> This CL enables the --wasm-generic-wrapper flag by default.
>
> Bug: v8:10982
> Change-Id: Iada906ce49810806c500ee3ca26e09e847b69a27
> Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2539915
> Commit-Queue: Vicky Kontoura <vkont@google.com>
> Reviewed-by: Andreas Haas <ahaas@chromium.org>
> Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#71374}

TBR=jkummerow@chromium.org,ahaas@chromium.org,vkont@google.com

Change-Id: I809de71155a76fce503ecd75c7c4854d507c3695
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: v8:10982
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2557990
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Commit-Queue: Andreas Haas <ahaas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71375}
2020-11-24 15:17:22 +00:00
Vicky Kontoura
f2034bf507 [wasm] Enable --wasm-generic-wrapper
This CL enables the --wasm-generic-wrapper flag by default.

Bug: v8:10982
Change-Id: Iada906ce49810806c500ee3ca26e09e847b69a27
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2539915
Commit-Queue: Vicky Kontoura <vkont@google.com>
Reviewed-by: Andreas Haas <ahaas@chromium.org>
Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#71374}
2020-11-24 15:03:51 +00:00