From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by dpdk.org (Postfix) with ESMTP id 38A5E2BA3 for ; Thu, 30 Aug 2018 12:52:39 +0200 (CEST) Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w7UAnK3K043969 for ; Thu, 30 Aug 2018 06:52:38 -0400 Received: from smtp.notes.na.collabserv.com (smtp.notes.na.collabserv.com [158.85.210.108]) by mx0a-001b2d01.pphosted.com with ESMTP id 2m6e83tb9w-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 30 Aug 2018 06:52:38 -0400 Received: from localhost by smtp.notes.na.collabserv.com with smtp.notes.na.collabserv.com ESMTP for from ; Thu, 30 Aug 2018 10:52:37 -0000 Received: from us1b3-smtp06.a3dr.sjc01.isc4sb.com (10.122.203.184) by smtp.notes.na.collabserv.com (10.122.47.46) with smtp.notes.na.collabserv.com ESMTP; Thu, 30 Aug 2018 10:52:31 -0000 Received: from us1b3-mail157.a3dr.sjc03.isc4sb.com ([10.160.174.125]) by us1b3-smtp06.a3dr.sjc01.isc4sb.com with ESMTP id 2018083010523058-350725 ; Thu, 30 Aug 2018 10:52:30 +0000 In-Reply-To: <20180830100000.23984-1-christian.ehrhardt@canonical.com> From: "Takeshi T Yoshimura" To: Christian Ehrhardt Cc: adrien.mazarguil@6wind.com, dev , Gowrishankar Muthukrishnan , Chao Zhu , Luca Boccassi , Thomas Monjalon Date: Thu, 30 Aug 2018 10:52:30 +0000 Sensitivity: Importance: Normal X-Priority: 3 (Normal) References: <20180830100000.23984-1-christian.ehrhardt@canonical.com>, X-Mailer: IBM iNotes ($HaikuForm 1011.1) | IBM Domino Build SCN1812108_20180501T0841 May 01, 2018 at 08:41 X-KeepSent: 6F595576:B86A373C-002582F9:003A9ACA; type=4; name=$KeepSent X-LLNOutbound: False X-Disclaimed: 20795 X-TNEFEvaluated: 1 X-LLNXfer: False x-cbid: 18083010-7845-0000-0000-000004930AD8 X-IBM-SpamModules-Scores: BY=0.020101; FL=0; FP=0; FZ=0; HX=0; KW=0; PH=0; SC=0.390428; ST=0; TS=0; UL=0; ISC=; MB=0.239782 X-IBM-SpamModules-Versions: BY=3.00009638; HX=3.00000242; KW=3.00000007; PH=3.00000004; SC=3.00000266; SDB=6.01080988; UDB=6.00557644; IPR=6.00860972; BA=6.00006087; NDR=6.00000001; ZLA=6.00000005; ZF=6.00000009; ZB=6.00000000; ZP=6.00000000; ZH=6.00000000; ZU=6.00000002; MB=3.00023012; XFM=3.00000015; UTC=2018-08-30 10:52:35 X-IBM-AV-DETECTION: SAVI=unsuspicious REMOTE=unsuspicious XFE=unused X-IBM-AV-VERSION: SAVI=2018-08-30 03:20:43 - 6.00008900 x-cbparentid: 18083010-7846-0000-0000-000011080A88 Message-Id: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: Quoted-printable MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2018-08-30_04:, , signatures=0 X-Proofpoint-Spam-Reason: safe Subject: Re: [dpdk-dev] [PATCH] ppc64: fix compilation of when AltiVec is enabled 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: , X-List-Received-Date: Thu, 30 Aug 2018 10:52:39 -0000 >=E5=AE=9B=E5=85=88: adrien.mazarguil@6wind.com, dev , Gowris= hankar >Muthukrishnan , Chao Zhu > >=E9=80=81=E4=BF=A1=E5=85=83: Christian Ehrhardt=20 >=E9=80=81=E4=BF=A1=E8=80=85: "dev"=20 >=E6=97=A5=E4=BB=98: 2018/08/30 07:00PM >Cc: Luca Boccassi , Thomas Monjalon >, Christian Ehrhardt > >=E4=BB=B6=E5=90=8D: [dpdk-dev] [PATCH] ppc64: fix compilation of when Alti= Vec is >enabled > >The definition of almost any newer standard like --stc=3Dc11 will drop >__APPLCE_ALTIVEC__ which otherwise would be defined. >If that is the case then altivec.h will redefine bool to a type >conflicting with those defined by stdbool.h. > >This breaks compilation of 18.08 on ppc64 like: > mlx5_nl_flow.c:407:17: error: incompatible types when assigning to >type > =E2=80=98__vector __bool int=E2=80=99 {aka =E2=80=98__vector(4) __bool i= nt=E2=80=99} from type >=E2=80=98int=E2=80=99 > in_port_id_set =3D false; > >Other alternatives were pursued on [1] but they always ended up being >more >complex than what would be appropriate for the issue we face. > >[1]: >INVALID URI REMOVED >chives_dev_2018-2DAugust_109926.html&d=3DDwIDaQ&c=3Djf_iaSHvJObTbx-siA1ZO >g&r=3DEZR6Jx10q0q3dTopeH3WIQ&m=3DbbU1KVc1ZvNW9Rz7B0MLHfS0f0oZv35d2mpRpHO0 >ByY&s=3DRvMIFfk-cAAGTrYM76-iSSqIYV_X2EptYZzYIweIHRk&e=3D > >Change-Id: I1ed56da954e4951b9d120ca2ac0c0c218b4a0140 >Signed-off-by: Christian Ehrhardt >--- > .../common/include/arch/ppc_64/rte_memcpy.h | 11 >+++++++++++ > 1 file changed, 11 insertions(+) > >diff --git a/lib/librte_eal/common/include/arch/ppc_64/rte_memcpy.h >b/lib/librte_eal/common/include/arch/ppc_64/rte_memcpy.h >index 75f74897b..0b3b89b56 100644 >--- a/lib/librte_eal/common/include/arch/ppc_64/rte_memcpy.h >+++ b/lib/librte_eal/common/include/arch/ppc_64/rte_memcpy.h >@@ -37,6 +37,17 @@ > #include > /*To include altivec.h, GCC version must >=3D 4.8 */ > #include >+/* >+ * Compilation workaround for PPC64 targets when AltiVec is fully >+ * enabled e.g. with std=3Dc11. Otherwise there would be a type >conflict >+ * of "bool" between stdbool and altivec. >+ */ >+#if defined(__PPC64__) && !defined(__APPLE_ALTIVEC__) >+ #undef bool >+ /* redefine as in stdbool.h */ >+ #define bool _Bool >+#endif >+ >=20 > #ifdef __cplusplus > extern "C" { >--=20 >2.17.1 > > > Hi, I could reproduce the issue you reported in 18.08 with my ppc64le box with = RedHat 7.5 and GCC4.8. The patch resolved the issue in my environment. Thanks! I am a bit newbie in dpdk-dev, but I will try contacting Chao and other IBM= guys... Sorry for our slow reply. Regards, Takeshi