From: Qu Wenruo <wqu@suse.com>
To: linux-btrfs@vger.kernel.org
Subject: [PATCH 0/2] btrfs-progs: crypto/crc32c: cleanup and reimplementation to reduce asm usage
Date: Sat, 7 Nov 2026 09:11:12 +1030 [thread overview]
Message-ID: <cover.1794003341.git.wqu@suse.com> (raw)
Although kernel is using a lot of ASM files for hardware acceleration,
we also have projects like google's crc32c
(https://github.com/google/crc32c) which doesn't have any inlined or
dedicated asm file.
The idea is that we have compiler wrappers for those instructions
already, considering how rare modern developers read/write asm code,
reducing asm code will improve readability in the long run.
The first patch is remove the inline asm usages, the second one is to
remove the only asm file for crc32-pcl optimization, and replace it with
a C function.
Qu Wenruo (2):
btrfs-progs: cleanup inline asm usage
btrfs-progs: crypto/crc32c: port crc32c-pcl optimization to C
Makefile | 14 --
common/cpu-utils.c | 31 +--
crypto/crc32c-pcl-intel-asm_64.S | 370 -------------------------------
crypto/crc32c.c | 282 +++++++++++++++++++++--
crypto/hash-speedtest.c | 14 +-
libbtrfs/crc32c.c | 43 +---
6 files changed, 284 insertions(+), 470 deletions(-)
delete mode 100644 crypto/crc32c-pcl-intel-asm_64.S
--
2.56.0
next reply other threads:[~2026-11-06 22:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-06 22:41 Qu Wenruo [this message]
2026-11-06 22:41 ` [PATCH 1/2] btrfs-progs: cleanup inline asm usage Qu Wenruo
2026-11-06 22:41 ` [PATCH 2/2] btrfs-progs: crypto/crc32c: port crc32c-pcl optimization to C Qu Wenruo
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.1794003341.git.wqu@suse.com \
--to=wqu@suse.com \
--cc=linux-btrfs@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