All of lore.kernel.org
 help / color / mirror / Atom feed
From: Corey Minyard <minyard@acm.org>
To: Marc Zyngier <maz@kernel.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will@kernel.org>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	Corey Minyard <cminyard@mvista.com>
Subject: Re: [PATCH v2] arm64:kgdb: Fix kernel single-stepping
Date: Thu, 20 Feb 2020 08:50:48 -0600	[thread overview]
Message-ID: <20200220145048.GH3704@minyard.net> (raw)
In-Reply-To: <1416dca51b52dff349923184f41d48e8@kernel.org>

On Thu, Feb 20, 2020 at 02:21:36PM +0000, Marc Zyngier wrote:
> On 2020-02-19 15:24, minyard@acm.org wrote:
> > From: Corey Minyard <cminyard@mvista.com>
> 
> [...]
> 
> > After studying the EL0 handling for this, I realized an issue with using
> > MDSCR to check if single step is enabled: it can be expensive on a VM.
> > So check the task flag first to see if single step is enabled.  Then
> > check MDSCR if the task flag is set.
> 
> Very tangential remark: I'd really like people *not* to try and optimize
> Linux based on the behaviour of a hypervisor. In general, reading a
> system register is fast, and the fact that it traps on a given hypervisor
> at some point may not be true in the future, nor be a valid assumption
> across hypervisors.

Normally I would agree, but I based this upon git commit
https://github.com/torvalds/linux/commit/2a2830703a2371b47f7b50b1d35cb15dc0e2b717
which seemed to say that it was a significant enough factor to do in the
EL0 case.

-corey

> 
>         M.
> -- 
> Jazz is not dead. It just smells funny...

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

WARNING: multiple messages have this Message-ID (diff)
From: Corey Minyard <minyard@acm.org>
To: Marc Zyngier <maz@kernel.org>
Cc: Will Deacon <will@kernel.org>,
	Catalin Marinas <catalin.marinas@arm.com>,
	linux-arm-kernel@lists.infradead.org,
	Corey Minyard <cminyard@mvista.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] arm64:kgdb: Fix kernel single-stepping
Date: Thu, 20 Feb 2020 08:50:48 -0600	[thread overview]
Message-ID: <20200220145048.GH3704@minyard.net> (raw)
In-Reply-To: <1416dca51b52dff349923184f41d48e8@kernel.org>

On Thu, Feb 20, 2020 at 02:21:36PM +0000, Marc Zyngier wrote:
> On 2020-02-19 15:24, minyard@acm.org wrote:
> > From: Corey Minyard <cminyard@mvista.com>
> 
> [...]
> 
> > After studying the EL0 handling for this, I realized an issue with using
> > MDSCR to check if single step is enabled: it can be expensive on a VM.
> > So check the task flag first to see if single step is enabled.  Then
> > check MDSCR if the task flag is set.
> 
> Very tangential remark: I'd really like people *not* to try and optimize
> Linux based on the behaviour of a hypervisor. In general, reading a
> system register is fast, and the fact that it traps on a given hypervisor
> at some point may not be true in the future, nor be a valid assumption
> across hypervisors.

Normally I would agree, but I based this upon git commit
https://github.com/torvalds/linux/commit/2a2830703a2371b47f7b50b1d35cb15dc0e2b717
which seemed to say that it was a significant enough factor to do in the
EL0 case.

-corey

> 
>         M.
> -- 
> Jazz is not dead. It just smells funny...

  reply	other threads:[~2020-02-20 14:50 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-19 15:24 [PATCH v2] arm64:kgdb: Fix kernel single-stepping minyard
2020-02-19 15:24 ` minyard
2020-02-20 14:06 ` Daniel Thompson
2020-02-20 14:06   ` Daniel Thompson
2020-02-20 14:52   ` Corey Minyard
2020-02-20 14:52     ` Corey Minyard
2020-02-20 14:21 ` Marc Zyngier
2020-02-20 14:21   ` Marc Zyngier
2020-02-20 14:50   ` Corey Minyard [this message]
2020-02-20 14:50     ` Corey Minyard
2020-02-20 15:06     ` Marc Zyngier
2020-02-20 15:06       ` Marc Zyngier
2020-02-20 14:22 ` Will Deacon
2020-02-20 14:22   ` Will Deacon
2020-02-20 16:30   ` Corey Minyard
2020-02-20 16:30     ` Corey Minyard
2020-02-20 21:30     ` Corey Minyard
2020-02-20 21:30       ` Corey Minyard
2020-02-24 18:07       ` James Morse
2020-02-24 18:07         ` James Morse
2020-02-25 15:38         ` Corey Minyard
2020-02-25 15:38           ` Corey Minyard
2020-02-25 17:55           ` James Morse
2020-02-25 17:55             ` James Morse
2020-02-26  2:58             ` Corey Minyard
2020-02-26  2:58               ` Corey Minyard

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=20200220145048.GH3704@minyard.net \
    --to=minyard@acm.org \
    --cc=catalin.marinas@arm.com \
    --cc=cminyard@mvista.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maz@kernel.org \
    --cc=will@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 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.