public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Claudio Imbrenda <imbrenda@linux.ibm.com>
To: Heiko Carstens <hca@linux.ibm.com>
Cc: Christian Borntraeger <borntraeger@linux.ibm.com>,
	Janosch Frank <frankja@linux.ibm.com>,
	David Hildenbrand <david@redhat.com>,
	kvm@vger.kernel.org, linux-s390@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 0/3] KVM: s390: Couple of small cmpxchg() optimizations
Date: Tue, 26 Nov 2024 13:11:44 +0100	[thread overview]
Message-ID: <20241126131144.0a076101@p-imbrenda> (raw)
In-Reply-To: <20241126102515.3178914-1-hca@linux.ibm.com>

On Tue, 26 Nov 2024 11:25:12 +0100
Heiko Carstens <hca@linux.ibm.com> wrote:

looks good, and it's a follow-up of your cmpxchg series, so I think it
should go through the s390 kernel tree

(but please try to add the comment in patch 3)

> v2:
> - Replace broken WRITE_ONCE(..., 9) with intended WRITE_ONCE(..., 0).
> 
> v1:
> Use try_cmpxchg() instead of cmpxchg() so compilers with flag output
> operand support (gcc 14 and newer) can generate slightly better code.
> 
> Also get rid of two cmpxchg() usages on one/two byte memory areas
> which generates inefficient code.
> 
> bloat-o-meter statistics of the kvm module:
> 
> add/remove: 0/0 grow/shrink: 0/11 up/down: 0/-318 (-318)
> Function                                     old     new   delta
> kvm_s390_handle_wait                         886     880      -6
> kvm_s390_gisa_destroy                        226     220      -6
> kvm_s390_gisa_clear                           96      90      -6
> ipte_unlock                                  380     372      -8
> kvm_s390_gisc_unregister                     270     260     -10
> kvm_s390_gisc_register                       290     280     -10
> gisa_vcpu_kicker                             200     190     -10
> account_mem                                  250     232     -18
> ipte_lock                                    416     368     -48
> kvm_s390_update_topology_change_report       174     122     -52
> kvm_s390_clear_local_irqs                    420     276    -144
> Total: Before=316521, After=316203, chg -0.10%
> 
> Heiko Carstens (3):
>   KVM: s390: Use try_cmpxchg() instead of cmpxchg() loops
>   KVM: s390: Remove one byte cmpxchg() usage
>   KVM: s390: Increase size of union sca_utility to four bytes
> 
>  arch/s390/include/asm/kvm_host.h | 10 +++++-----
>  arch/s390/kvm/gaccess.c          | 16 ++++++++--------
>  arch/s390/kvm/interrupt.c        | 25 ++++++++-----------------
>  arch/s390/kvm/kvm-s390.c         |  4 ++--
>  arch/s390/kvm/pci.c              |  5 ++---
>  5 files changed, 25 insertions(+), 35 deletions(-)
> 


  parent reply	other threads:[~2024-11-26 12:11 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-26 10:25 [PATCH v2 0/3] KVM: s390: Couple of small cmpxchg() optimizations Heiko Carstens
2024-11-26 10:25 ` [PATCH v2 1/3] KVM: s390: Use try_cmpxchg() instead of cmpxchg() loops Heiko Carstens
2024-11-26 10:25 ` [PATCH v2 2/3] KVM: s390: Remove one byte cmpxchg() usage Heiko Carstens
2024-11-26 10:25 ` [PATCH v2 3/3] KVM: s390: Increase size of union sca_utility to four bytes Heiko Carstens
2024-11-26 11:57   ` Claudio Imbrenda
2024-11-26 12:09   ` Janosch Frank
2024-11-26 12:21     ` Claudio Imbrenda
2024-11-26 13:33       ` Heiko Carstens
2024-11-26 12:11 ` Claudio Imbrenda [this message]
2024-11-26 12:26 ` [PATCH v2 0/3] KVM: s390: Couple of small cmpxchg() optimizations Janosch Frank

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=20241126131144.0a076101@p-imbrenda \
    --to=imbrenda@linux.ibm.com \
    --cc=borntraeger@linux.ibm.com \
    --cc=david@redhat.com \
    --cc=frankja@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-s390@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox