[compiler-rt] compiler-rt: Use OpenBSD's elf_aux_info to detect AArch64 HW features (PR #155768)
Brad Smith via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 27 23:57:37 PDT 2025
https://github.com/brad0 created https://github.com/llvm/llvm-project/pull/155768
None
>From 296ea991fd18f61be8ba5dc7098a5b576211b497 Mon Sep 17 00:00:00 2001
From: Brad Smith <brad at comstyle.com>
Date: Thu, 28 Aug 2025 02:55:37 -0400
Subject: [PATCH] compiler-rt: Use OpenBSD's elf_aux_info to detect AArch64 HW
features
---
compiler-rt/lib/builtins/cpu_model/aarch64.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/compiler-rt/lib/builtins/cpu_model/aarch64.c b/compiler-rt/lib/builtins/cpu_model/aarch64.c
index f41c9301dc6a4..d7880529ebe70 100644
--- a/compiler-rt/lib/builtins/cpu_model/aarch64.c
+++ b/compiler-rt/lib/builtins/cpu_model/aarch64.c
@@ -34,7 +34,7 @@ typedef struct __ifunc_arg_t {
_Bool __aarch64_have_lse_atomics
__attribute__((visibility("hidden"), nocommon)) = false;
-#if defined(__FreeBSD__)
+#if defined(__FreeBSD__) || defined(__OpenBSD__)
// clang-format off: should not reorder sys/auxv.h alphabetically
#include <sys/auxv.h>
// clang-format on
@@ -68,7 +68,7 @@ struct {
// clang-format off
#if defined(__APPLE__)
#include "aarch64/fmv/apple.inc"
-#elif defined(__FreeBSD__)
+#elif defined(__FreeBSD__) || defined(__OpenBSD__)
#include "aarch64/fmv/mrs.inc"
#include "aarch64/fmv/elf_aux_info.inc"
#elif defined(__Fuchsia__)
More information about the llvm-commits
mailing list