From patchwork Fri Aug 28 11:38:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Juraj_Linke=C5=A1?= X-Patchwork-Id: 76131 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id B5C98A04B1; Fri, 28 Aug 2020 13:39:15 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 299131C136; Fri, 28 Aug 2020 13:39:03 +0200 (CEST) Received: from lb.pantheon.sk (lb.pantheon.sk [46.229.239.20]) by dpdk.org (Postfix) with ESMTP id DFAED1C122 for ; Fri, 28 Aug 2020 13:38:57 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by lb.pantheon.sk (Postfix) with ESMTP id 5238C970A8; Fri, 28 Aug 2020 13:38:57 +0200 (CEST) X-Virus-Scanned: amavisd-new at siecit.sk Received: from lb.pantheon.sk ([127.0.0.1]) by localhost (lb.pantheon.sk [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id b5gaOYptB5KB; Fri, 28 Aug 2020 13:38:56 +0200 (CEST) Received: from service-node1.lab.pantheon.local (unknown [46.229.239.141]) by lb.pantheon.sk (Postfix) with ESMTP id 9647B970AE; Fri, 28 Aug 2020 13:38:54 +0200 (CEST) From: =?utf-8?q?Juraj_Linke=C5=A1?= To: thomas@monjalon.net, david.marchand@redhat.com, aconole@redhat.com, maicolgabriel@hotmail.com Cc: dev@dpdk.org, juraj.linkes@pantheon.tech Date: Fri, 28 Aug 2020 13:38:50 +0200 Message-Id: <1598614733-16220-3-git-send-email-juraj.linkes@pantheon.tech> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1598614733-16220-1-git-send-email-juraj.linkes@pantheon.tech> References: <1598360684-8975-1-git-send-email-juraj.linkes@pantheon.tech> <1598614733-16220-1-git-send-email-juraj.linkes@pantheon.tech> MIME-Version: 1.0 Subject: [dpdk-dev] [PATCH v9 2/5] build: add aarch32 meson build flags X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Add aarch32 extra build flags and aarch32 machine flags to generic machine args. Also modify how arm flags are updated in meson build - for 32-bit build, update only if cross-compiling. Signed-off-by: Juraj Linkeš --- config/arm/meson.build | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/config/arm/meson.build b/config/arm/meson.build index 8728051d5..b29f27097 100644 --- a/config/arm/meson.build +++ b/config/arm/meson.build @@ -63,6 +63,11 @@ flags_armada = [ ['RTE_MAX_LCORE', 16]] flags_default_extra = [] +flags_aarch32_extra = [ + ['RTE_ARCH_ARM_NEON_MEMCPY', false], + ['RTE_ARCH_STRICT_ALIGN', true], + ['RTE_EAL_NUMA_AWARE_HUGEPAGES', false], + ['RTE_MAX_LCORE', 256]] flags_n1sdp_extra = [ ['RTE_MACHINE', '"n1sdp"'], ['RTE_MAX_NUMA_NODES', 1], @@ -90,6 +95,7 @@ flags_octeontx2_extra = [ machine_args_generic = [ ['default', ['-march=armv8-a+crc']], ['native', ['-march=native']], + ['aarch32', ['-march=armv8-a', '-mfpu=neon'], flags_aarch32_extra], ['0xd03', ['-mcpu=cortex-a53']], ['0xd04', ['-mcpu=cortex-a35']], ['0xd07', ['-mcpu=cortex-a57']], @@ -129,15 +135,23 @@ impl_0x69 = ['Intel', flags_generic, machine_args_generic] impl_dpaa = ['NXP DPAA', flags_dpaa, machine_args_generic] dpdk_conf.set('RTE_FORCE_INTRINSICS', 1) - +update_flags = false if not dpdk_conf.get('RTE_ARCH_64') dpdk_conf.set('RTE_CACHE_LINE_SIZE', 64) dpdk_conf.set('RTE_ARCH_ARM', 1) dpdk_conf.set('RTE_ARCH_ARMv7', 1) # the minimum architecture supported, armv7-a, needs the following, # mk/machine/armv7a/rte.vars.mk sets it too - machine_args += '-mfpu=neon' + if meson.is_cross_build() + update_flags = true + impl_id = meson.get_cross_property('implementor_id', 'aarch32') + impl_pn = meson.get_cross_property('implementor_pn', 'default') + machine = get_variable('impl_' + impl_id) + else + machine_args += '-mfpu=neon' + endif else + update_flags = true dpdk_conf.set('RTE_CACHE_LINE_SIZE', 128) dpdk_conf.set('RTE_ARCH_ARM64', 1) @@ -172,7 +186,9 @@ else impl_pn = meson.get_cross_property('implementor_pn', 'default') machine = get_variable('impl_' + impl_id) endif +endif +if update_flags == true # Apply Common Defaults. These settings may be overwritten by machine # settings later. foreach flag: flags_common_default