]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
aarch64: Fix tst-ifunc-arg-4 on clang-18
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>
Tue, 28 Oct 2025 17:08:37 +0000 (14:08 -0300)
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>
Wed, 29 Oct 2025 15:54:10 +0000 (12:54 -0300)
It issues:

../sysdeps/aarch64/tst-ifunc-arg-4.c:39:1: error: unused function 'resolver' [-Werror,-Wunused-function]
   39 | resolver (uint64_t arg0, const uint64_t arg1[])
      | ^~~~~~~~
1 error generated.

clang-19 and onwards do not trigger the warning.

Reviewed-by: H.J. Lu <hjl.tools@gmail.com>
sysdeps/aarch64/tst-ifunc-arg-4.c

index c95ef9ebb3a304d4c81866a52ff0b2f8c41aefa2..9536d1e8e052a986e3362ec34c8883499920f782 100644 (file)
@@ -35,7 +35,7 @@ two (void)
 }
 
 /* Resolver function.  */
-static void *
+static __attribute_used__ void *
 resolver (uint64_t arg0, const uint64_t arg1[])
 {
   uint64_t hwcap2 = __ifunc_hwcap (_IFUNC_ARG_AT_HWCAP2, arg0, arg1);