Linux PARISC architecture development
 help / color / mirror / Atom feed
From: Rolf Eike Beer <eike@sf-mail.de>
To: linux-parisc@vger.kernel.org
Subject: Re: [PATCH] parisc: Simplify and speed up get_user() and put_user()
Date: Mon, 11 Apr 2016 08:16:21 +0200	[thread overview]
Message-ID: <4798044.iQpCdZPV03@caliban.sf-tec.de> (raw)
In-Reply-To: <20160409062614.GA4203@ls3530.box>

[-- Attachment #1: Type: text/plain, Size: 584 bytes --]

Am Samstag, 9. April 2016, 08:26:14 schrieb Helge Deller:
> This patch simplifies the code for get_user() and put_user() a lot.
> 
> Instead of accessing kernel memory (%sr0) and userspace memory (%sr3)
> hard-coded in the assembler instruction, we now preload %sr2 with either
> %sr0 (for accessing KERNEL_DS) or with sr3 (to access USER_DS) and
> use %sr2 in the load directly.
> 
> The generated code avoids a branch and speeds up execution by generating
> less assembler instructions.

I have put this on my C3600 (Linux 4.5.0, 32 bit kernel) and I see no negative 
effects.

Eike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  reply	other threads:[~2016-04-11  6:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-09  6:26 [PATCH] parisc: Simplify and speed up get_user() and put_user() Helge Deller
2016-04-11  6:16 ` Rolf Eike Beer [this message]
2016-04-11  7:38   ` Rolf Eike Beer
2016-04-11 17:26 ` Rolf Eike Beer

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=4798044.iQpCdZPV03@caliban.sf-tec.de \
    --to=eike@sf-mail.de \
    --cc=linux-parisc@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