Subject: cksum crc broken with VMULL on musl

From: Alyssa Ross <[email-masked]>
Date: Mon, 17 Feb 2025 10:26:15 +0100

On aarch64-unknown-linux-musl, cksum -a crc seems to be producing the
wrong values with coreutils 9.6, causing tests/cksum/cksum.sh to fail.
I bisected this to the following commit:

commit d155be4a22cdc5d271a74c2ae8226c4239ab76ed (HEAD)
Author: Sam Russell <[email-masked]>
Date:   Thu Nov 28 20:28:21 2024 +0100

    cksum: use ARMv8 SIMD extensions
    
    * configure.ac: Add check for ARMv8 VMULL support.
    * src/cksum.c: Add ARMv8 VMULL detection function.
    * src/cksum.h: Add ARMv8 VMULL implementation declaration.
    * src/cksum_vmull.c: ARMv8 VMULL implementation.
    * src/local.mk: Add build flags for ARMv8 VMULL.
    * NEWS: Mention the ARMv8 SIMD improvement.

If I configure with utils_cv_vmull_intrinsic_exists=no the test passes.
Relevant portion of test-suite.log follows.  I think the "missing: No
such file or directory" is an unrelated incorrect use of the _returns
function?

FAIL: tests/cksum/cksum
=======================

cksum: missing: No such file or directory
--- exp	2025-02-17 09:18:57.198429856 +0000
+++ out	2025-02-17 09:18:57.198429856 +0000
@@ -1 +1 @@
-3720986905 65574 in
+2108650022 65574 in
--- exp	2025-02-17 09:18:57.202429997 +0000
+++ out	2025-02-17 09:18:57.202429997 +0000
@@ -1 +1 @@
-4278270357 65664 in
+1411087274 65664 in
FAIL tests/cksum/cksum.sh (exit status: 1)