All of lore.kernel.org
 help / color / mirror / Atom feed
From: "David Hildenbrand (Arm)" <david@kernel.org>
To: "Christoph Lameter (Ampere)" <cl@gentwo.org>
Cc: "Lorenzo Stoakes (ARM)" <ljs@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Yang Shi <yang@os.amperecomputing.com>,
	Ryan Roberts <ryan.roberts@arm.com>,
	dennis@kernel.org, tj@kernel.org, urezki@gmail.com,
	catalin.marinas@arm.com, will@kernel.org,
	akpm@linux-foundation.org, hca@linux.ibm.com, gor@linux.ibm.com,
	agordeev@linux.ibm.com, linux-mm@kvack.org,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Jason Gunthorpe <jgg@nvidia.com>
Subject: Re: [RFC v2 PATCH 0/16] Optimize this_cpu_*() ops for non-x86 (ARM64 for this series)
Date: Tue, 4 Aug 2026 23:47:03 +0200	[thread overview]
Message-ID: <ea268481-d584-4744-99d6-0b05aade7d5d@kernel.org> (raw)
In-Reply-To: <9f146ce0-4adc-0c00-a2d8-c01b47edc9d1@gentwo.org>

On 8/4/26 23:25, Christoph Lameter (Ampere) wrote:
> On Tue, 4 Aug 2026, David Hildenbrand (Arm) wrote:
> 
>>> rather hacky restart logic. It relies on a long preemable and postscript
>>> to each per cpu operations.
> 
>> But I am sure you did you homework and have data to back up your claims. Please
>> share that data, because I am very curious.
> 
> The comparison here is a single instruction on one side and abnd the per
> cpu operation prefixed with a preeamble and another instruction / set of
> instructions on the other side.
> 
> Even if its only one before and one after then we are still looking at 3
> instructions instead of one. This is a frequently used operation in the
> VM.
> 
> You need data to show that one instruction  is faster than 3???

I want you to show that the difference *matters* in *practice* enough that we
should *care* about accepting the additional *complexity*.

No hand-waving about "3 > 1". IIRC people were asking that previously but
received no results back.

So to be clear: claiming that the additional instructions are unacceptable I'd
expect something minimal like: "removing these 3 instructions speeds up
micro-benchmark (a, b, c) by X% and macro-benchmarks (d, e, f) by Y% compared to
Mark's approach".

Maybe there really is a big difference.

> 
>> Mark's solution is the obvious improvement to the problem, doing it just like
>> s390 already does.
> 
> Well there is interest by the S390 folks to move to what we proposed from
> what I can tell.

Heiko said that as reply to v1, bit he's been replying a lot on Mark's patches.
Only Heiko can tell. (on CC)

> 
> 
>> If the proposed solution has a significant benefit over Mark's solution it could
>> be discussed as a next step; and it must be backed with sufficient data to
>> warrant all this complexity here.
> 
> You cannot accept that one instruction is faster than the same
> instruction prefixed with another and something else at its tail?

I am pretty sure that you got exactly what I meant, you likely just don't have
the data to back it up.

Proof me wrong!

-- 
Cheers,

David


  reply	other threads:[~2026-08-04 21:47 UTC|newest]

