From: Alfie Richards Date: Mon, 27 Oct 2025 17:49:07 +0000 (+0000) Subject: AArch64: Fix mv-cmpu-features.C test that fails on older glibc's [PR 122405] X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=7d6fc99bd0d963e3acfae6987db9ba4c3ca869ac;p=thirdparty%2Fgcc.git AArch64: Fix mv-cmpu-features.C test that fails on older glibc's [PR 122405] Adds a definition of HWCAP_ATOMICS and HWCAP2_RNG in the test file for the case that the glibc is old enough to not include them. PR target/122405 gcc/testsuite/ChangeLog: * g++.target/aarch64/mv-cpu-features.C: Add HWCAP_ATOMICS and HWCAP2_RNG defines. --- diff --git a/gcc/testsuite/g++.target/aarch64/mv-cpu-features.C b/gcc/testsuite/g++.target/aarch64/mv-cpu-features.C index ad6accd4c63..56e29163524 100644 --- a/gcc/testsuite/g++.target/aarch64/mv-cpu-features.C +++ b/gcc/testsuite/g++.target/aarch64/mv-cpu-features.C @@ -41,6 +41,14 @@ int impl () #define _IFUNC_ARG_HWCAP (1ULL << 62) #endif +#ifndef HWCAP_ATOMICS +#define HWCAP_ATOMICS (1 << 8) +#endif + +#ifndef HWCAP2_RNG +#define HWCAP2_RNG (1 << 16) +#endif + extern "C" void __init_cpu_features_resolver (unsigned long hwcap, const ifunc_arg_t *arg);