summaryrefslogtreecommitdiffstats
path: root/core/combo
diff options
context:
space:
mode:
authorAndrew Hsieh <andrewhsieh@google.com>2012-05-18 15:53:35 +0800
committerAndrew Hsieh <andrewhsieh@google.com>2012-05-18 15:53:35 +0800
commit112a674798c58052ddce94418e34f3e5a084ed1a (patch)
tree7dab2511ac9d4fd4711717553aa2d6e6db1d068b /core/combo
parentfeec98b139d2ca0b0164a5e178e75ce88b8f492f (diff)
downloadbuild-112a674798c58052ddce94418e34f3e5a084ed1a.zip
build-112a674798c58052ddce94418e34f3e5a084ed1a.tar.gz
build-112a674798c58052ddce94418e34f3e5a084ed1a.tar.bz2
Add -mno-movbe to disable "movbe" instruction from code-gen
Intruction "movbe" (move data after swapping bytes) is only available in Intel atom. Disable it for more general x86 devices and x86 hosts which run emulator-x86. Although emulator-x86 can support "movbe", most of the time we want to run emulator-x86 with VT support for speed (with KVM in Linux, or HAXM in Windows/MacOSX). The presence of "movbe" can crash emulator-x86 in VT because non-atom host doesn't have it natively. Change-Id: I86e037900ddcb8d544f92b8d8464c8627347e560
Diffstat (limited to 'core/combo')
-rw-r--r--core/combo/TARGET_linux-x86.mk5
1 files changed, 5 insertions, 0 deletions
diff --git a/core/combo/TARGET_linux-x86.mk b/core/combo/TARGET_linux-x86.mk
index a4d07b5..cb251d3 100644
--- a/core/combo/TARGET_linux-x86.mk
+++ b/core/combo/TARGET_linux-x86.mk
@@ -132,6 +132,11 @@ TARGET_GLOBAL_CFLAGS += -mbionic
#
TARGET_GLOBAL_CFLAGS += -D__ANDROID__
+# instructions "movbe" is only available in Intel atom. Disable it
+# for general x86 device and x86 host which runs emulator-x86
+#
+TARGET_GLOBAL_CFLAGS += -mno-movbe
+
# XXX: This flag is probably redundant since our toolchain binaries already
# generate 32-bit machine code. It probably dates back to the old days
# where we were using the host toolchain on Linux to build the platform