[wasm-wide-arith] Implement Wide Multiplication on ia32 and arm in Liftoff [v8/v8 : main]

0 views
Skip to first unread message

Ryan Diaz (Gerrit)

unread,
May 16, 2026, 1:16:00 AM (4 days ago) May 16
to Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Clemens Backes and Jakob Kummerow

Ryan Diaz voted and added 2 comments

Votes added by Ryan Diaz

Commit-Queue+1

2 comments

File src/wasm/baseline/ia32/liftoff-assembler-ia32-inl.h
Line 1982, Patchset 4:inline void EmitI64MulWide(LiftoffAssembler* assm, bool is_signed) {
Clemens Backes . unresolved

Would it be easier to call out to C (is there some library function we could use)?

And to which extend is this covered by tests? Would now be a good time to add some fuzzing support, maybe something similar to the `Float32CrossCompilerDeterminismTest`?

Ryan Diaz

You mean do a similar thing to what we did for 32 bit add/sub128 https://chromium-review.git.corp.google.com/c/v8/v8/+/7797503 ?

Yes, I think that is simpler, I wasn't sure if it was better / necessary, but I'll go ahead and add external ref function for this.

For tests, I'm relying on the js unittests here: https://source.chromium.org/chromium/chromium/src/+/main:v8/test/mjsunit/wasm/wide-arithmetic.js;l=1?q=test%2Fmjsunit%2Fwasm%2Fwide-arithmetic.js&sq=&ss=chromium%2Fchromium%2Fsrc:v8%2F

I agree there should be more robust coverage, I'll look into the test you mentioned.

Ryan Diaz

Ok updated this CL to us an external call for liftoff wide mul for both 32 bit architectures.

File src/wasm/baseline/liftoff-compiler.cc
Line 3108, Patchset 7: for (int i = 1; i <= 2; ++i) {
VarState& slot = __ cache_state() -> stack_state.end()[-i];
if (slot.is_const()) {
__ Spill(slot.offset(), slot.constant());
slot.MakeStack();
}
}
Ryan Diaz . unresolved

This was the suggestion for materializing constants from the bug related to add/sub128 potential memory read errors. I will separately go apply this to those ops and pull it out into a separate function in a separate cl.

Open in Gerrit

Related details

Attention is currently required from:
  • Clemens Backes
  • Jakob Kummerow
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-Attention: Clemens Backes <clem...@chromium.org>
Gerrit-Attention: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Comment-Date: Sat, 16 May 2026 05:15:56 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: Ryan Diaz <ryan...@chromium.org>
Comment-In-Reply-To: Clemens Backes <clem...@chromium.org>
unsatisfied_requirement
open
diffy

Clemens Backes (Gerrit)

unread,
May 18, 2026, 5:10:24 AM (yesterday) May 18
to Ryan Diaz, Jakob Kummerow, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Jakob Kummerow and Ryan Diaz

Clemens Backes voted and added 5 comments

Votes added by Clemens Backes

Code-Review+1

5 comments

Patchset-level comments
File-level comment, Patchset 8 (Latest):
Clemens Backes . resolved

LGTM with comments.

File src/wasm/baseline/liftoff-compiler.cc
Line 3110, Patchset 8 (Latest): if (slot.is_const()) {
__ Spill(slot.offset(), slot.constant());
slot.MakeStack();
}
Clemens Backes . unresolved

It would be slightly simpler to just call `Spill(&slot);` unconditionally.

Line 3108, Patchset 7: for (int i = 1; i <= 2; ++i) {
VarState& slot = __ cache_state() -> stack_state.end()[-i];
if (slot.is_const()) {
__ Spill(slot.offset(), slot.constant());
slot.MakeStack();
}
}
Ryan Diaz . resolved

This was the suggestion for materializing constants from the bug related to add/sub128 potential memory read errors. I will separately go apply this to those ops and pull it out into a separate function in a separate cl.

Clemens Backes

Ack.

File src/wasm/function-body-decoder-impl.h
Line 7917, Patchset 8 (Latest):#if V8_TARGET_ARCH_X64 || V8_TARGET_ARCH_ARM64 || V8_TARGET_ARCH_IA32 || \
Clemens Backes . unresolved

See https://crrev.com/c/7847572: We should fully remove these `#if`s from the function body decoder. This can happen in any order (it's fine to extend the list here and then drop it in a separate CL).

File src/wasm/wasm-external-refs.cc
Line 406, Patchset 8 (Latest):void wasm_int64_mul_wide_s_wrapper(Address data) {
Clemens Backes . unresolved

To save a bit of binary size and to avoid accidentally calling this on 64-bit architectures, we could have a `#if V8_TARGET_ARCH_64_BIT \n UNREACHABLE() \n #else \n ...` (same below of course).

We could also go a step further and not even *define* the external references on 64-bit systems. Feel free to try that if you like. But it's optional.

Open in Gerrit

Related details

Attention is currently required from:
  • Jakob Kummerow
  • Ryan Diaz
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
Gerrit-Attention: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Comment-Date: Mon, 18 May 2026 09:10:20 +0000
satisfied_requirement
unsatisfied_requirement
open
diffy

Jakob Kummerow (Gerrit)

unread,
May 18, 2026, 9:24:36 AM (yesterday) May 18
to Ryan Diaz, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Ryan Diaz

Jakob Kummerow voted and added 1 comment

Votes added by Jakob Kummerow

Code-Review+1

1 comment

Patchset-level comments
Jakob Kummerow . resolved

LGTM % Clemens' comments.

Open in Gerrit

Related details

Attention is currently required from:
  • Ryan Diaz
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
Gerrit-Comment-Date: Mon, 18 May 2026 13:24:33 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
satisfied_requirement
unsatisfied_requirement
open
diffy

Milad Farazmand (Gerrit)

unread,
May 18, 2026, 9:35:29 AM (yesterday) May 18
to Ryan Diaz, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Ryan Diaz

Milad Farazmand added 1 comment

Patchset-level comments
Milad Farazmand . resolved

Hello,

A number of macro guards have been removed by this CL: http://crrev.com/c/7847572
PPC/S390 don't yet support wide ops and we will have them implemented in the near future.
Would it be safer to add the guards back for said platforms or just skip the `mjsunit/wasm/wide-arithmetic` tests for now?

Open in Gerrit

Related details

Attention is currently required from:
  • Ryan Diaz
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
Gerrit-Comment-Date: Mon, 18 May 2026 13:35:27 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Clemens Backes (Gerrit)

unread,
May 18, 2026, 9:38:41 AM (yesterday) May 18
to Ryan Diaz, Milad Farazmand, Jakob Kummerow, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Milad Farazmand and Ryan Diaz

Clemens Backes added 1 comment

Patchset-level comments
Milad Farazmand . resolved

Hello,

A number of macro guards have been removed by this CL: http://crrev.com/c/7847572
PPC/S390 don't yet support wide ops and we will have them implemented in the near future.
Would it be safer to add the guards back for said platforms or just skip the `mjsunit/wasm/wide-arithmetic` tests for now?

Clemens Backes

If you add back some bailouts, do that at some lower level, ideally in the platform-specific `LiftoffAssembler` methods. If it's just failing tests and not failing compilation, you can also just skip. Whatever is easier for you.

Open in Gerrit

Related details

Attention is currently required from:
  • Milad Farazmand
  • Ryan Diaz
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
Gerrit-Attention: Milad Farazmand <mfar...@ibm.com>
Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
Gerrit-Comment-Date: Mon, 18 May 2026 13:38:37 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Milad Farazmand <mfar...@ibm.com>
satisfied_requirement
unsatisfied_requirement
open
diffy

Milad Farazmand (Gerrit)

unread,
May 18, 2026, 9:44:15 AM (yesterday) May 18
to Ryan Diaz, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Ryan Diaz

Milad Farazmand added 1 comment

Patchset-level comments
Milad Farazmand . resolved

Hello,

A number of macro guards have been removed by this CL: http://crrev.com/c/7847572
PPC/S390 don't yet support wide ops and we will have them implemented in the near future.
Would it be safer to add the guards back for said platforms or just skip the `mjsunit/wasm/wide-arithmetic` tests for now?

Clemens Backes

If you add back some bailouts, do that at some lower level, ideally in the platform-specific `LiftoffAssembler` methods. If it's just failing tests and not failing compilation, you can also just skip. Whatever is easier for you.

Milad Farazmand

It will hit the `unimplemented` blocks in liftoff. Do you expect more tests will get added soon which use this feature (given it's experimental) or `wide-arithmetic` is the only test for now? trying to prioritize this item.

Open in Gerrit

Related details

Attention is currently required from:
  • Ryan Diaz
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
Gerrit-Comment-Date: Mon, 18 May 2026 13:44:13 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Milad Farazmand <mfar...@ibm.com>
Comment-In-Reply-To: Clemens Backes <clem...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Jakob Kummerow (Gerrit)

unread,
May 18, 2026, 10:05:26 AM (yesterday) May 18
to Ryan Diaz, Milad Farazmand, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Milad Farazmand and Ryan Diaz

Jakob Kummerow added 1 comment

Patchset-level comments
Milad Farazmand . resolved

Hello,

A number of macro guards have been removed by this CL: http://crrev.com/c/7847572
PPC/S390 don't yet support wide ops and we will have them implemented in the near future.
Would it be safer to add the guards back for said platforms or just skip the `mjsunit/wasm/wide-arithmetic` tests for now?

Clemens Backes

If you add back some bailouts, do that at some lower level, ideally in the platform-specific `LiftoffAssembler` methods. If it's just failing tests and not failing compilation, you can also just skip. Whatever is easier for you.

Milad Farazmand

It will hit the `unimplemented` blocks in liftoff. Do you expect more tests will get added soon which use this feature (given it's experimental) or `wide-arithmetic` is the only test for now? trying to prioritize this item.

Jakob Kummerow

"experimental" in this case just means that it's a feature we're currently implementing; it's not ready for production yet but we're working on getting it into that state. The upstream spec is pretty far along ("phase 3"); I'd expect this to ship by default not too long from now.

Open in Gerrit

Related details

Attention is currently required from:
  • Milad Farazmand
  • Ryan Diaz
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
Gerrit-Attention: Milad Farazmand <mfar...@ibm.com>
Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
Gerrit-Comment-Date: Mon, 18 May 2026 14:05:21 +0000
satisfied_requirement
unsatisfied_requirement
open
diffy

Milad Farazmand (Gerrit)

unread,
May 18, 2026, 10:47:12 AM (yesterday) May 18
to Ryan Diaz, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Ryan Diaz

Milad Farazmand added 1 comment

Patchset-level comments
Milad Farazmand . resolved

Hello,

A number of macro guards have been removed by this CL: http://crrev.com/c/7847572
PPC/S390 don't yet support wide ops and we will have them implemented in the near future.
Would it be safer to add the guards back for said platforms or just skip the `mjsunit/wasm/wide-arithmetic` tests for now?

Clemens Backes

If you add back some bailouts, do that at some lower level, ideally in the platform-specific `LiftoffAssembler` methods. If it's just failing tests and not failing compilation, you can also just skip. Whatever is easier for you.

Milad Farazmand

It will hit the `unimplemented` blocks in liftoff. Do you expect more tests will get added soon which use this feature (given it's experimental) or `wide-arithmetic` is the only test for now? trying to prioritize this item.

Jakob Kummerow

"experimental" in this case just means that it's a feature we're currently implementing; it's not ready for production yet but we're working on getting it into that state. The upstream spec is pretty far along ("phase 3"); I'd expect this to ship by default not too long from now.

Milad Farazmand

Thank yo for the information, I'll skip them for now until we implement the ops: http://crrev.com/c/7856124

Open in Gerrit

Related details

Attention is currently required from:
  • Ryan Diaz
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 8
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
Gerrit-Comment-Date: Mon, 18 May 2026 14:47:10 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Milad Farazmand <mfar...@ibm.com>
Comment-In-Reply-To: Jakob Kummerow <jkum...@chromium.org>
Comment-In-Reply-To: Clemens Backes <clem...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Ryan Diaz (Gerrit)

unread,
May 18, 2026, 7:25:05 PM (yesterday) May 18
to Milad Farazmand, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Clemens Backes and Jakob Kummerow

Ryan Diaz added 3 comments

File src/wasm/baseline/liftoff-compiler.cc
Line 3110, Patchset 8: if (slot.is_const()) {
__ Spill(slot.offset(), slot.constant());
slot.MakeStack();
}
Clemens Backes . resolved

It would be slightly simpler to just call `Spill(&slot);` unconditionally.

Ryan Diaz

refactored to use `SpillLoopArgs` which does what you suggested.

File src/wasm/function-body-decoder-impl.h
Line 7917, Patchset 8:#if V8_TARGET_ARCH_X64 || V8_TARGET_ARCH_ARM64 || V8_TARGET_ARCH_IA32 || \
Clemens Backes . resolved

See https://crrev.com/c/7847572: We should fully remove these `#if`s from the function body decoder. This can happen in any order (it's fine to extend the list here and then drop it in a separate CL).

Ryan Diaz

Done

File src/wasm/wasm-external-refs.cc
Line 406, Patchset 8:void wasm_int64_mul_wide_s_wrapper(Address data) {
Clemens Backes . unresolved

To save a bit of binary size and to avoid accidentally calling this on 64-bit architectures, we could have a `#if V8_TARGET_ARCH_64_BIT \n UNREACHABLE() \n #else \n ...` (same below of course).

We could also go a step further and not even *define* the external references on 64-bit systems. Feel free to try that if you like. But it's optional.

Ryan Diaz

went with the simpler `#if V8_TARGET_ARCH_64_BIT...` approach here

Open in Gerrit

Related details

Attention is currently required from:
  • Clemens Backes
  • Jakob Kummerow
Submit Requirements:
  • requirement satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
Gerrit-Change-Number: 7851203
Gerrit-PatchSet: 10
Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
Gerrit-Attention: Clemens Backes <clem...@chromium.org>
Gerrit-Attention: Jakob Kummerow <jkum...@chromium.org>
Gerrit-Comment-Date: Mon, 18 May 2026 23:25:01 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Clemens Backes <clem...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

Ryan Diaz (Gerrit)

unread,
May 18, 2026, 8:46:27 PM (yesterday) May 18
to Milad Farazmand, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Clemens Backes and Jakob Kummerow

Ryan Diaz added 1 comment

File src/wasm/wasm-external-refs.cc
Line 406, Patchset 8:void wasm_int64_mul_wide_s_wrapper(Address data) {
Clemens Backes . resolved

To save a bit of binary size and to avoid accidentally calling this on 64-bit architectures, we could have a `#if V8_TARGET_ARCH_64_BIT \n UNREACHABLE() \n #else \n ...` (same below of course).

We could also go a step further and not even *define* the external references on 64-bit systems. Feel free to try that if you like. But it's optional.

Ryan Diaz

went with the simpler `#if V8_TARGET_ARCH_64_BIT...` approach here

Ryan Diaz

Done

Gerrit-Comment-Date: Tue, 19 May 2026 00:46:24 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Ryan Diaz (Gerrit)

unread,
May 18, 2026, 8:46:52 PM (yesterday) May 18
to Milad Farazmand, Jakob Kummerow, Clemens Backes, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
Attention needed from Clemens Backes and Jakob Kummerow

Ryan Diaz voted and added 1 comment

Votes added by Ryan Diaz

Auto-Submit+1

1 comment

File src/wasm/baseline/ia32/liftoff-assembler-ia32-inl.h
Line 1982, Patchset 4:inline void EmitI64MulWide(LiftoffAssembler* assm, bool is_signed) {
Clemens Backes . resolved

Would it be easier to call out to C (is there some library function we could use)?

And to which extend is this covered by tests? Would now be a good time to add some fuzzing support, maybe something similar to the `Float32CrossCompilerDeterminismTest`?

Ryan Diaz

You mean do a similar thing to what we did for 32 bit add/sub128 https://chromium-review.git.corp.google.com/c/v8/v8/+/7797503 ?

Yes, I think that is simpler, I wasn't sure if it was better / necessary, but I'll go ahead and add external ref function for this.

For tests, I'm relying on the js unittests here: https://source.chromium.org/chromium/chromium/src/+/main:v8/test/mjsunit/wasm/wide-arithmetic.js;l=1?q=test%2Fmjsunit%2Fwasm%2Fwide-arithmetic.js&sq=&ss=chromium%2Fchromium%2Fsrc:v8%2F

I agree there should be more robust coverage, I'll look into the test you mentioned.

Ryan Diaz

Ok updated this CL to us an external call for liftoff wide mul for both 32 bit architectures.

Ryan Diaz

Done

Open in Gerrit

Related details

Attention is currently required from:
  • Clemens Backes
  • Jakob Kummerow
Submit Requirements:
    • requirement satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
    Gerrit-Change-Number: 7851203
    Gerrit-PatchSet: 11
    Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
    Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
    Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
    Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
    Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
    Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
    Gerrit-Attention: Clemens Backes <clem...@chromium.org>
    Gerrit-Attention: Jakob Kummerow <jkum...@chromium.org>
    Gerrit-Comment-Date: Tue, 19 May 2026 00:46:49 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Clemens Backes (Gerrit)

    unread,
    5:00 AM (16 hours ago) 5:00 AM
    to Ryan Diaz, Milad Farazmand, Jakob Kummerow, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
    Attention needed from Jakob Kummerow and Ryan Diaz

    Clemens Backes voted and added 1 comment

    Votes added by Clemens Backes

    Code-Review+1

    1 comment

    File src/wasm/baseline/liftoff-compiler.cc
    Line 3108, Patchset 11 (Latest): __ SpillLoopArgs(2);
    Clemens Backes . unresolved

    This could use a little comment, in particular since it is used outside of a loop.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Jakob Kummerow
    • Ryan Diaz
    Submit Requirements:
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
    Gerrit-Change-Number: 7851203
    Gerrit-PatchSet: 11
    Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
    Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
    Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
    Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
    Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
    Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
    Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
    Gerrit-Attention: Jakob Kummerow <jkum...@chromium.org>
    Gerrit-Comment-Date: Tue, 19 May 2026 09:00:22 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Jakob Kummerow (Gerrit)

    unread,
    6:47 AM (15 hours ago) 6:47 AM
    to Ryan Diaz, Jakob Kummerow, Clemens Backes, Milad Farazmand, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com
    Attention needed from Ryan Diaz

    Jakob Kummerow voted Code-Review+1

    Code-Review+1
    Open in Gerrit

    Related details

    Attention is currently required from:
    • Ryan Diaz
    Submit Requirements:
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
    Gerrit-Change-Number: 7851203
    Gerrit-PatchSet: 11
    Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
    Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
    Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
    Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
    Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
    Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
    Gerrit-Attention: Ryan Diaz <ryan...@chromium.org>
    Gerrit-Comment-Date: Tue, 19 May 2026 10:47:53 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Ryan Diaz (Gerrit)

    unread,
    7:32 PM (2 hours ago) 7:32 PM
    to Jakob Kummerow, Clemens Backes, Milad Farazmand, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com

    Ryan Diaz voted and added 1 comment

    Votes added by Ryan Diaz

    Auto-Submit+1
    Code-Review+1

    1 comment

    File src/wasm/baseline/liftoff-compiler.cc
    Line 3108, Patchset 11: __ SpillLoopArgs(2);
    Clemens Backes . resolved

    This could use a little comment, in particular since it is used outside of a loop.

    Ryan Diaz

    Done

    Open in Gerrit

    Related details

    Attention set is empty
    Submit Requirements:
      • requirement satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
      Gerrit-Change-Number: 7851203
      Gerrit-PatchSet: 11
      Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
      Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
      Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
      Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
      Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
      Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
      Gerrit-Comment-Date: Tue, 19 May 2026 23:32:29 +0000
      Gerrit-HasComments: Yes
      Gerrit-Has-Labels: Yes
      Comment-In-Reply-To: Clemens Backes <clem...@chromium.org>
      satisfied_requirement
      open
      diffy

      Ryan Diaz (Gerrit)

      unread,
      7:32 PM (2 hours ago) 7:32 PM
      to Jakob Kummerow, Clemens Backes, Milad Farazmand, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com

      Ryan Diaz voted Commit-Queue+2

      Commit-Queue+2
      Open in Gerrit

      Related details

      Attention set is empty
      Submit Requirements:
      • requirement satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
      Gerrit-Change-Number: 7851203
      Gerrit-PatchSet: 12
      Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
      Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
      Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
      Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
      Gerrit-CC: Deepti Gandluri <gde...@chromium.org>
      Gerrit-CC: Milad Farazmand <mfar...@ibm.com>
      Gerrit-Comment-Date: Tue, 19 May 2026 23:32:49 +0000
      Gerrit-HasComments: No
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      open
      diffy

      Ryan Diaz (Gerrit)

      unread,
      7:33 PM (2 hours ago) 7:33 PM
      to Jakob Kummerow, Clemens Backes, Milad Farazmand, Deepti Gandluri, v8-s...@luci-project-accounts.iam.gserviceaccount.com, v8-re...@googlegroups.com, was...@google.com

      Ryan Diaz voted

      Auto-Submit+1
      Code-Review+0
      Gerrit-Comment-Date: Tue, 19 May 2026 23:33:01 +0000
      Gerrit-HasComments: No
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      open
      diffy

      v8-scoped@luci-project-accounts.iam.gserviceaccount.com (Gerrit)

      unread,
      8:21 PM (1 hour ago) 8:21 PM
      to Ryan Diaz, Jakob Kummerow, Clemens Backes, Milad Farazmand, Deepti Gandluri, v8-re...@googlegroups.com, was...@google.com

      v8-s...@luci-project-accounts.iam.gserviceaccount.com submitted the change with unreviewed changes

      Unreviewed changes

      11 is the latest approved patch-set.
      The change was submitted with unreviewed changes in the following files:

      ```
      The name of the file: src/wasm/baseline/liftoff-compiler.cc
      Insertions: 2, Deletions: 0.

      @@ -3105,7 +3105,9 @@
      UNREACHABLE();
      }
      #elif V8_TARGET_ARCH_IA32 || V8_TARGET_ARCH_ARM
      + // Spill the two 64-bit arguments to multiplication.
      __ SpillLoopArgs(2);
      + // Spill the remaining registers (if any).
      __ SpillAllRegisters();

      // Compute the lowest address of the two 64bit inputs.
      ```

      Change information

      Commit message:
      [wasm-wide-arith] Implement Wide Multiplication on ia32 and arm in Liftoff

      Use an external call to complete the 64x64 -> 128 bit multiplication ops
      on 32 bit architectures in Liftoff.
      Bug: 491766259
      Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
      Reviewed-by: Jakob Kummerow <jkum...@chromium.org>
      Commit-Queue: Ryan Diaz <ryan...@chromium.org>
      Reviewed-by: Clemens Backes <clem...@chromium.org>
      Auto-Submit: Ryan Diaz <ryan...@chromium.org>
      Cr-Commit-Position: refs/heads/main@{#107438}
      Files:
      • M src/codegen/external-reference.cc
      • M src/codegen/external-reference.h
      • M src/wasm/baseline/liftoff-compiler.cc
      • M src/wasm/wasm-external-refs.cc
      • M src/wasm/wasm-external-refs.h
      Change size: M
      Delta: 5 files changed, 70 insertions(+), 0 deletions(-)
      Branch: refs/heads/main
      Submit Requirements:
      • requirement satisfiedCode-Review: +0 by Ryan Diaz, +1 by Clemens Backes, +1 by Jakob Kummerow
      Open in Gerrit
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: merged
      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: I9afdf3ef15bce7eebcc5a09f5335b53ee8f03582
      Gerrit-Change-Number: 7851203
      Gerrit-PatchSet: 13
      Gerrit-Owner: Ryan Diaz <ryan...@chromium.org>
      Gerrit-Reviewer: Clemens Backes <clem...@chromium.org>
      Gerrit-Reviewer: Jakob Kummerow <jkum...@chromium.org>
      Gerrit-Reviewer: Ryan Diaz <ryan...@chromium.org>
      open
      diffy
      satisfied_requirement
      Reply all
      Reply to author
      Forward
      0 new messages