3838/*********************************************************************/
3939
4040#include "common.h"
41-
42- #ifndef _MSC_VER
4341#include <strings.h>
44- #else
45- #define strncasecmp _strnicmp
46- #endif
47-
4842#if (defined OS_LINUX || defined OS_ANDROID )
4943#include <asm/hwcap.h>
5044#include <sys/auxv.h>
@@ -135,10 +129,16 @@ extern gotoblas_t gotoblas_ARMV9SME;
135129#else
136130#define gotoblas_ARMV9SME gotoblas_ARMV8
137131#endif
132+ #ifdef DYN_VORTEX
133+ extern gotoblas_t gotoblas_VORTEX ;
134+ #elif defined(DYN_NEOVERSEN1 )
135+ #define gotoblas_VORTEX gotoblas_NEOVERSEN1
136+ #else
137+ #define gotoblas_VORTEX gotoblas_ARMV8
138+ #endif
138139#ifdef DYN_VORTEXM4
139140extern gotoblas_t gotoblas_VORTEXM4 ;
140141#else
141- #error "dont have vortexm4"
142142#define gotoblas_VORTEXM4 gotoblas_ARMV8
143143#endif
144144#ifdef DYN_CORTEXA55
@@ -151,7 +151,7 @@ extern gotoblas_t gotoblas_A64FX;
151151#else
152152#define gotoblas_A64FX gotoblas_ARMV8
153153#endif
154- #else
154+ #else //not a user-specified dynamic_list
155155extern gotoblas_t gotoblas_CORTEXA53 ;
156156#define gotoblas_CORTEXA55 gotoblas_CORTEXA53
157157extern gotoblas_t gotoblas_CORTEXA57 ;
@@ -163,6 +163,7 @@ extern gotoblas_t gotoblas_THUNDERX2T99;
163163extern gotoblas_t gotoblas_TSV110 ;
164164extern gotoblas_t gotoblas_EMAG8180 ;
165165extern gotoblas_t gotoblas_NEOVERSEN1 ;
166+ #define gotoblas_VORTEX gotoblas_NEOVERSEN1
166167#ifndef NO_SVE
167168extern gotoblas_t gotoblas_NEOVERSEV1 ;
168169extern gotoblas_t gotoblas_NEOVERSEN2 ;
@@ -198,7 +199,7 @@ extern void openblas_warning(int verbose, const char * msg);
198199#define FALLBACK_VERBOSE 1
199200#define NEOVERSEN1_FALLBACK "OpenBLAS : Your OS does not support SVE instructions. OpenBLAS is using Neoverse N1 kernels as a fallback, which may give poorer performance.\n"
200201
201- #define NUM_CORETYPES 20
202+ #define NUM_CORETYPES 21
202203
203204/*
204205 * In case asm/hwcap.h is outdated on the build system, make sure
@@ -238,6 +239,7 @@ static char *corename[] = {
238239 "armv8sve" ,
239240 "a64fx" ,
240241 "armv9sme" ,
242+ "vortex" ,
241243 "vortexm4" ,
242244 "unknown"
243245};
@@ -262,7 +264,8 @@ char *gotoblas_corename(void) {
262264 if (gotoblas == & gotoblas_ARMV8SVE ) return corename [16 ];
263265 if (gotoblas == & gotoblas_A64FX ) return corename [17 ];
264266 if (gotoblas == & gotoblas_ARMV9SME ) return corename [18 ];
265- if (gotoblas == & gotoblas_VORTEXM4 ) return corename [19 ];
267+ if (gotoblas == & gotoblas_VORTEX ) return corename [19 ];
268+ if (gotoblas == & gotoblas_VORTEXM4 ) return corename [20 ];
266269 return corename [NUM_CORETYPES ];
267270}
268271
@@ -301,7 +304,8 @@ static gotoblas_t *force_coretype(char *coretype) {
301304 case 16 : return (& gotoblas_ARMV8SVE );
302305 case 17 : return (& gotoblas_A64FX );
303306 case 18 : return (& gotoblas_ARMV9SME );
304- case 19 : return (& gotoblas_VORTEXM4 );
307+ case 19 : return (& gotoblas_VORTEX );
308+ case 20 : return (& gotoblas_VORTEXM4 );
305309 }
306310 snprintf (message , 128 , "Core not found: %s\n" , coretype );
307311 openblas_warning (1 , message );
@@ -318,7 +322,7 @@ static gotoblas_t *get_coretype(void) {
318322 return & gotoblas_VORTEXM4 ;
319323 }
320324#endif
321- return & gotoblas_NEOVERSEN1 ;
325+ return & gotoblas_VORTEX ;
322326#endif
323327
324328#if (!defined OS_LINUX && !defined OS_ANDROID )
@@ -403,6 +407,8 @@ static gotoblas_t *get_coretype(void) {
403407 case 0xd08 : // Cortex A72
404408 return & gotoblas_CORTEXA72 ;
405409 case 0xd09 : // Cortex A73
410+ case 0xd0a : // Cortex A75
411+ case 0xd0b : // Cortex A76
406412 return & gotoblas_CORTEXA73 ;
407413 case 0xd0c : // Neoverse N1
408414 return & gotoblas_NEOVERSEN1 ;
@@ -492,7 +498,7 @@ static gotoblas_t *get_coretype(void) {
492498 break ;
493499 case 0x61 : // Apple
494500 if (support_sme1 ()) return & gotoblas_VORTEXM4 ;
495- return & gotoblas_NEOVERSEN1 ;
501+ return & gotoblas_VORTEX ;
496502 break ;
497503 default :
498504 snprintf (coremsg , 128 , "Unknown CPU model - implementer %x part %x\n" ,implementer ,part );
0 commit comments