Use i686 as TARGET_ARCH for 32bit core2 (and corei7 and atom) builds. In most cases, i586 and i686 are equivalent values for TARGET_ARCH, however one important exception is glibc. When configured for i686, glibc enables optimised string functions (SSE, SSE2, etc), which are not used when building for i586. The benefits of i686 optimised string functions vary depending on the application and the CPU, however in some cases the improvements are significant. In one test, a 50% increase in FPS was seen when running the 'smashcat' benchmark [1] in a qtwebkit browser on an Intel Atom based SoC. The gain seems to comes from a 3x improvement in memcpy performance when copying graphics buffer lines (5120 bytes, or 1280 x 4 bytes/pixel), from the CPU to GPU. Note that very large memcpy's (e.g. 32MB) on the same machine show no particular performance increase between i586 and i686. [1] http://www.smashcat.org/av/canvas_test/ Warning: The change in TARGET_ARCH means that _i586 architecture specific over-rides will no longer take effect. Both oe-core and meta-oe have been updated to replace _i586 over-rides with _x86, however other layers may still need review and updating. (From OE-Core rev: dd09fab685de2eaf04aa5ab60f8220b89c1deae9) Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
39 lines
1.5 KiB
C++
39 lines
1.5 KiB
C++
# Settings for the GCC(1) cpu-type "core2":
|
|
#
|
|
# Intel Core2 CPU with 64-bit extensions, MMX, SSE, SSE2, SSE3 and SSSE3
|
|
# instruction set support.
|
|
#
|
|
# This tune is recommended for the Intel Core 2 CPU family, including Conroe,
|
|
# Merom and beyond, as well as the first Atom CPUs, Diamondville, and beyond.
|
|
#
|
|
DEFAULTTUNE ?= "core2-32"
|
|
|
|
# Set x86 target arch to i686, so that glibc enables SSE optimised memcpy, etc.
|
|
X86ARCH32 ?= "i686"
|
|
|
|
# Include the previous tune to pull in PACKAGE_EXTRA_ARCHS
|
|
require conf/machine/include/tune-i586.inc
|
|
|
|
# Extra tune features
|
|
TUNEVALID[core2] = "Enable core2 specific processor optimizations"
|
|
TUNE_CCARGS .= "${@bb.utils.contains("TUNE_FEATURES", "core2", " -march=core2 -mtune=core2 -msse3 -mfpmath=sse", "", d)}"
|
|
|
|
# Extra tune selections
|
|
AVAILTUNES += "core2-32"
|
|
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-i586} core2-32"
|
|
|
|
AVAILTUNES += "core2-64"
|
|
TUNE_FEATURES_tune-core2-64 = "${TUNE_FEATURES_tune-x86-64} core2"
|
|
BASE_LIB_tune-core2-64 = "lib64"
|
|
TUNE_PKGARCH_tune-core2-64 = "core2-64"
|
|
PACKAGE_EXTRA_ARCHS_tune-core2-64 = "${PACKAGE_EXTRA_ARCHS_tune-x86-64} core2-64"
|
|
|
|
AVAILTUNES += "core2-64-x32"
|
|
TUNE_FEATURES_tune-core2-64-x32 = "${TUNE_FEATURES_tune-x86-64-x32} core2"
|
|
BASE_LIB_tune-core2-64-x32 = "libx32"
|
|
TUNE_PKGARCH_tune-core2-64-x32 = "core2-64-x32"
|
|
PACKAGE_EXTRA_ARCHS_tune-core2-64-x32 = "${PACKAGE_EXTRA_ARCHS_tune-x86-64-x32} core2-64-x32"
|