From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 6A62C1B4AA for ; Thu, 29 Nov 2018 14:24:03 +0100 (CET) Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D4065315485E; Thu, 29 Nov 2018 13:24:02 +0000 (UTC) Received: from ktraynor.remote.csb (ovpn-117-230.ams2.redhat.com [10.36.117.230]) by smtp.corp.redhat.com (Postfix) with ESMTP id D58961001F50; Thu, 29 Nov 2018 13:24:01 +0000 (UTC) From: Kevin Traynor To: Thomas Monjalon Cc: dpdk stable Date: Thu, 29 Nov 2018 13:21:10 +0000 Message-Id: <20181129132128.7609-70-ktraynor@redhat.com> In-Reply-To: <20181129132128.7609-1-ktraynor@redhat.com> References: <20181129132128.7609-1-ktraynor@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.41]); Thu, 29 Nov 2018 13:24:02 +0000 (UTC) Subject: [dpdk-stable] patch 'eal: fix build with -O1' has been queued to stable release 18.08.1 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: , X-List-Received-Date: Thu, 29 Nov 2018 13:24:03 -0000 Hi, FYI, your patch has been queued to stable release 18.08.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 12/08/18. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. If the code is different (ie: not only metadata diffs), due for example to a change in context or macro names, please double check it. Thanks. Kevin Traynor --- >>From 048dfa09bb606e52fe3d9cacf4608390d3377dd3 Mon Sep 17 00:00:00 2001 From: Thomas Monjalon Date: Fri, 16 Nov 2018 17:58:50 +0100 Subject: [PATCH] eal: fix build with -O1 [ upstream commit e357e8ebd99c9c394a276fdffd37f13005cb1c63 ] In case of optimized compilation, RTE_BUILD_BUG_ON use an external variable which is neither defined, nor used. It seems not optimized out in case of OPDL compiled with clang -O1: opdl_ring.c: undefined reference to `RTE_BUILD_BUG_ON_detected_error' clang-6.0: fatal error: linker command failed with exit code 1 Fixes: af75078fece3 ("first public release") Signed-off-by: Thomas Monjalon --- lib/librte_eal/common/include/rte_common.h | 9 --------- 1 file changed, 9 deletions(-) diff --git a/lib/librte_eal/common/include/rte_common.h b/lib/librte_eal/common/include/rte_common.h index 069c13ec7..e873415aa 100644 --- a/lib/librte_eal/common/include/rte_common.h +++ b/lib/librte_eal/common/include/rte_common.h @@ -260,14 +260,5 @@ rte_is_aligned(void *ptr, unsigned align) * Triggers an error at compilation time if the condition is true. */ -#ifndef __OPTIMIZE__ #define RTE_BUILD_BUG_ON(condition) ((void)sizeof(char[1 - 2*!!(condition)])) -#else -extern int RTE_BUILD_BUG_ON_detected_error; -#define RTE_BUILD_BUG_ON(condition) do { \ - ((void)sizeof(char[1 - 2*!!(condition)])); \ - if (condition) \ - RTE_BUILD_BUG_ON_detected_error = 1; \ -} while(0) -#endif /** -- 2.19.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2018-11-29 13:11:36.781645840 +0000 +++ 0069-eal-fix-build-with-O1.patch 2018-11-29 13:11:34.000000000 +0000 @@ -1,8 +1,10 @@ -From e357e8ebd99c9c394a276fdffd37f13005cb1c63 Mon Sep 17 00:00:00 2001 +From 048dfa09bb606e52fe3d9cacf4608390d3377dd3 Mon Sep 17 00:00:00 2001 From: Thomas Monjalon Date: Fri, 16 Nov 2018 17:58:50 +0100 Subject: [PATCH] eal: fix build with -O1 +[ upstream commit e357e8ebd99c9c394a276fdffd37f13005cb1c63 ] + In case of optimized compilation, RTE_BUILD_BUG_ON use an external variable which is neither defined, nor used. It seems not optimized out in case of OPDL compiled with clang -O1: @@ -10,7 +12,6 @@ clang-6.0: fatal error: linker command failed with exit code 1 Fixes: af75078fece3 ("first public release") -Cc: stable@dpdk.org Signed-off-by: Thomas Monjalon --- @@ -18,10 +19,10 @@ 1 file changed, 9 deletions(-) diff --git a/lib/librte_eal/common/include/rte_common.h b/lib/librte_eal/common/include/rte_common.h -index d115b175c..66cdf60b2 100644 +index 069c13ec7..e873415aa 100644 --- a/lib/librte_eal/common/include/rte_common.h +++ b/lib/librte_eal/common/include/rte_common.h -@@ -271,14 +271,5 @@ rte_is_aligned(void *ptr, unsigned align) +@@ -260,14 +260,5 @@ rte_is_aligned(void *ptr, unsigned align) * Triggers an error at compilation time if the condition is true. */ -#ifndef __OPTIMIZE__