Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions Makefile.system
Original file line number Diff line number Diff line change
Expand Up @@ -738,6 +738,20 @@ DYNAMIC_CORE += THUNDERX2T99
DYNAMIC_CORE += TSV110
DYNAMIC_CORE += EMAG8180
DYNAMIC_CORE += THUNDERX3T110

ifeq ($(OSNAME), Darwin)
DYNAMIC_CORE = ARMV8
DYNAMIC_CORE += NEOVERSEN1
ifneq ($(NO_SME), 1)
DYNAMIC_CORE += ARMV9SME
ifeq ($(OSNAME), Darwin)
ifneq ($(C_COMPILER), GCC)
DYNAMIC_CORE += VORTEXM4
endif
endif
endif
endif

ifdef DYNAMIC_LIST
override DYNAMIC_CORE = ARMV8 $(DYNAMIC_LIST)
XCCOMMON_OPT = -DDYNAMIC_LIST -DDYN_ARMV8
Expand Down
8 changes: 8 additions & 0 deletions cmake/arch.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,14 @@ if (DYNAMIC_ARCH)
endif()
endif()
endif ()

if (${CMAKE_SYSTEM_NAME} STREQUAL "Darwin" OR ${CMAKE_SYSTEM_NAME} STREQUAL "iOS")
set(DYNAMIC_CORE ARMV8 NEOVERSEN1)
if (${CMAKE_C_COMPILER_VERSION} VERSION_GREATER_EQUAL 19 OR (${CMAKE_C_COMPILER_ID} MATCHES AppleClang AND ${CMAKE_C_COMPILER_VERSION} VERSION_GREATER_EQUAL 17) ) # SME ACLE supported in LLVM >= 19 and AppleClang >= 17
set(DYNAMIC_CORE ${DYNAMIC_CORE} ARMV9SME VORTEXM4)
endif()
endif()

if (DYNAMIC_LIST)
set(DYNAMIC_CORE ARMV8 ${DYNAMIC_LIST})
endif ()
Expand Down
27 changes: 26 additions & 1 deletion driver/others/dynamic_arm64.c
Original file line number Diff line number Diff line change
Expand Up @@ -151,19 +151,39 @@ extern gotoblas_t gotoblas_A64FX;
#else
#define gotoblas_A64FX gotoblas_ARMV8
#endif

#else //not a user-specified dynamic_list

#ifdef OS_DARWIN
#define gotoblas_CORTEXA53 gotoblas_ARMV8
#else
extern gotoblas_t gotoblas_CORTEXA53;
#endif
#define gotoblas_CORTEXA55 gotoblas_CORTEXA53
#ifdef OS_DARWIN
#define gotoblas_CORTEXA57 gotoblas_ARMV8
#else
extern gotoblas_t gotoblas_CORTEXA57;
#endif
#define gotoblas_CORTEXA72 gotoblas_CORTEXA57
#define gotoblas_CORTEXA73 gotoblas_CORTEXA57
#define gotoblas_FALKOR gotoblas_CORTEXA57
#ifdef OS_DARWIN
#define gotoblas_THUNDERX gotoblas_ARMV8
#define gotoblas_THUNDERX2T99 gotoblas_ARMV8
#define gotoblas_THUNDERX3T110 gotoblas_ARMV8
#define gotoblas_TSV110 gotoblas_ARMV8
#define gotoblas_EMAG8180 gotoblas_ARMV8
#else
extern gotoblas_t gotoblas_THUNDERX;
extern gotoblas_t gotoblas_THUNDERX2T99;
extern gotoblas_t gotoblas_THUNDERX3T110;
extern gotoblas_t gotoblas_TSV110;
extern gotoblas_t gotoblas_EMAG8180;
#endif
extern gotoblas_t gotoblas_NEOVERSEN1;
#define gotoblas_VORTEX gotoblas_NEOVERSEN1
#ifndef OS_DARWIN
#ifndef NO_SVE
extern gotoblas_t gotoblas_NEOVERSEV1;
extern gotoblas_t gotoblas_NEOVERSEN2;
Expand All @@ -175,6 +195,12 @@ extern gotoblas_t gotoblas_A64FX;
#define gotoblas_ARMV8SVE gotoblas_ARMV8
#define gotoblas_A64FX gotoblas_ARMV8
#endif
#else
#define gotoblas_NEOVERSEV1 gotoblas_ARMV8
#define gotoblas_NEOVERSEN2 gotoblas_ARMV8
#define gotoblas_ARMV8SVE gotoblas_ARMV8
#define gotoblas_A64FX gotoblas_ARMV8
#endif
#ifndef NO_SME
extern gotoblas_t gotoblas_ARMV9SME;
#if defined (__clang__) && defined(OS_DARWIN)
Expand All @@ -191,7 +217,6 @@ extern gotoblas_t gotoblas_VORTEXM4;
#define gotoblas_VORTEXM4 gotoblas_NEOVERSEN1
#endif

extern gotoblas_t gotoblas_THUNDERX3T110;
#endif
#define gotoblas_NEOVERSEV2 gotoblas_NEOVERSEN2

Expand Down
Loading