linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Dave Martin <Dave.Martin@arm.com>
To: Mark Brown <broonie@kernel.org>
Cc: Julien Grall <julien@xen.com>, Julien Grall <julien@xen.org>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Zhang Lei <zhang.lei@jp.fujitsu.com>,
	Will Deacon <will@kernel.org>,
	linux-arm-kernel@lists.infradead.org,
	Daniel Kiss <Daniel.Kiss@arm.com>
Subject: Re: [PATCH v7 1/2] arm64/sve: Split TIF_SVE into separate execute and register state flags
Date: Mon, 1 Feb 2021 15:35:53 +0000	[thread overview]
Message-ID: <20210201153550.GE13952@arm.com> (raw)
In-Reply-To: <20210201122901.11331-2-broonie@kernel.org>

On Mon, Feb 01, 2021 at 12:29:00PM +0000, Mark Brown wrote:
> Currently we have a single flag TIF_SVE which says that a task is
> allowed to execute SVE instructions without trapping and also that full
> SVE register state is stored for the task.  This results in us doing
> extra work storing and restoring the full SVE register state even in
> those cases where the ABI is that only the first 128 bits of the Z0-V31
> registers which are shared with the FPSIMD V0-V31 are valid.
> 
> In order to allow us to avoid these overheads split TIF_SVE up so that
> we have two separate flags, TIF_SVE_EXEC which allows execution of SVE
> instructions without trapping and TIF_SVE_FULL_REGS which indicates that
> the full SVE register state is stored.  If both are set the behaviour is
> as currently, if TIF_SVE_EXEC is set without TIF_SVE_FULL_REGS then we
> save and restore only the FPSIMD registers until we return to userspace
> with TIF_SVE_EXEC enabled at which point we convert the FPSIMD registers
> to SVE.  It is not meaningful to have TIF_SVE_FULL_REGS set without
> TIF_SVE_EXEC.
> 
> This patch is intended only to split the flags, it does not take
> avantage of the ability to set the flags independently and the new
> state with TIF_SVE_EXEC only should not be observed.
> 
> This is based on earlier work by Julien Gral implementing a slightly
> different approach.
> 
> Signed-off-by: Mark Brown <broonie@kernel.org>

While I'm trying to get my head around this, can you sketch out the
mapping between the old flag combinations (including Julien's
TIF_SVE_NEEDS_FLUSH) and yours?

[...]

Cheers
---Dave

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-02-01 15:37 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-01 12:28 [PATCH v7 0/2] arm64/sve: Improve performance when handling SVE access traps Mark Brown
2021-02-01 12:29 ` [PATCH v7 1/2] arm64/sve: Split TIF_SVE into separate execute and register state flags Mark Brown
2021-02-01 15:35   ` Dave Martin [this message]
2021-02-01 15:45     ` Mark Brown
2021-02-09 17:59   ` Dave Martin
2021-02-09 22:16     ` Mark Brown
2021-02-10 19:52       ` Mark Brown
2021-02-10 10:56   ` Dave Martin
2021-02-10 14:54     ` Mark Brown
2021-02-10 15:42       ` Dave Martin
2021-02-10 17:14         ` Mark Brown
2021-02-10 18:15           ` Dave Martin
2021-02-01 12:29 ` [PATCH v7 2/2] arm64/sve: Rework SVE trap access to minimise memory access Mark Brown
2021-02-10 11:09   ` Dave Martin
2021-02-10 17:54     ` Mark Brown
2021-02-08 17:26 ` [PATCH v7 0/2] arm64/sve: Improve performance when handling SVE access traps Dave Martin
2021-02-09 18:22   ` Mark Brown

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=20210201153550.GE13952@arm.com \
    --to=dave.martin@arm.com \
    --cc=Daniel.Kiss@arm.com \
    --cc=broonie@kernel.org \
    --cc=catalin.marinas@arm.com \
    --cc=julien@xen.com \
    --cc=julien@xen.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=will@kernel.org \
    --cc=zhang.lei@jp.fujitsu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).