From: Christoffer Dall <christoffer.dall@linaro.org>
To: Marc Zyngier <marc.zyngier@arm.com>
Cc: kvm@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
kvmarm@lists.cs.columbia.edu
Subject: Re: [RFC PATCH] arm64: KVM: remove fpsimd save/restore from the world switch
Date: Fri, 10 Apr 2015 11:12:15 +0200 [thread overview]
Message-ID: <20150410091215.GC6186@cbox> (raw)
In-Reply-To: <1428598439-5217-1-git-send-email-marc.zyngier@arm.com>
On Thu, Apr 09, 2015 at 05:53:59PM +0100, Marc Zyngier wrote:
> The world switch spends quite some time dealing with the FP/SIMD
> registers, as the state is quite sizeable (32 128bit registers,
> plus some crumbs on the side). We save/restore them on each
> entry/exit, so that both the host and the guest always see
> the state they expect.
>
> But let's face it: the host kernel doesn't care. It is the host
> userspace that actually cares about FP. An obvious improvement is
> to remove the save/restore from the world switch, and only perform
> it when we're about to enter/exit the guest (by plugging it into
> vcpu_load/vcpu_put). The effect is pretty spectacular when running
> hackbench (which is the only benchmark worth looking at):
>
so the kernel never uses fp/simd registers for stuff like memcopies
etc.?
Can we also make a similar change for ARM on the 32-bit side?
-Christoffer
WARNING: multiple messages have this Message-ID (diff)
From: christoffer.dall@linaro.org (Christoffer Dall)
To: linux-arm-kernel@lists.infradead.org
Subject: [RFC PATCH] arm64: KVM: remove fpsimd save/restore from the world switch
Date: Fri, 10 Apr 2015 11:12:15 +0200 [thread overview]
Message-ID: <20150410091215.GC6186@cbox> (raw)
In-Reply-To: <1428598439-5217-1-git-send-email-marc.zyngier@arm.com>
On Thu, Apr 09, 2015 at 05:53:59PM +0100, Marc Zyngier wrote:
> The world switch spends quite some time dealing with the FP/SIMD
> registers, as the state is quite sizeable (32 128bit registers,
> plus some crumbs on the side). We save/restore them on each
> entry/exit, so that both the host and the guest always see
> the state they expect.
>
> But let's face it: the host kernel doesn't care. It is the host
> userspace that actually cares about FP. An obvious improvement is
> to remove the save/restore from the world switch, and only perform
> it when we're about to enter/exit the guest (by plugging it into
> vcpu_load/vcpu_put). The effect is pretty spectacular when running
> hackbench (which is the only benchmark worth looking at):
>
so the kernel never uses fp/simd registers for stuff like memcopies
etc.?
Can we also make a similar change for ARM on the 32-bit side?
-Christoffer
next prev parent reply other threads:[~2015-04-10 9:04 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-09 16:53 [RFC PATCH] arm64: KVM: remove fpsimd save/restore from the world switch Marc Zyngier
2015-04-09 16:53 ` Marc Zyngier
2015-04-10 8:41 ` Paolo Bonzini
2015-04-10 8:41 ` Paolo Bonzini
2015-04-10 9:11 ` Marc Zyngier
2015-04-10 9:11 ` Marc Zyngier
2015-04-10 9:13 ` Paolo Bonzini
2015-04-10 9:13 ` Paolo Bonzini
2015-04-10 9:40 ` Marc Zyngier
2015-04-10 9:40 ` Marc Zyngier
2015-04-10 10:01 ` Peter Maydell
2015-04-10 10:01 ` Peter Maydell
2015-04-10 10:08 ` Marc Zyngier
2015-04-10 10:08 ` Marc Zyngier
2015-04-10 10:20 ` Catalin Marinas
2015-04-10 10:20 ` Catalin Marinas
2015-04-10 9:12 ` Christoffer Dall [this message]
2015-04-10 9:12 ` Christoffer Dall
2015-04-10 9:36 ` Marc Zyngier
2015-04-10 9:36 ` Marc Zyngier
2015-04-13 12:57 ` Christoffer Dall
2015-04-13 12:57 ` Christoffer Dall
2015-04-13 14:12 ` Marc Zyngier
2015-04-13 14:12 ` Marc Zyngier
2015-04-13 14:26 ` Christoffer Dall
2015-04-13 14:26 ` Christoffer Dall
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=20150410091215.GC6186@cbox \
--to=christoffer.dall@linaro.org \
--cc=kvm@vger.kernel.org \
--cc=kvmarm@lists.cs.columbia.edu \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=marc.zyngier@arm.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.