Skip to contentSkip to conversation

arch: Fix typo breaking use of core-avx2 arch

PATCH New Esben Haabendal 2 participants 6 messages Jun 7, 2019 – Jun 23, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 arch: Fix typo breaking use of core-avx2 arch

---
 arch/Config.in.x86 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/Config.in.x86 +1 -1
index ce91317dc6ae..3f6983ac1b63 100644
@@ -236,7 +236,7 @@ config BR2_ARCH
 	default "i686"		if BR2_x86_core2 && BR2_i386
 	default "i686"		if BR2_x86_corei7 && BR2_i386
 	default "i686"		if BR2_x86_corei7_avx && BR2_i386
-	default "i686"		if BR2_x86_corei7_avx2 && BR2_i386
+	default "i686"		if BR2_x86_core_avx2 && BR2_i386
 	default "i686"		if BR2_x86_atom && BR2_i386
 	default "i686"		if BR2_x86_silvermont && BR2_i386
 	default "i686"		if BR2_x86_opteron && BR2_i386
Signature · 1 line
2.21.0
#1 lore raw

PATCH 2/2 arch: Add support for Westmere targets

The westmere line of x86_64 targets lies between nehalem (corei7) and sandybridge (corei7-avx). Allowing use of -march=westmere enables use of AES instruction set on these targets.

---
 arch/Config.in.x86         | 10 ++++++++++
 package/openblas/Config.in |  2 +-
 2 files changed, 11 insertions(+), 1 deletion(-)
arch/Config.in.x86 +10 -0
index 3f6983ac1b63..26496b8d08e9 100644
@@ -101,6 +101,15 @@ config BR2_x86_corei7
 	select BR2_X86_CPU_HAS_SSSE3
 	select BR2_X86_CPU_HAS_SSE4
 	select BR2_X86_CPU_HAS_SSE42
+config BR2_x86_westmere
+	bool "westmere"
+	select BR2_X86_CPU_HAS_MMX
+	select BR2_X86_CPU_HAS_SSE
+	select BR2_X86_CPU_HAS_SSE2
+	select BR2_X86_CPU_HAS_SSE3
+	select BR2_X86_CPU_HAS_SSSE3
+	select BR2_X86_CPU_HAS_SSE4
+	select BR2_X86_CPU_HAS_SSE42
 config BR2_x86_corei7_avx
 	bool "corei7-avx"
 	select BR2_X86_CPU_HAS_MMX
@@ -235,6 +244,7 @@ config BR2_ARCH
 	default "i686"		if BR2_x86_nocona && BR2_i386
 	default "i686"		if BR2_x86_core2 && BR2_i386
 	default "i686"		if BR2_x86_corei7 && BR2_i386
+	default "i686"		if BR2_x86_westmere && BR2_i386
 	default "i686"		if BR2_x86_corei7_avx && BR2_i386
 	default "i686"		if BR2_x86_core_avx2 && BR2_i386
 	default "i686"		if BR2_x86_atom && BR2_i386
package/openblas/Config.in +1 -1
index 8e71a43f982c..c8a516bb9f93 100644
@@ -6,7 +6,7 @@ config BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET
 	default "PRESCOTT"     if BR2_x86_prescott || BR2_x86_nocona
 	default "BANIAS"       if BR2_x86_pentium_m
 	default "CORE2"        if BR2_x86_core2
-	default "NEHALEM"      if BR2_x86_corei7 || BR2_x86_silvermont
+	default "NEHALEM"      if BR2_x86_corei7 || BR2_x86_westmere || BR2_x86_silvermont
 	default "SANDYBRIDGE"  if BR2_x86_corei7_avx
 	default "HASWELL"      if BR2_x86_core_avx2
 	default "ATOM"         if BR2_x86_atom
Signature · 1 line
2.21.0
#2 lore raw

PATCH 2/2 arch: Add support for Westmere targets

Quoted 33 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Esben" == Esben Haabendal <[email protected]> writes:

The westmere line of x86_64 targets lies between nehalem (corei7) and sandybridge (corei7-avx). Allowing use of -march=westmere enables use of AES instruction set on these targets.

---
 arch/Config.in.x86         | 10 ++++++++++
 package/openblas/Config.in |  2 +-
 2 files changed, 11 insertions(+), 1 deletion(-)
arch/Config.in.x86 +9 -0
index 3f6983ac1b63..26496b8d08e9 100644
@@ -101,6 +101,15 @@ config BR2_x86_corei7
 	select BR2_X86_CPU_HAS_SSSE3
 	select BR2_X86_CPU_HAS_SSE4
 	select BR2_X86_CPU_HAS_SSE42
+config BR2_x86_westmere
+	bool "westmere"
+	select BR2_X86_CPU_HAS_MMX
+	select BR2_X86_CPU_HAS_SSE
+	select BR2_X86_CPU_HAS_SSE2
+	select BR2_X86_CPU_HAS_SSE3
+	select BR2_X86_CPU_HAS_SSSE3
+	select BR2_X86_CPU_HAS_SSE4
+	select BR2_X86_CPU_HAS_SSE42
 config BR2_x86_corei7_avx
 	bool "corei7-avx"
 	select BR2_X86_CPU_HAS_MMX

