File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -641,18 +641,22 @@ DYNAMIC_CORE += POWER8
641641ifneq ($(C_COMPILER), GCC)
642642DYNAMIC_CORE += POWER9
643643DYNAMIC_CORE += POWER10
644+ CCOMMON_OPT += -DHAVE_P10_SUPPORT
644645endif
645646ifeq ($(C_COMPILER), GCC)
646647ifeq ($(GCCVERSIONGT5), 1)
647648DYNAMIC_CORE += POWER9
648649else
649650$(info, OpenBLAS: Your gcc version is too old to build the POWER9 kernels.)
650651endif
651- ifeq ($(GCCVERSIONGTEQ11), 1)
652+ LDVERSIONGTEQ35 := $(shell expr `ld --version | head -1 | cut -f2 -d "." | cut -f1 -d "-"` >= 35)
653+ ifeq ($(GCCVERSIONGTEQ11)$(LDVERSIONGTEQ35), 11)
652654DYNAMIC_CORE += POWER10
655+ CCOMMON_OPT += -DHAVE_P10_SUPPORT
653656else ifeq ($(GCCVERSIONGTEQ10), 1)
654- ifeq ($(GCCMINORVERSIONGTEQ2), 1 )
657+ ifeq ($(GCCMINORVERSIONGTEQ2)$(LDVERSIONGTEQ35), 11 )
655658DYNAMIC_CORE += POWER10
659+ CCOMMON_OPT += -DHAVE_P10_SUPPORT
656660endif
657661else
658662$(info, OpenBLAS: Your gcc version is too old to build the POWER10 kernels.)
Original file line number Diff line number Diff line change @@ -49,6 +49,7 @@ if (DYNAMIC_ARCH)
4949
5050 if (POWER)
5151 set (DYNAMIC_CORE POWER6 POWER8 POWER9 POWER10)
52+ set (CCOMMON_OPT "${CCOMMON_OPT} -DHAVE_P10_SUPPORT" )
5253 endif ()
5354
5455 if (X86)
Original file line number Diff line number Diff line change @@ -6,10 +6,10 @@ extern gotoblas_t gotoblas_POWER8;
66#if (!defined __GNUC__ ) || ( __GNUC__ >= 6 )
77extern gotoblas_t gotoblas_POWER9 ;
88#endif
9- #if (!defined __GNUC__ ) || ( __GNUC__ >= 11 ) \
10- || (__GNUC__ == 10 && __GNUC_MINOR__ >= 2 )
11- #define HAVE_P10_SUPPORT 1
12- #endif
9+ // #if (!defined __GNUC__) || ( __GNUC__ >= 11) \
10+ // || (__GNUC__ == 10 && __GNUC_MINOR__ >= 2)
11+ // #define HAVE_P10_SUPPORT 1
12+ // #endif
1313#ifdef HAVE_P10_SUPPORT
1414extern gotoblas_t gotoblas_POWER10 ;
1515#endif
You can’t perform that action at this time.
0 commit comments