From af165bc72df7b9f897b8cf68b298dac24db50516 Mon Sep 17 00:00:00 2001 From: Joao Paulo Magalhaes Date: Fri, 18 Nov 2022 14:13:32 +0000 Subject: [PATCH] [fix] fix #94: detection of __ARM_ARCH_8A__ --- changelog/current.md | 1 + src/c4/cpu.hpp | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/changelog/current.md b/changelog/current.md index cf481cb5..1fa990a9 100644 --- a/changelog/current.md +++ b/changelog/current.md @@ -43,6 +43,7 @@ - Add fully qualified ARM detection macros: - `__ARM_ARCH_7EM__` ([PR#90](https://github.com/biojppm/c4core/pull/90)). - `__ARM_ARCH_6KZ__` ([PR#93](https://github.com/biojppm/c4core/pull/93)). + - `__ARM_ARCH_8A__` ([#94](https://github.com/biojppm/c4core/issues/94)). - Improve linux and unix platform detection: detect both `__linux` and `__linux__` ([PR#92](https://github.com/biojppm/c4core/pull/92)). diff --git a/src/c4/cpu.hpp b/src/c4/cpu.hpp index 9a66278b..f8877d11 100644 --- a/src/c4/cpu.hpp +++ b/src/c4/cpu.hpp @@ -43,7 +43,9 @@ #else #define C4_CPU_ARM #define C4_WORDSIZE 4 - #if defined(__ARM_ARCH_8__) || (defined(__TARGET_ARCH_ARM) && __TARGET_ARCH_ARM >= 8) + #if defined(__ARM_ARCH_8__) || defined(__ARM_ARCH_8A__) \ + || (defined(__ARCH_ARM) && __ARCH_ARM >= 8) + || (defined(__TARGET_ARCH_ARM) && __TARGET_ARCH_ARM >= 8) \ #define C4_CPU_ARMV8 #elif defined(__ARM_ARCH_7__) || defined(_ARM_ARCH_7) \ || defined(__ARM_ARCH_7A__) || defined(__ARM_ARCH_7R__) \