Linux Btrfs filesystem development
 help / color / mirror / Atom feed
* [PATCH 0/2] btrfs-progs: crypto/crc32c: cleanup and reimplementation to reduce asm usage
@ 2026-11-06 22:41 Qu Wenruo
  2026-11-06 22:41 ` [PATCH 1/2] btrfs-progs: cleanup inline " Qu Wenruo
  2026-11-06 22:41 ` [PATCH 2/2] btrfs-progs: crypto/crc32c: port crc32c-pcl optimization to C Qu Wenruo
  0 siblings, 2 replies; 3+ messages in thread
From: Qu Wenruo @ 2026-11-06 22:41 UTC (permalink / raw)
  To: linux-btrfs

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


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-11-06 22:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-06 22:41 [PATCH 0/2] btrfs-progs: crypto/crc32c: cleanup and reimplementation to reduce asm usage Qu Wenruo
2026-11-06 22:41 ` [PATCH 1/2] btrfs-progs: cleanup inline " Qu Wenruo
2026-11-06 22:41 ` [PATCH 2/2] btrfs-progs: crypto/crc32c: port crc32c-pcl optimization to C Qu Wenruo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox