Skip to contentSkip to conversation

tune-core2: use n270 instead of core2duo

PATCH In review Anuj Mittal 4 participants 7 messages Sep 13, 2018 – Sep 14, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tune-core2: use n270 instead of core2duo

Fixes warnings in builds using core2-32 tune:

warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.syscall [bit 11]
warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.lm [bit 29]

when executing postinsts using qemu-i386.

i386 target doesn't enable CPUID_EXT2_SYSCALL and CPUID_EXT2_LM [1] while cpu choice of core2duo that we use for core2-32 TUNE does [2]. Use n270 cpu instead to use with qemu which supports SSSE3 and doesn't have these bits enabled [3].

[1] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L739
[2] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1439
[3] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1603

Fixes [YOCTO #12916]

---
 meta/conf/machine/include/tune-core2.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/conf/machine/include/tune-core2.inc +1 -1
index c686bb4682..ddde719bde 100644
@@ -21,7 +21,7 @@ TUNE_FEATURES_tune-core2-32 = "${TUNE_FEATURES_tune-x86} core2"
 BASE_LIB_tune-core2-32 = "lib"
 TUNE_PKGARCH_tune-core2-32 = "core2-32"
 PACKAGE_EXTRA_ARCHS_tune-core2-32 = "${PACKAGE_EXTRA_ARCHS_tune-i686} core2-32"
-QEMU_EXTRAOPTIONS_core2-32 = " -cpu core2duo"
+QEMU_EXTRAOPTIONS_core2-32 = " -cpu n270"
 
 AVAILTUNES += "core2-64"
 TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
Signature · 1 line
2.17.1
#1 lore raw
Quoted 12 lines · Anuj Mittal

Fixes warnings in builds using core2-32 tune:

warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.syscall [bit 11]
warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.lm [bit 29]

when executing postinsts using qemu-i386.

i386 target doesn't enable CPUID_EXT2_SYSCALL and CPUID_EXT2_LM [1] while cpu choice of core2duo that we use for core2-32 TUNE does [2]. Use n270 cpu instead to use with qemu which supports SSSE3 and doesn't have these bits enabled [3].

Quoted 5 lines

[1] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L739
[2] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1439
[3] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1603

Fixes [YOCTO #12916]

Is this working around a bug in qemu?

Quoted 25 lines
 meta/conf/machine/include/tune-core2.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/conf/machine/include/tune-core2.inc +1 -2
index c686bb4682..ddde719bde 100644
@@ -21,7 +21,7 @@ TUNE_FEATURES_tune-core2-32 = "${TUNE_FEATURES_tune-x86} core2"
 BASE_LIB_tune-core2-32 = "lib"
 TUNE_PKGARCH_tune-core2-32 = "core2-32"
 PACKAGE_EXTRA_ARCHS_tune-core2-32 = "${PACKAGE_EXTRA_ARCHS_tune-i686} core2-32"
-QEMU_EXTRAOPTIONS_core2-32 = " -cpu core2duo"
+QEMU_EXTRAOPTIONS_core2-32 = " -cpu n270"
 
 AVAILTUNES += "core2-64"
 TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
--

2.17.1

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#2 lore raw

Is this different issue than what was discussed in:
https://www.mail-archive.com/[email protected]/msg109516.html

The message is slightly different (might be changed in newer qemu used now), but the issue I had before was that features of selected -cpu and host cpu didn't match and qemu failed with:
qemu-system-x86_64: warning: host doesn't support requested feature:
CPUID.01H:EDX.ss [bit 27]
when some features were missing and kvm was used.

If it's the same root cause, then it's not a bug in qemu.

Quoted 58 lines · Andre McCurdy
Quoted 3 lines · Anuj Mittal

Fixes warnings in builds using core2-32 tune:

warning: TCG doesn't support requested feature:

CPUID.80000001H:EDX.syscall [bit 11]

Quoted 1 line

warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.lm

[bit 29]

Quoted 8 lines

when executing postinsts using qemu-i386.

i386 target doesn't enable CPUID_EXT2_SYSCALL and CPUID_EXT2_LM [1] while cpu choice of core2duo that we use for core2-32 TUNE does [2]. Use n270 cpu instead to use with qemu which supports SSSE3 and doesn't have these bits enabled [3].

Quoted 5 lines

[1] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L739
[2] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1439
[3] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1603

Fixes [YOCTO #12916]

Is this working around a bug in qemu?

Review

Quoted 5 lines
 meta/conf/machine/include/tune-core2.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
(quoted diff) +0 -0

b/meta/conf/machine/include/tune-core2.inc

meta/conf/machine/include/tune-core2.inc TUNE_FEATURES_tune-core2-32 =

Quoted 4 lines

index c686bb4682..ddde719bde 100644

meta/conf/machine/include/tune-core2.inc +0 -0
@@ -21,7 +21,7 @@ TUNE_FEATURES_tune-core2-32 =

"${TUNE_FEATURES_tune-x86} core2"

meta/conf/machine/include/tune-core2.inc TUNE_FEATURES_tune-core2-32 = "${TUNE_FEATURES_tune-x86} core2"

Quoted 3 lines
meta/conf/machine/include/tune-core2.inc +0 -0
 BASE_LIB_tune-core2-32 = "lib"
 TUNE_PKGARCH_tune-core2-32 = "core2-32"
 PACKAGE_EXTRA_ARCHS_tune-core2-32 = "${PACKAGE_EXTRA_ARCHS_tune-i686}

core2-32"

Quoted 8 lines
meta/conf/machine/include/tune-core2.inc +1 -2
-QEMU_EXTRAOPTIONS_core2-32 = " -cpu core2duo"
+QEMU_EXTRAOPTIONS_core2-32 = " -cpu n270"
 
 AVAILTUNES += "core2-64"
 TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
--

2.17.1

Quoted 5 lines

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#3 lore raw
Quoted 11 lines · Martin Jansa

Is this different issue than what was discussed in:
https://www.mail-archive.com/[email protected]/msg109516.html

The message is slightly different (might be changed in newer qemu used now), but the issue I had before was that features of selected -cpu and host cpu didn't match and qemu failed with:
qemu-system-x86_64: warning: host doesn't support requested feature:
CPUID.01H:EDX.ss [bit 27]
when some features were missing and kvm was used.

If it's the same root cause, then it's not a bug in qemu.

Thanks. Looks like it could be the same issue - if qemu is running with KVM on a host which isn't natively compatible with the full core2duo feature set.

From the Yocto bug these warnings are coming from the nightly builds:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=12916

Has something changed recently? Have the nightly builds moved onto an AMD machine?

Quoted 59 lines · Andre McCurdy
Quoted 58 lines
Quoted 14 lines · Anuj Mittal

Fixes warnings in builds using core2-32 tune:

warning: TCG doesn't support requested feature:
CPUID.80000001H:EDX.syscall [bit 11]
warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.lm [bit 29]

when executing postinsts using qemu-i386.

i386 target doesn't enable CPUID_EXT2_SYSCALL and CPUID_EXT2_LM [1] while cpu choice of core2duo that we use for core2-32 TUNE does [2]. Use n270 cpu instead to use with qemu which supports SSSE3 and doesn't have these bits enabled [3].

Quoted 5 lines

[1] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L739
[2] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1439
[3] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1603

Fixes [YOCTO #12916]

Is this working around a bug in qemu?

Quoted 23 lines
 meta/conf/machine/include/tune-core2.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/conf/machine/include/tune-core2.inc +0 -0
index c686bb4682..ddde719bde 100644
@@ -21,7 +21,7 @@ TUNE_FEATURES_tune-core2-32 =

"${TUNE_FEATURES_tune-x86} core2"
BASE_LIB_tune-core2-32 = "lib"
TUNE_PKGARCH_tune-core2-32 = "core2-32" PACKAGE_EXTRA_ARCHS_tune-core2-32 = "${PACKAGE_EXTRA_ARCHS_tune-i686}
core2-32"

meta/conf/machine/include/tune-core2.inc +1 -2
-QEMU_EXTRAOPTIONS_core2-32 = " -cpu core2duo"
+QEMU_EXTRAOPTIONS_core2-32 = " -cpu n270"
 
 AVAILTUNES += "core2-64"
 TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
--

2.17.1

Quoted 5 lines

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#4 lore raw
Quoted 11 lines · Andre McCurdy
Quoted 10 lines · Martin Jansa

Is this different issue than what was discussed in:
https://www.mail-archive.com/[email protected]/msg109516.html

The message is slightly different (might be changed in newer qemu used now), but the issue I had before was that features of selected -cpu and host cpu didn't match and qemu failed with:
qemu-system-x86_64: warning: host doesn't support requested feature:
CPUID.01H:EDX.ss [bit 27]
when some features were missing and kvm was used.

The message is different in this case because that one was for KVM, this one is when using user space emulation so it's checking what can be emulated and what is being asked by way of -cpu parameter [1].

Quoted 5 lines
Quoted 1 line

If it's the same root cause, then it's not a bug in qemu.

Thanks. Looks like it could be the same issue - if qemu is running with KVM on a host which isn't natively compatible with the full core2duo feature set.

Similar problem, but a different issue in my opinion. So these features (lm, syscall) that we see warnings about are only seen when building for 32 bit while running qemu-i386 for executing postinsts.

Looking at qemu commit logs, it doesn't look like these two features are supported with qemu-i386. So, I changed the qemu -cpu value that is used with qemu-i386 to a lower denominator which still supports the instruction set that we build for for 32 bit.

[1] https://wiki.qemu.org/Documentation/TCG
[2]
https://github.com/qemu/qemu/commit/4586f157757acc5c8edcc954289c7aa51661235c

Quoted 68 lines

From the Yocto bug these warnings are coming from the nightly builds:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=12916

Has something changed recently? Have the nightly builds moved onto an AMD machine?

Quoted 59 lines · Andre McCurdy
Quoted 58 lines
Quoted 14 lines · Anuj Mittal

Fixes warnings in builds using core2-32 tune:

warning: TCG doesn't support requested feature:
CPUID.80000001H:EDX.syscall [bit 11]
warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.lm [bit 29]

when executing postinsts using qemu-i386.

i386 target doesn't enable CPUID_EXT2_SYSCALL and CPUID_EXT2_LM [1] while cpu choice of core2duo that we use for core2-32 TUNE does [2]. Use n270 cpu instead to use with qemu which supports SSSE3 and doesn't have these bits enabled [3].

Quoted 5 lines

[1] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L739
[2] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1439
[3] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1603

Fixes [YOCTO #12916]

Is this working around a bug in qemu?

Quoted 23 lines
 meta/conf/machine/include/tune-core2.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/conf/machine/include/tune-core2.inc +0 -0
index c686bb4682..ddde719bde 100644
@@ -21,7 +21,7 @@ TUNE_FEATURES_tune-core2-32 =

"${TUNE_FEATURES_tune-x86} core2"
BASE_LIB_tune-core2-32 = "lib"
TUNE_PKGARCH_tune-core2-32 = "core2-32" PACKAGE_EXTRA_ARCHS_tune-core2-32 = "${PACKAGE_EXTRA_ARCHS_tune-i686}
core2-32"

meta/conf/machine/include/tune-core2.inc +1 -2
-QEMU_EXTRAOPTIONS_core2-32 = " -cpu core2duo"
+QEMU_EXTRAOPTIONS_core2-32 = " -cpu n270"
 
 AVAILTUNES += "core2-64"
 TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
--

2.17.1

Quoted 5 lines

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#5 lore raw
Quoted 23 lines · Anuj Mittal
Quoted 11 lines · Andre McCurdy
Quoted 10 lines · Martin Jansa

Is this different issue than what was discussed in:
https://www.mail-archive.com/[email protected]/msg109516.html

The message is slightly different (might be changed in newer qemu used now), but the issue I had before was that features of selected -cpu and host cpu didn't match and qemu failed with:
qemu-system-x86_64: warning: host doesn't support requested feature:
CPUID.01H:EDX.ss [bit 27]
when some features were missing and kvm was used.

The message is different in this case because that one was for KVM, this one is when using user space emulation so it's checking what can be emulated and what is being asked by way of -cpu parameter [1].

Quoted 5 lines
Quoted 1 line

If it's the same root cause, then it's not a bug in qemu.

Thanks. Looks like it could be the same issue - if qemu is running with KVM on a host which isn't natively compatible with the full core2duo feature set.

Quoted 8 lines

Similar problem, but a different issue in my opinion. So these features (lm, syscall) that we see warnings about are only seen when building for 32 bit while running qemu-i386 for executing postinsts.

Looking at qemu commit logs, it doesn't look like these two features are supported with qemu-i386. So, I changed the qemu -cpu value that is used with qemu-i386 to a lower denominator which still supports the instruction set that we build for for 32 bit.

If KVM isn't involved then it does look like a qemu bug, ie the -cpu core2duo option enables features which the emulator doesn't support.

Right?

Quoted 73 lines

[1] https://wiki.qemu.org/Documentation/TCG
[2]
https://github.com/qemu/qemu/commit/4586f157757acc5c8edcc954289c7aa51661235c

Quoted 68 lines

From the Yocto bug these warnings are coming from the nightly builds:

https://bugzilla.yoctoproject.org/show_bug.cgi?id=12916

Has something changed recently? Have the nightly builds moved onto an AMD machine?

Quoted 59 lines · Andre McCurdy
Quoted 58 lines
Quoted 14 lines · Anuj Mittal

Fixes warnings in builds using core2-32 tune:

warning: TCG doesn't support requested feature:
CPUID.80000001H:EDX.syscall [bit 11]
warning: TCG doesn't support requested feature: CPUID.80000001H:EDX.lm [bit 29]

when executing postinsts using qemu-i386.

i386 target doesn't enable CPUID_EXT2_SYSCALL and CPUID_EXT2_LM [1] while cpu choice of core2duo that we use for core2-32 TUNE does [2]. Use n270 cpu instead to use with qemu which supports SSSE3 and doesn't have these bits enabled [3].

Quoted 5 lines

[1] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L739
[2] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1439
[3] https://github.com/qemu/qemu/blob/master/target/i386/cpu.c#L1603

Fixes [YOCTO #12916]

Is this working around a bug in qemu?

Quoted 23 lines
 meta/conf/machine/include/tune-core2.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/conf/machine/include/tune-core2.inc +0 -0
index c686bb4682..ddde719bde 100644
@@ -21,7 +21,7 @@ TUNE_FEATURES_tune-core2-32 =

"${TUNE_FEATURES_tune-x86} core2"
BASE_LIB_tune-core2-32 = "lib"
TUNE_PKGARCH_tune-core2-32 = "core2-32" PACKAGE_EXTRA_ARCHS_tune-core2-32 = "${PACKAGE_EXTRA_ARCHS_tune-i686}
core2-32"

meta/conf/machine/include/tune-core2.inc +1 -2
-QEMU_EXTRAOPTIONS_core2-32 = " -cpu core2duo"
+QEMU_EXTRAOPTIONS_core2-32 = " -cpu n270"
 
 AVAILTUNES += "core2-64"
 TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
--

2.17.1

Quoted 5 lines

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core