[compiler][arm64] Instruction latencies. [v8/v8 : main]

1 view
Skip to first unread message

Sam Parker-Haynes (Gerrit)

unread,
Jun 23, 2026, 10:05:41 AMJun 23
to Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com

Sam Parker-Haynes added 1 comment

Patchset-level comments
File-level comment, Patchset 1 (Latest):
Sam Parker-Haynes . resolved

@dmerc...@chromium.org Would you mind kicking off one/some pinpoints..?

Open in Gerrit

Related details

Attention set is empty
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Comment-Date: Tue, 23 Jun 2026 14:05:36 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

Darius Mercadier (Gerrit)

unread,
Jun 23, 2026, 10:12:44 AMJun 23
to Sam Parker-Haynes, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Darius Mercadier added 1 comment

Patchset-level comments
Sam Parker-Haynes . resolved

@dmerc...@chromium.org Would you mind kicking off one/some pinpoints..?

Darius Mercadier

Done ;)

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Comment-Date: Tue, 23 Jun 2026 14:12:40 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Sam Parker-Haynes <sam.p...@arm.com>
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 23, 2026, 11:06:36 AMJun 23
to Sam Parker-Haynes, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m4-mini-perf/jetstream-main.crossbench complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/15b9b8c9c90000

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Comment-Date: Tue, 23 Jun 2026 15:06:32 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 23, 2026, 11:10:36 AMJun 23
to Sam Parker-Haynes, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m4-mini-perf/jetstream-main.crossbench complete.

  • ml: base median = 260.0517451286581 -> patched median = 236.52338799036923
  • stanford-crypto-aes: base median = 844.1923446837709 -> patched median = 794.9815443925895


See results at: https://pinpoint-dot-chromeperf.appspot.com/job/1757142ec90000

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Comment-Date: Tue, 23 Jun 2026 15:10:32 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

Sam Parker-Haynes (Gerrit)

unread,
Jun 24, 2026, 3:21:33 AMJun 24
to chrom...@appspot.gserviceaccount.com, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Darius Mercadier

Sam Parker-Haynes added 1 comment

Patchset-level comments
Sam Parker-Haynes . resolved

@dmerc...@chromium.org Would you mind kicking off one/some pinpoints..?

Darius Mercadier

Done ;)

Sam Parker-Haynes

Can we try just --turbo-instruction-scheduling? This patch would change the default behaviour.

Open in Gerrit

Related details

Attention is currently required from:
  • Darius Mercadier
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Comment-Date: Wed, 24 Jun 2026 07:21:28 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Darius Mercadier <dmerc...@chromium.org>
Comment-In-Reply-To: Sam Parker-Haynes <sam.p...@arm.com>
unsatisfied_requirement
open
diffy

Darius Mercadier (Gerrit)

unread,
Jun 24, 2026, 3:22:58 AMJun 24
to Sam Parker-Haynes, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Darius Mercadier added 1 comment

Patchset-level comments
Sam Parker-Haynes . resolved

@dmerc...@chromium.org Would you mind kicking off one/some pinpoints..?

Darius Mercadier

Done ;)

Sam Parker-Haynes

Can we try just --turbo-instruction-scheduling? This patch would change the default behaviour.

Darius Mercadier

done

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Comment-Date: Wed, 24 Jun 2026 07:22:53 +0000
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 24, 2026, 4:19:39 AMJun 24
to Sam Parker-Haynes, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m4-mini-perf/jetstream-main.crossbench complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/14255d9ec90000

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Comment-Date: Wed, 24 Jun 2026 08:19:29 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 24, 2026, 4:19:54 AMJun 24
to Sam Parker-Haynes, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m4-mini-perf/jetstream-main.crossbench complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/12d3e6e1c90000

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Comment-Date: Wed, 24 Jun 2026 08:19:50 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

Sam Parker-Haynes (Gerrit)

unread,
Jun 24, 2026, 5:54:29 AMJun 24
to chrom...@appspot.gserviceaccount.com, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com

Sam Parker-Haynes added 1 comment

Patchset-level comments
Sam Parker-Haynes . resolved

Is this okay, performance wise? I would prefer to ignore the experimental results for now, as the 'backward scheduling' patch should revert the troublesome code.

Open in Gerrit

Related details