Thread overview: 64+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-15 18:04 [RFC v2 PATCH 0/16] Optimize this_cpu_*() ops for non-x86 (ARM64 for this series) Yang Shi
2026-07-15 18:04 ` [PATCH 01/16] drivers: arch_numa: move percpu set up code to arch Yang Shi
2026-07-15 18:04 ` [PATCH 02/16] arm64: kconfig: make percpu related configs not depend on NUMA Yang Shi
2026-07-15 18:04 ` [PATCH 03/16] mm: pgalloc: introduce {pud|pmd}_populate_sync() Yang Shi
2026-07-15 18:04 ` [PATCH 04/16] vmalloc: pass in pgd pointer for vmap{__vunmap}_range_noflush() Yang Shi
2026-07-29  9:32   ` Lorenzo Stoakes (ARM)
2026-08-03 19:12     ` Yang Shi
2026-08-04 13:47       ` Lorenzo Stoakes (ARM)
2026-07-15 18:04 ` [PATCH 05/16] arm64: mm: enable percpu kernel page table Yang Shi
2026-07-15 18:04 ` [PATCH 06/16] arm64: mm: defined {pud|pmd}_populate_sync() Yang Shi
2026-07-15 18:04 ` [PATCH 07/16] arm64: mm: sync percpu page table for memory hotplug/unplug Yang Shi
2026-07-15 18:04 ` [PATCH 08/16] arm64: kasan: sync up kasan shadow area page table Yang Shi
2026-07-15 18:04 ` [PATCH 09/16] arm64: mm: define percpu virtual space area Yang Shi
2026-07-15 18:04 ` [PATCH 10/16] mm: percpu: prepare to use dedicated percpu area Yang Shi
2026-07-15 18:04 ` [PATCH 11/16] arm64: mm: map local percpu first chunk Yang Shi
2026-07-15 18:04 ` [PATCH 12/16] mm: percpu: set up first chunk and reserve chunk Yang Shi
2026-07-15 18:04 ` [PATCH 13/16] arm64: mm: introduce __per_cpu_local_off Yang Shi
2026-07-15 18:04 ` [PATCH 14/16] mm: percpu: allocate and free local percpu vm area Yang Shi
2026-07-15 18:04 ` [PATCH 15/16] arm64: kconfig: select HAVE_LOCAL_PER_CPU_MAP Yang Shi
2026-07-15 18:04 ` [PATCH 16/16] arm64: percpu: use local percpu for this_cpu_*() APIs Yang Shi
2026-07-16 13:23 ` [RFC v2 PATCH 0/16] Optimize this_cpu_*() ops for non-x86 (ARM64 for this series) Ryan Roberts
2026-07-21 19:08   ` Mark Rutland
2026-07-21 19:08     ` Mark Rutland
2026-07-21 23:20   ` Yang Shi
2026-07-22  9:36     ` Mark Rutland
2026-07-27 21:10       ` Yang Shi
2026-07-27 22:06       ` Christoph Lameter (Ampere)
2026-07-29  9:28         ` David Hildenbrand (Arm)
2026-08-04 14:15           ` Lorenzo Stoakes (ARM)
2026-08-04 14:21             ` Lorenzo Stoakes (ARM)
2026-08-04 14:40               ` Jason Gunthorpe
2026-08-04 18:06                 ` Matthew Wilcox
2026-08-04 18:16                   ` Jason Gunthorpe
2026-08-04 15:21             ` Linus Torvalds
2026-08-04 16:15               ` Christoph Lameter (Ampere)
2026-08-04 16:30                 ` Linus Torvalds
2026-08-04 16:54                   ` David Hildenbrand (Arm)
2026-08-04 17:01                   ` Linus Torvalds
2026-08-04 17:32                     ` Lorenzo Stoakes (ARM)
2026-08-04 21:40                       ` Christoph Lameter (Ampere)
2026-08-04 21:48                         ` David Hildenbrand (Arm)
2026-08-04 21:56                           ` Christoph Lameter (Ampere)
2026-08-04 22:01                             ` David Hildenbrand (Arm)
2026-08-05  8:16                         ` Lorenzo Stoakes (ARM)
2026-08-04 17:23                   ` Lorenzo Stoakes (ARM)
2026-08-04 17:28                     ` Linus Torvalds
2026-08-04 21:51                     ` Yang Shi
2026-08-04 22:05                       ` David Hildenbrand (Arm)
2026-08-04 22:35                         ` Christoph Lameter (Ampere)
2026-08-05  6:11                           ` David Hildenbrand (Arm)
2026-08-05 14:48                           ` Mark Rutland
2026-08-05  7:52                       ` Lorenzo Stoakes (ARM)
2026-08-06 17:15                     ` Will Deacon
2026-08-06 17:31                       ` Lorenzo Stoakes (ARM)
2026-08-04 16:19             ` Christoph Lameter (Ampere)
2026-08-04 16:47               ` David Hildenbrand (Arm)
2026-08-04 21:25                 ` Christoph Lameter (Ampere)
2026-08-04 21:47                   ` David Hildenbrand (Arm) [this message]
2026-08-04 22:01                     ` Christoph Lameter (Ampere)
2026-08-05  6:12                       ` David Hildenbrand (Arm)
2026-08-05  8:45                     ` Heiko Carstens
2026-08-05 11:10                 ` David Laight
2026-08-05 14:53         ` Mark Rutland
2026-07-30  6:06     ` [RFC v2 PATCH 0/16] Optimize this_cpu_*() ops for non-x86 (ARM64 for this series)~ Mete Durlu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ea268481-d584-4744-99d6-0b05aade7d5d@kernel.org \
    --to=david@kernel.org \
    --cc=agordeev@linux.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=catalin.marinas@arm.com \
    --cc=cl@gentwo.org \
    --cc=dennis@kernel.org \
    --cc=gor@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=jgg@nvidia.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=ljs@kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=ryan.roberts@arm.com \
    --cc=tj@kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=urezki@gmail.com \
    --cc=will@kernel.org \
    --cc=yang@os.amperecomputing.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.