From 04aa521ecab87340a477c2a463c6fb77251796bd Mon Sep 17 00:00:00 2001 From: Dan Willemsen Date: Tue, 10 May 2016 14:08:45 -0700 Subject: [PATCH] Add a 32-bit x86_64 arch variant The current 32-bit configuration for generic x86_64 targets inherits some variables (SSE4 support) from the 64-bit configuration, and overrides the make variables used for other configurations (SSSE3). Ideally, these would be using different variables, but until then, unify the configuration for x86_64 targets so that everything is consistent. Bug: 28694691 Change-Id: I47e67299d4c632e7491d7e73dc0fc6480ef08006 --- core/combo/arch/x86/x86_64.mk | 18 ++++++++++++++++++ target/board/generic_x86_64/BoardConfig.mk | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 core/combo/arch/x86/x86_64.mk diff --git a/core/combo/arch/x86/x86_64.mk b/core/combo/arch/x86/x86_64.mk new file mode 100644 index 000000000..620fbd80b --- /dev/null +++ b/core/combo/arch/x86/x86_64.mk @@ -0,0 +1,18 @@ +# This file is used as the second (32-bit) architecture when building a generic +# x86_64 64-bit platform image. (full_x86_64-eng / sdk_x86_64-eng) +# +# The generic 'x86' variant cannot be used, since it resets some flags used +# by the 'x86_64' variant. + +ARCH_X86_HAVE_SSSE3 := true +ARCH_X86_HAVE_MOVBE := false # Only supported on Atom. +ARCH_X86_HAVE_POPCNT := true +ARCH_X86_HAVE_SSE4 := true +ARCH_X86_HAVE_SSE4_1 := true +ARCH_X86_HAVE_SSE4_2 := true + + +# Some intrinsic functions used by libcxx only exist for prescott or newer CPUs. +arch_variant_cflags := \ + -march=prescott \ + diff --git a/target/board/generic_x86_64/BoardConfig.mk b/target/board/generic_x86_64/BoardConfig.mk index 783fc7767..09462431f 100755 --- a/target/board/generic_x86_64/BoardConfig.mk +++ b/target/board/generic_x86_64/BoardConfig.mk @@ -13,7 +13,7 @@ TARGET_PRELINK_MODULE := false TARGET_2ND_CPU_ABI := x86 TARGET_2ND_ARCH := x86 -TARGET_2ND_ARCH_VARIANT := x86 +TARGET_2ND_ARCH_VARIANT := x86_64 TARGET_USES_64_BIT_BINDER := true -- 2.11.0