Attention set is empty
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Comment-Date: Wed, 24 Jun 2026 09:54:23 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

Darius Mercadier (Gerrit)

unread,
Jun 24, 2026, 8:23:02 AMJun 24
to Sam Parker-Haynes, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Darius Mercadier added 1 comment

Patchset-level comments
Sam Parker-Haynes . resolved

Is this okay, performance wise? I would prefer to ignore the experimental results for now, as the 'backward scheduling' patch should revert the troublesome code.

Darius Mercadier

Mmmh not ideal, but if the CL still makes sense, then I think it's ok. Can you convince me in a few sentences that the CL makes sense (I haven't really looked at it)? :D

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Comment-Date: Wed, 24 Jun 2026 12:22:57 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: Sam Parker-Haynes <sam.p...@arm.com>
unsatisfied_requirement
open
diffy

Sam Parker-Haynes (Gerrit)

unread,
Jun 24, 2026, 8:36:15 AMJun 24
to chrom...@appspot.gserviceaccount.com, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Darius Mercadier

Sam Parker-Haynes added 1 comment

Patchset-level comments
Sam Parker-Haynes . resolved

Is this okay, performance wise? I would prefer to ignore the experimental results for now, as the 'backward scheduling' patch should revert the troublesome code.

Darius Mercadier

Mmmh not ideal, but if the CL still makes sense, then I think it's ok. Can you convince me in a few sentences that the CL makes sense (I haven't really looked at it)? :D

Sam Parker-Haynes

Maybe a few points:

  • Lots of long latency operations can cause greater register pressure.
  • Shorter latencies actually should mean the scheduler spends less time trying to schedule.
  • We currently do not have any Neon instructions and in my downstream testing, on an Arm Linux machine, this patch gave double digit improvements on many simd kernels.
  • Pinpoint shows no difference in the default mode, which I'm really surprised about, but it doesn't appear to be doing any harm.
Open in Gerrit

Related details

Attention is currently required from:
  • Darius Mercadier
Submit Requirements:
  • requirement is not 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: If67c34c6848fa845048610a75a2e775223465c97
Gerrit-Change-Number: 7981419
Gerrit-PatchSet: 1
Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
Gerrit-CC: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Attention: Darius Mercadier <dmerc...@chromium.org>
Gerrit-Comment-Date: Wed, 24 Jun 2026 12:36:11 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

Darius Mercadier (Gerrit)

unread,
Jun 24, 2026, 11:22:49 AMJun 24
to Sam Parker-Haynes, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
Attention needed from Sam Parker-Haynes

Darius Mercadier added 3 comments

Patchset-level comments
Darius Mercadier . unresolved

I'm a bit surprised by some of the new latencies. And a bit surprised that have less precise latencies (only 3 different ones for scalar vs 8 different ones before). Can you explain a bit (maybe in the commit message actually) why the new latencies make more sense? Were the old ones outdated? Or were they never actually correct? Or... ?

The commit message says "Probably the most important part is adding costs for Neon
instructions." ==> maybe it would make sense to split this change in 2 part then: one adding the Neon latencies and one updating the scalar ones?

File src/compiler/backend/arm64/instruction-scheduler-arm64.cc
Line 436, Patchset 1 (Latest): case kArm64Idiv:
case kArm64Idiv32:
case kArm64Udiv:
case kArm64Udiv32:
case kArm64Imod:
case kArm64Imod32:
case kArm64Umod:
case kArm64Umod32:
return kVeryLongScalarLatency;
Darius Mercadier . unresolved

That's much lower than before; are modern Arm CPUs really that fast to do division?

Line 467, Patchset 1 (Latest): case kArm64Float64Mod:
Darius Mercadier . unresolved

That's a surprising one as well!

Open in Gerrit

Related details

