[OE-core] [PATCH] tune-corei7.inc: tell qemu to emulate a matching processor

Ross Burton ross.burton at intel.com
Mon Feb 8 15:16:03 UTC 2016


If tune-corei7 is in use then the target binaries may contain instructions that
qemu-x86-64 can't execute by default, resulting in errors on rootfs construction:

NOTE: Running intercept scripts:
NOTE: > Executing update_font_cache intercept ...
qemu: uncaught target signal 4 (Illegal instruction) - core dumped

In this case the instruction is popcnt, part of SSE4.2, so tell Qemu to emulate
the CPU that the tune targets (in this case, Nehalem).

[ YOCTO #8888 ]

Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/conf/machine/include/tune-corei7.inc | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/meta/conf/machine/include/tune-corei7.inc b/meta/conf/machine/include/tune-corei7.inc
index d245d9f..197558f 100644
--- a/meta/conf/machine/include/tune-corei7.inc
+++ b/meta/conf/machine/include/tune-corei7.inc
@@ -11,6 +11,8 @@ DEFAULTTUNE ?= "corei7-64"
 # Pull in the previous tune in to pull in PACKAGE_EXTRA_ARCHS
 require conf/machine/include/tune-core2.inc
 
+QEMU_EXTRAOPTIONS_corei7-64 = " -cpu Nehalem,check=false"
+
 # Extra tune features
 TUNEVALID[corei7] = "Enable corei7 specific processor optimizations"
 TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'corei7', ' -march=corei7 -mtune=corei7 -mfpmath=sse -msse4.2', '', d)}"
-- 
2.7.0




More information about the Openembedded-core mailing list