From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 688D2A04E0 for ; Wed, 27 Nov 2019 11:33:03 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 334ED1B103; Wed, 27 Nov 2019 11:33:03 +0100 (CET) Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by dpdk.org (Postfix) with ESMTP id 3CA6E28EE; Wed, 27 Nov 2019 11:32:59 +0100 (CET) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 64EAD224AA; Wed, 27 Nov 2019 05:32:57 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Wed, 27 Nov 2019 05:32:57 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=mesmtp; bh=Hdfz8nIzm8SsIMoundvi8t6O8XqFileqXTl2ALLK/to=; b=Mr2kKB5Xbx96 M7SbVIVigGkqumQBp22hS7tcbt4MLBG8DjeOGjWgAFWg0DmOZl4UbIR2P07pSBo5 gJ0AZu4zC9V9/8yosXB2ZXgC/vNf9QVZpk0a4HziYnrQ7NDgCwXRN4Tzftvld/EJ /pqp1emi7U9WXDZqkQNRVshBlD7zaJ0= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=Hdfz8nIzm8SsIMoundvi8t6O8XqFileqXTl2ALLK/ to=; b=GLNhvOOIgcTngZojwpHyQT9mWOsEJ68rR22ku2bq97cfMSqoZmIdbXdmG LRdiUD5q2uK1rHvlv+EqpO0MCwSQRKmVbkxsOJl/sb41Mf0uGoQe/aUOGY6kGuc3 BRdFX1c6lyDEsJFZA0vqkE5BAn/UkF0pfPQ4Z5ymleoJTl/oyuxTWAsMk6rnlzUO 3bCifvsRW1pu/QM6dzsUsEzhi9vBI5/hjCQti3jWhQVYEtBmotBQhiYGHmXW7Z+X 6SXA6JmBEUE8yGHUegnxCEcCD26XoLZjJIJJVj6shISadBsRiDDWk7PUdBqLzWYq +0rVbdUS+YPdALkvPNSZH6v+8pIlQ== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedufedrudeihedgudeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkfgjfhgggfgtsehtufertddttddvnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecuff homhgrihhnpehvrghrshdrmhhkpdhhuhgrrhhmrdgtohhmpdhgnhhurdhorhhgnecukfhp peejjedrudefgedrvddtfedrudekgeenucfrrghrrghmpehmrghilhhfrhhomhepthhhoh hmrghssehmohhnjhgrlhhonhdrnhgvthenucevlhhushhtvghrufhiiigvpedt X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 8813F3060060; Wed, 27 Nov 2019 05:32:55 -0500 (EST) From: Thomas Monjalon To: "Phil Yang (Arm Technology China)" Cc: Bruce Richardson , "dev@dpdk.org" , "david.marchand@redhat.com" , "jerinj@marvell.com" , Honnappa Nagarahalli , "Gavin Hu (Arm Technology China)" , "Joyce Kong (Arm Technology China)" , nd , "stable@dpdk.org" Date: Wed, 27 Nov 2019 11:32:54 +0100 Message-ID: <5000317.ObS1QFYq1c@xps> In-Reply-To: References: <1573468461-25972-1-git-send-email-phil.yang@arm.com> <20191127092931.GA1158@bricha3-MOBL.ger.corp.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH 1/2] mk: fix unsupported flag error on armhf architercture X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" 27/11/2019 11:00, Phil Yang (Arm Technology China): > > -----Original Message----- > > From: Bruce Richardson > > Sent: Wednesday, November 27, 2019 5:30 PM > > To: Phil Yang (Arm Technology China) > > Cc: thomas@monjalon.net; dev@dpdk.org; david.marchand@redhat.com; > > jerinj@marvell.com; Honnappa Nagarahalli > > ; Gavin Hu (Arm Technology China) > > ; Joyce Kong (Arm Technology China) > > ; nd ; stable@dpdk.org > > Subject: Re: [dpdk-dev] [PATCH 1/2] mk: fix unsupported flag error on armhf > > architercture > > > > On Wed, Nov 27, 2019 at 08:09:22AM +0000, Phil Yang (Arm Technology China) > > wrote: > > > > -----Original Message----- > > > > From: Thomas Monjalon > > > > Sent: Wednesday, November 27, 2019 1:02 AM > > > > To: Phil Yang (Arm Technology China) > > > > Cc: dev@dpdk.org; Bruce Richardson ; > > > > david.marchand@redhat.com; jerinj@marvell.com; Honnappa > > Nagarahalli > > > > ; Gavin Hu (Arm Technology China) > > > > ; Joyce Kong (Arm Technology China) > > > > ; nd ; stable@dpdk.org > > > > Subject: Re: [dpdk-dev] [PATCH 1/2] mk: fix unsupported flag error on > > armhf > > > > architercture > > > > > > > > 12/11/2019 07:40, Phil Yang (Arm Technology China): > > > > > > -----Original Message----- > > > > > > From: Thomas Monjalon > > > > > > Sent: Tuesday, November 12, 2019 2:03 PM > > > > > > To: Phil Yang (Arm Technology China) > > > > > > Cc: Bruce Richardson ; dev@dpdk.org; > > > > > > david.marchand@redhat.com; jerinj@marvell.com; Honnappa > > > > Nagarahalli > > > > > > ; Gavin Hu (Arm Technology China) > > > > > > ; Joyce Kong (Arm Technology China) > > > > > > ; nd ; stable@dpdk.org > > > > > > Subject: Re: [dpdk-dev] [PATCH 1/2] mk: fix unsupported flag error > > on > > > > armhf > > > > > > architercture > > > > > > > > > > > > 12/11/2019 06:25, Phil Yang (Arm Technology China): > > > > > > > From: Bruce Richardson > > > > > > > > On Mon, Nov 11, 2019 at 06:34:20PM +0800, Phil Yang wrote: > > > > > > > > > The older version (e.g. version 7.4.0 ) of GNU C compiler for the > > > > armhf > > > > > > > > > architecture doesn't support the flag '-Wno-address-of-packed- > > > > > > member', > > > > > > > > > so remove this flag for aarch32. > > > > > > > > > > > > > > > > > > Fixes: a385972c3675 ("mk: disable warning for packed member > > > > pointer") > > > > > > > > > Cc: stable@dpdk.org > > > > > > > > > > > > > > > > > > Signed-off-by: Phil Yang > > > > > > > > > Reviewed-by: Gavin Hu > > > > > > > > > Tested-by: Joyce Kong > > > > > > > > > > > > > > > > > > --- > > > > > > > > > mk/toolchain/gcc/rte.vars.mk | 2 ++ > > > > > > > > > 1 file changed, 2 insertions(+) > > > > > > > > > > > > > > > > > > diff --git a/mk/toolchain/gcc/rte.vars.mk > > > > > > b/mk/toolchain/gcc/rte.vars.mk > > > > > > > > > index 9fc7041..ec0cbbf 100644 > > > > > > > > > --- a/mk/toolchain/gcc/rte.vars.mk > > > > > > > > > +++ b/mk/toolchain/gcc/rte.vars.mk > > > > > > > > > @@ -100,7 +100,9 @@ WERROR_FLAGS += -Wno-format- > > truncation > > > > > > > > > endif > > > > > > > > > > > > > > > > > > # disable packed member unalign warnings > > > > > > > > > +ifneq ($(CONFIG_RTE_ARCH_ARM), y) > > > > > > > > > WERROR_FLAGS += -Wno-address-of-packed-member > > > > > > > > > +endif > > > > > > > > > > > > > > > > > You don't need to do this, as gcc will not complain about this > > unknown > > > > > > flag > > > > > > > > unless you have other issues in your code.[1] I think it's better to > > > > keep > > > > > > the > > > > > > > > code clean in this case, otherwise we'll have the code littered with > > > > > > > > conditionals for various flags. > > > > > > > > > > > > > > > > /Bruce > > > > > > > > > > > > > > > > [1] https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html > > > > > > > > "When an unrecognized warning option is requested (e.g., > > > > > > > > -Wunknown-warning), GCC emits a diagnostic stating that the > > option > > > > is > > > > > > not > > > > > > > > recognized. However, if the -Wno- form is used, the behavior is > > > > slightly > > > > > > > > different: no diagnostic is produced for -Wno-unknown-warning > > > > unless > > > > > > other > > > > > > > > diagnostics are being produced. This allows the use of new -Wno- > > > > options > > > > > > > > with old compilers, but if something goes wrong, the compiler > > warns > > > > that > > > > > > an > > > > > > > > unrecognized option is present." > > > > > > > > > > > > > > Thanks, Bruce. > > > > > > > > > > > > > > There are thousands of warnings with alignment when compiling for > > > > > > ARMv7 (ARMv7 supports unaligned memory access). > > > > > > > Without this new flag, the build system works fine for ARMv7. So I > > add > > > > this > > > > > > conditional for ARMv7 only. > > > > > > > I agree with you we should clean up the code, but it needs a lot of > > > > effort to > > > > > > achieve that. > > > > > > > This patch is going to make the ARMv7 target build successfully > > during > > > > this > > > > > > period. > > > > > > > > > > > > I would go the opposite direction. > > > > > > I think we should remove all warnings disablement like "-Wno- > > > > something", > > > > > > and clean the code. > > > > > > > > > > Thanks, Thomas. > > > > > > > > > > I think it is a compiler issue rather than a code defect in this case, as It > > > > cannot recognize the '-Waddress-of-packed-member' flag. > > > > > "arm-linux-gnueabihf-gcc: error: unrecognized command line option '- > > > > Waddress-of-packed-member'" > > > > > > > > > > > > > > > > > If you want to allow building ARMv7, you can just allow warnings as > > not > > > > > > errors. > > > > > > So we will still see something is wrong but it won't prevent from > > building. > > > > > > > > > > Yes. We did this already, all the alignment issues are emitted as > > warnings > > > > on ARMv7. > > > > > Please see these two commits: > > > > > 79fa5c2a9992 ("mk: ignore alignment errors for ARMv7") > > > > > 6433c19105e8 ("mk: generalize strict alignment warning handling") > > > > > > > > I don't know what to do with this patch. > > > > I think it is not how it should work, > > > > but you say your compiler has a real bug. > > > Agree with you, however I haven't found a better solution for this issue yet. > > > > > > > > > > > Can you confirm which compiler is it? > > > > > > Please check the packet information dumped below, it is the latest version > > in Ubuntu 18.04 LTS. > > > $ sudo apt show gcc-arm-linux-gnueabihf > > > Package: gcc-arm-linux-gnueabihf > > > Version: 4:7.4.0-1ubuntu2.3 > > > Priority: optional > > > Section: devel > > > Source: gcc-defaults (1.176ubuntu2.3) > > > Origin: Ubuntu > > > > > > > Does it prevent to compile even with -Wno-error ? > > > Yes, it does. I put one piece of the compiling log bellow. Please take a look. > > > > > > $ make -j1 CROSS=arm-linux-gnueabihf- T=arm-armv7a-linuxapp-gcc > > RTE_DEVEL_BUILD=y > > > > RTE_DEVEL_BUILD turns on -Werror, while what Thomas is asking about is > > using the opposite flag "-Wno-error". Can you do a non-developer build or > > put "-Wno-error" in EXTRA_CFLAGS to test this. > > Thanks, Bruce. > There is no compiling issue for the non-developer build and "-Wno-error" flag build. Cool, so we can classify this patch as "rejected".