* [PATCH] libgcc: Add missing HWCAP entries to aarch64/cpuinfo.c
@ 2024-04-02 12:21 Wilco Dijkstra
2024-04-02 12:46 ` Richard Sandiford
0 siblings, 1 reply; 2+ messages in thread
From: Wilco Dijkstra @ 2024-04-02 12:21 UTC (permalink / raw)
To: GCC Patches; +Cc: Kyrylo Tkachov, Richard Sandiford, Richard Earnshaw
A few HWCAP entries are missing from aarch64/cpuinfo.c. This results in build errors
on older machines.
This counts a trivial build fix, but since it's late in stage 4 I'll let maintainers chip in.
OK for commit?
libgcc/
* config/aarch64/cpuinfo.c: Add HWCAP_EVTSTRM, HWCAP_CRC32, HWCAP_CPUID,
HWCAP_PACA and HWCAP_PACG.
---
diff --git a/libgcc/config/aarch64/cpuinfo.c b/libgcc/config/aarch64/cpuinfo.c
index 3c6fb8a575b423c2aff71a1a9f40812b154ee284..4b94fca869507145ec690c825f637abbc82a3493 100644
--- a/libgcc/config/aarch64/cpuinfo.c
+++ b/libgcc/config/aarch64/cpuinfo.c
@@ -52,15 +52,15 @@ struct {
#ifndef AT_HWCAP
#define AT_HWCAP 16
#endif
-#ifndef HWCAP_CPUID
-#define HWCAP_CPUID (1 << 11)
-#endif
#ifndef HWCAP_FP
#define HWCAP_FP (1 << 0)
#endif
#ifndef HWCAP_ASIMD
#define HWCAP_ASIMD (1 << 1)
#endif
+#ifndef HWCAP_EVTSTRM
+#define HWCAP_EVTSTRM (1 << 2)
+#endif
#ifndef HWCAP_AES
#define HWCAP_AES (1 << 3)
#endif
@@ -73,6 +73,9 @@ struct {
#ifndef HWCAP_SHA2
#define HWCAP_SHA2 (1 << 6)
#endif
+#ifndef HWCAP_CRC32
+#define HWCAP_CRC32 (1 << 7)
+#endif
#ifndef HWCAP_ATOMICS
#define HWCAP_ATOMICS (1 << 8)
#endif
@@ -82,6 +85,9 @@ struct {
#ifndef HWCAP_ASIMDHP
#define HWCAP_ASIMDHP (1 << 10)
#endif
+#ifndef HWCAP_CPUID
+#define HWCAP_CPUID (1 << 11)
+#endif
#ifndef HWCAP_ASIMDRDM
#define HWCAP_ASIMDRDM (1 << 12)
#endif
@@ -133,6 +139,12 @@ struct {
#ifndef HWCAP_SB
#define HWCAP_SB (1 << 29)
#endif
+#ifndef HWCAP_PACA
+#define HWCAP_PACA (1 << 30)
+#endif
+#ifndef HWCAP_PACG
+#define HWCAP_PACG (1UL << 31)
+#endif
#ifndef HWCAP2_DCPODP
#define HWCAP2_DCPODP (1 << 0)
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] libgcc: Add missing HWCAP entries to aarch64/cpuinfo.c
2024-04-02 12:21 [PATCH] libgcc: Add missing HWCAP entries to aarch64/cpuinfo.c Wilco Dijkstra
@ 2024-04-02 12:46 ` Richard Sandiford
0 siblings, 0 replies; 2+ messages in thread
From: Richard Sandiford @ 2024-04-02 12:46 UTC (permalink / raw)
To: Wilco Dijkstra; +Cc: GCC Patches, Kyrylo Tkachov, Richard Earnshaw
Wilco Dijkstra <Wilco.Dijkstra@arm.com> writes:
> A few HWCAP entries are missing from aarch64/cpuinfo.c. This results in build errors
> on older machines.
>
> This counts a trivial build fix, but since it's late in stage 4 I'll let maintainers chip in.
> OK for commit?
>
> libgcc/
> * config/aarch64/cpuinfo.c: Add HWCAP_EVTSTRM, HWCAP_CRC32, HWCAP_CPUID,
> HWCAP_PACA and HWCAP_PACG.
OK, thanks.
Richard
> ---
>
> diff --git a/libgcc/config/aarch64/cpuinfo.c b/libgcc/config/aarch64/cpuinfo.c
> index 3c6fb8a575b423c2aff71a1a9f40812b154ee284..4b94fca869507145ec690c825f637abbc82a3493 100644
> --- a/libgcc/config/aarch64/cpuinfo.c
> +++ b/libgcc/config/aarch64/cpuinfo.c
> @@ -52,15 +52,15 @@ struct {
> #ifndef AT_HWCAP
> #define AT_HWCAP 16
> #endif
> -#ifndef HWCAP_CPUID
> -#define HWCAP_CPUID (1 << 11)
> -#endif
> #ifndef HWCAP_FP
> #define HWCAP_FP (1 << 0)
> #endif
> #ifndef HWCAP_ASIMD
> #define HWCAP_ASIMD (1 << 1)
> #endif
> +#ifndef HWCAP_EVTSTRM
> +#define HWCAP_EVTSTRM (1 << 2)
> +#endif
> #ifndef HWCAP_AES
> #define HWCAP_AES (1 << 3)
> #endif
> @@ -73,6 +73,9 @@ struct {
> #ifndef HWCAP_SHA2
> #define HWCAP_SHA2 (1 << 6)
> #endif
> +#ifndef HWCAP_CRC32
> +#define HWCAP_CRC32 (1 << 7)
> +#endif
> #ifndef HWCAP_ATOMICS
> #define HWCAP_ATOMICS (1 << 8)
> #endif
> @@ -82,6 +85,9 @@ struct {
> #ifndef HWCAP_ASIMDHP
> #define HWCAP_ASIMDHP (1 << 10)
> #endif
> +#ifndef HWCAP_CPUID
> +#define HWCAP_CPUID (1 << 11)
> +#endif
> #ifndef HWCAP_ASIMDRDM
> #define HWCAP_ASIMDRDM (1 << 12)
> #endif
> @@ -133,6 +139,12 @@ struct {
> #ifndef HWCAP_SB
> #define HWCAP_SB (1 << 29)
> #endif
> +#ifndef HWCAP_PACA
> +#define HWCAP_PACA (1 << 30)
> +#endif
> +#ifndef HWCAP_PACG
> +#define HWCAP_PACG (1UL << 31)
> +#endif
>
> #ifndef HWCAP2_DCPODP
> #define HWCAP2_DCPODP (1 << 0)
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-04-02 12:46 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-02 12:21 [PATCH] libgcc: Add missing HWCAP entries to aarch64/cpuinfo.c Wilco Dijkstra
2024-04-02 12:46 ` Richard Sandiford
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).