From: Christophe Leroy <christophe.leroy@c-s.fr>
To: Benjamin Herrenschmidt <benh@kernel.crashing.org>,
Paul Mackerras <paulus@samba.org>,
Michael Ellerman <mpe@ellerman.id.au>,
Scott Wood <oss@buserror.net>
Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org
Subject: [PATCH 0/4] powerpc: Replace some bitops functions by builtin/generic ones
Date: Fri, 21 Apr 2017 13:18:44 +0200 (CEST) [thread overview]
Message-ID: <cover.1492772606.git.christophe.leroy@c-s.fr> (raw)
This patchset replaces the following bitops by builtin/generic ones:
- ffs() / __ffs()
- fls() / __fls() / fls64()
- ffz()
- __ilog2() / __ilog2_u32() / __ilog2_u64()
The current functions are written as inline assembly which prevents
GCC to optimise them in case of constant parameters and obliges GCC
to group the related instructions all together.
With the builtin alternatives, GCC optimises better
Christophe Leroy (4):
powerpc: Discard ffs()/__ffs() function and use builtin functions
instead
powerpc: Use builtin functions for fls()/__fls()/fls64()
powerpc: Replace ffz() by equivalent generic function
powerpc: remove __ilog2()s and use generic ones
arch/powerpc/Kconfig | 8 ----
arch/powerpc/include/asm/bitops.h | 87 ++++-----------------------------------
2 files changed, 7 insertions(+), 88 deletions(-)
--
2.12.0
next reply other threads:[~2017-04-21 11:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-21 11:18 Christophe Leroy [this message]
2017-04-21 11:18 ` [PATCH 1/4] powerpc: Discard ffs()/__ffs() function and use builtin functions instead Christophe Leroy
2017-06-05 10:21 ` [1/4] " Michael Ellerman
2017-04-21 11:18 ` [PATCH 2/4] powerpc: Use builtin functions for fls()/__fls()/fls64() Christophe Leroy
2017-04-21 11:18 ` [PATCH 3/4] powerpc: Replace ffz() by equivalent generic function Christophe Leroy
2017-04-21 11:18 ` [PATCH 4/4] powerpc: remove __ilog2()s and use generic ones Christophe Leroy
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=cover.1492772606.git.christophe.leroy@c-s.fr \
--to=christophe.leroy@c-s.fr \
--cc=benh@kernel.crashing.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mpe@ellerman.id.au \
--cc=oss@buserror.net \
--cc=paulus@samba.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
all inboxes | Powered by JetHome®