linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Matthew Wilcox <willy@infradead.org>
To: John Sanpe <sanpeqf@gmail.com>
Cc: linkinjeon@kernel.org, sj1557.seo@samsung.com,
	linux-fsdevel@vger.kernel.org, Andy.Wu@sony.com,
	Wataru.Aoyama@sony.com, cpgs@samsung.com
Subject: Re: [PATCH] exfat/balloc: using hweight instead of internal logic
Date: Mon, 4 Dec 2023 13:36:21 +0000	[thread overview]
Message-ID: <ZW3V1fmY0R2uD6tH@casper.infradead.org> (raw)
In-Reply-To: <20231204022258.1297277-1-sanpeqf@gmail.com>

On Mon, Dec 04, 2023 at 10:22:58AM +0800, John Sanpe wrote:
> Replace the internal table lookup algorithm with the hweight
> library, which has instruction set acceleration.

This is undeniably better, but why stop here?  Instead of working one
byte at a time, you could work an entire word at a time and use
hweight_long().

Also, if you're in the mood for a second patch, free_bit[] is clearly
an open-coding of ffz().

  reply	other threads:[~2023-12-04 13:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-04  2:22 [PATCH] exfat/balloc: using hweight instead of internal logic John Sanpe
2023-12-04 13:36 ` Matthew Wilcox [this message]
2023-12-04 16:19   ` Fredrik Anderson

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=ZW3V1fmY0R2uD6tH@casper.infradead.org \
    --to=willy@infradead.org \
    --cc=Andy.Wu@sony.com \
    --cc=Wataru.Aoyama@sony.com \
    --cc=cpgs@samsung.com \
    --cc=linkinjeon@kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=sanpeqf@gmail.com \
    --cc=sj1557.seo@samsung.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).