Attention is currently required from:
  • Sam Parker-Haynes
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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 1
    Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Reviewer: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Comment-Date: Wed, 24 Jun 2026 15:22:44 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    unsatisfied_requirement
    open
    diffy

    Sam Parker-Haynes (Gerrit)

    unread,
    Jun 24, 2026, 2:22:47 PMJun 24
    to Darius Mercadier, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Darius Mercadier

    Sam Parker-Haynes added 2 comments

    Patchset-level comments
    Darius Mercadier . unresolved

    I'm a bit surprised by some of the new latencies. And a bit surprised that have less precise latencies (only 3 different ones for scalar vs 8 different ones before). Can you explain a bit (maybe in the commit message actually) why the new latencies make more sense? Were the old ones outdated? Or were they never actually correct? Or... ?

    The commit message says "Probably the most important part is adding costs for Neon
    instructions." ==> maybe it would make sense to split this change in 2 part then: one adding the Neon latencies and one updating the scalar ones?

    Sam Parker-Haynes

    Yes, sorry the message was a little terse, I've basically had the same discussion downstream and should have dumped the reasoning somewhere 😊 The commit message has been updated.

    Basically the latencies do not reflect reality but make it harder for scheduler to make decisions that increase register pressure. But I'm also working on a patch so the scheduler becomes aware of that too.

    I can split the patch if that's preferred.

    File src/compiler/backend/arm64/instruction-scheduler-arm64.cc
    Line 436, Patchset 1: case kArm64Idiv:

    case kArm64Idiv32:
    case kArm64Udiv:
    case kArm64Udiv32:
    case kArm64Imod:
    case kArm64Imod32:
    case kArm64Umod:
    case kArm64Umod32:
    return kVeryLongScalarLatency;
    Darius Mercadier . unresolved

    That's much lower than before; are modern Arm CPUs really that fast to do division?

    Sam Parker-Haynes

    No, I think most cores are actually 12 cycles or so, but I've found that in general having higher latencies just means higher register pressure and spills/refills end up being more expensive than a possible a few stall cycles.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Darius Mercadier
    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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 2
    Gerrit-Attention: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Comment-Date: Wed, 24 Jun 2026 18:22:40 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Darius Mercadier <dmerc...@chromium.org>
    unsatisfied_requirement
    open
    diffy

    Darius Mercadier (Gerrit)

    unread,
    Jun 25, 2026, 1:50:06 AMJun 25
    to Sam Parker-Haynes, Nico Hartmann, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Sam Parker-Haynes

    Darius Mercadier added 4 comments

    Patchset-level comments
    Darius Mercadier . unresolved

    I'm a bit surprised by some of the new latencies. And a bit surprised that have less precise latencies (only 3 different ones for scalar vs 8 different ones before). Can you explain a bit (maybe in the commit message actually) why the new latencies make more sense? Were the old ones outdated? Or were they never actually correct? Or... ?

    The commit message says "Probably the most important part is adding costs for Neon
    instructions." ==> maybe it would make sense to split this change in 2 part then: one adding the Neon latencies and one updating the scalar ones?

    Sam Parker-Haynes

    Yes, sorry the message was a little terse, I've basically had the same discussion downstream and should have dumped the reasoning somewhere 😊 The commit message has been updated.

    Basically the latencies do not reflect reality but make it harder for scheduler to make decisions that increase register pressure. But I'm also working on a patch so the scheduler becomes aware of that too.

    I can split the patch if that's preferred.

    Darius Mercadier

    Ok thanks for the additional context.. Yea, I've also noticed that the scheduler has a tendency to increase register pressure and my very naive [attempt](https://crrev.com/c/7612927) to improve this didn't work, so thanks for spending more time to improve things here! :)

    I can't say that I'm a huge fan of this CL though, because it feels like you don't fully know where you're going, and you're just hoping that more coarse latencies would be better. I'd prefer to keep precise(ish) latencies, and make the scheduler approximate them afterwards with something like
    ```
    int ExactLatencyToApproxForScheduling(int latency) {
    if (latency <= 1) return 1;
    if (latency <= 3) return 2;
    return 5;
    }
    ```
    So that we still have an opportunity to make use of the exact latency (to break ties for instance or something like that).

    Additionally, this would be a less intrusive change, which is better given that as far as I understand you're unsure yet if your work will really pay off.

    Another point: you're only updating arm64 with this new model, which means that the scheduler will do different things on arm64 and other architectures (until this CL is ported to other architectures), which isn't great.

    File src/compiler/backend/arm64/instruction-scheduler-arm64.cc
    Line 436, Patchset 1: case kArm64Idiv:
    case kArm64Idiv32:
    case kArm64Udiv:
    case kArm64Udiv32:
    case kArm64Imod:
    case kArm64Imod32:
    case kArm64Umod:
    case kArm64Umod32:
    return kVeryLongScalarLatency;
    Darius Mercadier . resolved

    That's much lower than before; are modern Arm CPUs really that fast to do division?

    Sam Parker-Haynes

    No, I think most cores are actually 12 cycles or so, but I've found that in general having higher latencies just means higher register pressure and spills/refills end up being more expensive than a possible a few stall cycles.

    Darius Mercadier

    Acknowledged

    Line 467, Patchset 1: case kArm64Float64Mod:
    Darius Mercadier . resolved

    That's a surprising one as well!

    Darius Mercadier

    Acknowledged

    Line 709, Patchset 2 (Latest): default:
    Darius Mercadier . unresolved

    It could make sense to remove the `default` so that new opcodes aren't assumed to have DefautScalarLatency.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Sam Parker-Haynes
    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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 2
    Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Reviewer: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-CC: Nico Hartmann <nicoha...@chromium.org>
    Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Comment-Date: Thu, 25 Jun 2026 05:50:00 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Darius Mercadier <dmerc...@chromium.org>
    Comment-In-Reply-To: Sam Parker-Haynes <sam.p...@arm.com>
    unsatisfied_requirement
    open
    diffy

    Sam Parker-Haynes (Gerrit)

    unread,
    Jun 25, 2026, 5:47:56 AMJun 25
    to Nico Hartmann, Darius Mercadier, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Darius Mercadier

    Sam Parker-Haynes added 1 comment

    Patchset-level comments
    Darius Mercadier . unresolved

    I'm a bit surprised by some of the new latencies. And a bit surprised that have less precise latencies (only 3 different ones for scalar vs 8 different ones before). Can you explain a bit (maybe in the commit message actually) why the new latencies make more sense? Were the old ones outdated? Or were they never actually correct? Or... ?

    The commit message says "Probably the most important part is adding costs for Neon
    instructions." ==> maybe it would make sense to split this change in 2 part then: one adding the Neon latencies and one updating the scalar ones?

    Sam Parker-Haynes

    Yes, sorry the message was a little terse, I've basically had the same discussion downstream and should have dumped the reasoning somewhere 😊 The commit message has been updated.

    Basically the latencies do not reflect reality but make it harder for scheduler to make decisions that increase register pressure. But I'm also working on a patch so the scheduler becomes aware of that too.

    I can split the patch if that's preferred.

    Darius Mercadier

    Ok thanks for the additional context.. Yea, I've also noticed that the scheduler has a tendency to increase register pressure and my very naive [attempt](https://crrev.com/c/7612927) to improve this didn't work, so thanks for spending more time to improve things here! :)

    I can't say that I'm a huge fan of this CL though, because it feels like you don't fully know where you're going, and you're just hoping that more coarse latencies would be better. I'd prefer to keep precise(ish) latencies, and make the scheduler approximate them afterwards with something like
    ```
    int ExactLatencyToApproxForScheduling(int latency) {
    if (latency <= 1) return 1;
    if (latency <= 3) return 2;
    return 5;
    }
    ```
    So that we still have an opportunity to make use of the exact latency (to break ties for instance or something like that).

    Additionally, this would be a less intrusive change, which is better given that as far as I understand you're unsure yet if your work will really pay off.

    Another point: you're only updating arm64 with this new model, which means that the scheduler will do different things on arm64 and other architectures (until this CL is ported to other architectures), which isn't great.

    Sam Parker-Haynes

    I'd prefer to keep precise(ish) latencies, and make the scheduler approximate them afterwards.

    Okay.

    until this CL is ported to other architectures

    Sorry, I don't follow! Why would arm64 latencies be ported to other architectures?

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Darius Mercadier
    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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 2
    Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Reviewer: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-CC: Nico Hartmann <nicoha...@chromium.org>
    Gerrit-Attention: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Comment-Date: Thu, 25 Jun 2026 09:47:52 +0000
    unsatisfied_requirement
    open
    diffy

    Darius Mercadier (Gerrit)

    unread,
    Jun 25, 2026, 5:55:16 AMJun 25
    to Sam Parker-Haynes, Nico Hartmann, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Sam Parker-Haynes

    Darius Mercadier added 1 comment

    Patchset-level comments
    Darius Mercadier

    Sorry, I don't follow! Why would arm64 latencies be ported to other architectures?

    Presumably you're going to work on the scheduler to make it work better and you'll make the assumption that you're dealing with the "new" arm64 latencies, so whatever you do might not be good for other architectures that didn't get the "latency update".

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Sam Parker-Haynes
    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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 2
    Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Reviewer: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-CC: Nico Hartmann <nicoha...@chromium.org>
    Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Comment-Date: Thu, 25 Jun 2026 09:55:10 +0000
    unsatisfied_requirement
    open
    diffy

    Sam Parker-Haynes (Gerrit)

    unread,
    Jun 25, 2026, 6:17:35 AMJun 25
    to Nico Hartmann, Darius Mercadier, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Darius Mercadier

    Sam Parker-Haynes added 1 comment

    Patchset-level comments
    Sam Parker-Haynes

    I think they should be orthagonal. With the exception of backward scheduling, all of the other changes will be controlled by 'models' supplied by the backends and those values can be set so that the status quo is maintained, as done in https://chromium-review.googlesource.com/c/v8/v8/+/7994015. That patch removes the one thing that could cause issues for arm64 and other backends so I need to think further about how that would be an opt-in.

    Maybe it would just be best to land this patch after everything else? I don't want anyone thinking I've rewritten the scheduler to just benefit arm64!

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Darius Mercadier
    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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 2
    Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Reviewer: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-CC: Nico Hartmann <nicoha...@chromium.org>
    Gerrit-Attention: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Comment-Date: Thu, 25 Jun 2026 10:17:30 +0000
    unsatisfied_requirement
    open
    diffy

    chromeperf@appspot.gserviceaccount.com (Gerrit)

    unread,
    Jul 24, 2026, 5:20:28 AM (24 hours ago) Jul 24
    to Sam Parker-Haynes, Nico Hartmann, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Darius Mercadier and Sam Parker-Haynes

    Message from chrom...@appspot.gserviceaccount.com

    📍 Job mac-m4-mini-perf/jetstream3.crossbench complete.

    See results at: https://pinpoint-dot-chromeperf.appspot.com/job/105cee8c290000

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Darius Mercadier
    • Sam Parker-Haynes
    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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 3
    Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Reviewer: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-CC: Nico Hartmann <nicoha...@chromium.org>
    Gerrit-Attention: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Attention: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Comment-Date: Fri, 24 Jul 2026 09:20:24 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: No
    unsatisfied_requirement
    open
    diffy

    chromeperf@appspot.gserviceaccount.com (Gerrit)

    unread,
    Jul 24, 2026, 5:23:35 AM (24 hours ago) Jul 24
    to Sam Parker-Haynes, Nico Hartmann, Darius Mercadier, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Darius Mercadier and Sam Parker-Haynes

    Message from chrom...@appspot.gserviceaccount.com

    📍 Job mac-m4-mini-perf/jetstream3.crossbench complete.

    See results at: https://pinpoint-dot-chromeperf.appspot.com/job/12491dca290000

    Gerrit-Comment-Date: Fri, 24 Jul 2026 09:23:31 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: No
    unsatisfied_requirement
    open
    diffy

    Sam Parker-Haynes (Gerrit)

    unread,
    Jul 24, 2026, 5:40:27 AM (23 hours ago) Jul 24
    to Nico Hartmann, Darius Mercadier, chrom...@appspot.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, dmercadi...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Darius Mercadier

    Sam Parker-Haynes added 1 comment

    Patchset-level comments
    File-level comment, Patchset 3 (Latest):
    Sam Parker-Haynes . resolved

    Hi Darius, I've rewritten this so we're using accurate(ish) latencies.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Darius Mercadier
    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: If67c34c6848fa845048610a75a2e775223465c97
    Gerrit-Change-Number: 7981419
    Gerrit-PatchSet: 3
    Gerrit-Owner: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-Reviewer: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Reviewer: Sam Parker-Haynes <sam.p...@arm.com>
    Gerrit-CC: Nico Hartmann <nicoha...@chromium.org>
    Gerrit-Attention: Darius Mercadier <dmerc...@chromium.org>
    Gerrit-Comment-Date: Fri, 24 Jul 2026 09:40:21 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    unsatisfied_requirement
    open
    diffy
    Reply all
    Reply to author
    Forward
    0 new messages