arch/Config.in.x86 config BR2_ARCH · line 250

Quoted 7 lines
arch/Config.in.x86 +1 -0
@@ -235,6 +244,7 @@ config BR2_ARCH
 	default "i686"		if BR2_x86_nocona && BR2_i386
 	default "i686"		if BR2_x86_core2 && BR2_i386
 	default "i686"		if BR2_x86_corei7 && BR2_i386
+	default "i686"		if BR2_x86_westmere && BR2_i386
 	default "i686"		if BR2_x86_corei7_avx && BR2_i386
 	default "i686"		if BR2_x86_core_avx2 && BR2_i386
 	default "i686"		if BR2_x86_atom && BR2_i386

No BR2_GCC_TARGET_ARCH? That doesn't seem right.

package/openblas/Config.in config BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET · line 9

Quoted 10 lines
package/openblas/Config.in +1 -1
index 8e71a43f982c..c8a516bb9f93 100644
@@ -6,7 +6,7 @@ config BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET
 	default "PRESCOTT"     if BR2_x86_prescott || BR2_x86_nocona
 	default "BANIAS"       if BR2_x86_pentium_m
 	default "CORE2"        if BR2_x86_core2
-	default "NEHALEM"      if BR2_x86_corei7 || BR2_x86_silvermont
+	default "NEHALEM"      if BR2_x86_corei7 || BR2_x86_westmere || BR2_x86_silvermont

Please put this openblas change in a separate patch. I know we don't do it consistently, but please sort these alphabetically - E.G. put westmere after silvermont.

Signature · 1 line
Bye, Peter Korsgaard
#3 lore raw

PATCH 2/2 arch: Add support for Westmere targets

Quoted 34 lines · Peter Korsgaard
Quoted 34 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Esben" == Esben Haabendal <[email protected]> writes:

The westmere line of x86_64 targets lies between nehalem (corei7) and sandybridge (corei7-avx). Allowing use of -march=westmere enables use of AES instruction set on these targets.

---
 arch/Config.in.x86         | 10 ++++++++++
 package/openblas/Config.in |  2 +-
 2 files changed, 11 insertions(+), 1 deletion(-)
arch/Config.in.x86 +9 -0
index 3f6983ac1b63..26496b8d08e9 100644
@@ -101,6 +101,15 @@ config BR2_x86_corei7
 	select BR2_X86_CPU_HAS_SSSE3
 	select BR2_X86_CPU_HAS_SSE4
 	select BR2_X86_CPU_HAS_SSE42
+config BR2_x86_westmere
+	bool "westmere"
+	select BR2_X86_CPU_HAS_MMX
+	select BR2_X86_CPU_HAS_SSE
+	select BR2_X86_CPU_HAS_SSE2
+	select BR2_X86_CPU_HAS_SSE3
+	select BR2_X86_CPU_HAS_SSSE3
+	select BR2_X86_CPU_HAS_SSE4
+	select BR2_X86_CPU_HAS_SSE42
 config BR2_x86_corei7_avx
 	bool "corei7-avx"
 	select BR2_X86_CPU_HAS_MMX
@@ -235,6 +244,7 @@ config BR2_ARCH
 	default "i686"		if BR2_x86_nocona && BR2_i386
Quoted 8 lines

arch/Config.in.x86 config BR2_ARCH · line 250

Quoted 6 lines
arch/Config.in.x86 +1 -0
 	default "i686"		if BR2_x86_core2 && BR2_i386
 	default "i686"		if BR2_x86_corei7 && BR2_i386
+	default "i686"		if BR2_x86_westmere && BR2_i386
 	default "i686"		if BR2_x86_corei7_avx && BR2_i386
 	default "i686"		if BR2_x86_core_avx2 && BR2_i386
 	default "i686"		if BR2_x86_atom && BR2_i386

No BR2_GCC_TARGET_ARCH? That doesn't seem right.

Definitely not right.

Quoted 7 lines
Quoted 7 lines
package/openblas/Config.in +0 -0
index 8e71a43f982c..c8a516bb9f93 100644
@@ -6,7 +6,7 @@ config BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET
 	default "PRESCOTT"     if BR2_x86_prescott || BR2_x86_nocona
 	default "BANIAS"       if BR2_x86_pentium_m
Quoted 8 lines
Quoted 4 lines
package/openblas/Config.in +1 -1
 	default "CORE2"        if BR2_x86_core2
-	default "NEHALEM"      if BR2_x86_corei7 || BR2_x86_silvermont
+ default "NEHALEM" if BR2_x86_corei7 || BR2_x86_westmere ||

BR2_x86_silvermont

Please put this openblas change in a separate patch. I know we don't do it consistently, but please sort these alphabetically - E.G. put westmere after silvermont.

Ok, will do.

I just tried to keep the split identical to the most recent similar change, which is 1eecd462ae05 ("arch: add Atom CPUs as Silvermont Architecture target").

Sending v2...

/Esben