From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mailout2.w1.samsung.com (mailout2.w1.samsung.com [210.118.77.12]) by dpdk.org (Postfix) with ESMTP id 58BAB5F1D for ; Tue, 15 Jan 2019 12:29:48 +0100 (CET) Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20190115112947euoutp02347002e6c5c8dbb5ab933212d612a451~6AibKKgsR0332003320euoutp02B for ; Tue, 15 Jan 2019 11:29:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20190115112947euoutp02347002e6c5c8dbb5ab933212d612a451~6AibKKgsR0332003320euoutp02B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1547551787; bh=090F3ybc/Ot3Fk+mkiz9hf5xl+L22uQKpIiJJQ8mDdI=; h=From:To:Cc:Subject:Date:References:From; b=QDoTe4QC4UBQ8j2Xvh2CZ+FVaDrMRyOYbUtJ2f7QSQt8RxkBZhTQjfGLv8NygMPam AWeBShD4CKoRnWSiSmfPxbn50AE1G3x75Qimdz0GH3E4C/nkHuyNi1Bq2H0UY+ZesA lnrlvAgaZNimprrgCzzs3ZqzqcgCcM/CuyhBDvUI= Received: from eusmges1new.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20190115112947eucas1p2dca2bb3e0741f09e44cdb108e150ae59~6AiaqtXNL0098700987eucas1p28; Tue, 15 Jan 2019 11:29:47 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges1new.samsung.com (EUCPMTA) with SMTP id 7A.2C.04441.A24CD3C5; Tue, 15 Jan 2019 11:29:46 +0000 (GMT) Received: from eusmtrp2.samsung.com (unknown [182.198.249.139]) by eucas1p2.samsung.com (KnoxPortal) with ESMTPA id 20190115112946eucas1p22fa0b405d8cfe1feae7426a9b37857b1~6AiZ0KCTK1106711067eucas1p2T; Tue, 15 Jan 2019 11:29:46 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eusmtrp2.samsung.com (KnoxPortal) with ESMTP id 20190115112945eusmtrp2417ec0c6d453075e85efe060ddd2c826~6AiZlozhE1980419804eusmtrp2I; Tue, 15 Jan 2019 11:29:45 +0000 (GMT) X-AuditID: cbfec7f2-5e3ff70000001159-48-5c3dc42a6ab1 Received: from eusmtip2.samsung.com ( [203.254.199.222]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id E6.DF.04284.924CD3C5; Tue, 15 Jan 2019 11:29:45 +0000 (GMT) Received: from imaximets.rnd.samsung.ru (unknown [106.109.129.180]) by eusmtip2.samsung.com (KnoxPortal) with ESMTPA id 20190115112945eusmtip202a5561d168cc78e4a6cc04d2acbb29a~6AiZGivXq2716127161eusmtip2j; Tue, 15 Jan 2019 11:29:45 +0000 (GMT) From: Ilya Maximets To: dev@dpdk.org, Thomas Monjalon Cc: Pavan Nikhilesh , Bruce Richardson , Honnappa Nagarahalli , Ilya Maximets , stable@dpdk.org Date: Tue, 15 Jan 2019 14:29:39 +0300 Message-Id: <20190115112939.8780-1-i.maximets@samsung.com> X-Mailer: git-send-email 2.17.1 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrMIsWRmVeSWpSXmKPExsWy7djPc7paR2xjDPb8MrC4scre4t2n7UwW M5+2sFtcaf/JbnG85yOLxb+OP+wWnx6cYHFg91gzbw2jx68FS1k9Fu95yeQxeeFFZo9jN6ex e/RtWcUYwBbFZZOSmpNZllqkb5fAlfFtiWZBk3DF+ccXmBoYFwl0MXJySAiYSKxoeM3UxcjF ISSwglFi0bc/zBDOF0aJlVNvMkI4nxklZt/vZ4ZpOTZhKlTLckaJltWHoKp+MErMWnWSFaSK TUBH4tTqI4wgtoiAucTECZ2sIEXMAhcZJU5s62YHSQgL2EhMur6ECcRmEVCVWP/3LBuIzStg JfH9+wx2iHXyEqs3HIBafZ9N4lFbJITtIjGv/xMjhC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2Blk9klhJNzgfGSl5JvKGpobmFpaG5sbmxmYWSOO95g8ooIYH0 xJLU7NTUgtQimD4mDk6pBsbuc9Wf9grsPZK/VS2C02FtnT+Phmzl+2ecU/KOnWC6wPfp5XLl aytO6utMndv2P9vI4K/LDmkZtl7tvwG2XO2HxPkfdj+cJPro5LLlImIXXyfO+F59OHFv3lSG A/eunUqqdM7ieT7h7VPRtZXR4azXqxads3bM1Knds9HTpmYG6371QoGmrEIlluKMREMt5qLi RAAWEszRXQIAAA== X-CMS-MailID: 20190115112946eucas1p22fa0b405d8cfe1feae7426a9b37857b1 X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-RootMTR: 20190115112946eucas1p22fa0b405d8cfe1feae7426a9b37857b1 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20190115112946eucas1p22fa0b405d8cfe1feae7426a9b37857b1 References: Subject: [dpdk-dev] [PATCH] eal: fix clang build with intrinsics forced 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: Tue, 15 Jan 2019 11:29:48 -0000 This fixes x86_64-native-linuxapp-clang build with CONFIG_RTE_FORCE_INTRINSICS=y: include/generic/rte_atomic.h:218:9: error: implicit declaration of function '__atomic_exchange_2' is invalid in C99 [-Werror,-Wimplicit-function-declaration] include/generic/rte_atomic.h:501:9: error: implicit declaration of function '__atomic_exchange_4' is invalid in C99 [-Werror,-Wimplicit-function-declaration] include/generic/rte_atomic.h:783:9: error: implicit declaration of function '__atomic_exchange_8' is invalid in C99 [-Werror,-Wimplicit-function-declaration] We didn't caught this issue previously on other platforms because CONFIG_RTE_FORCE_INTRINSICS enabled by default only for armv8. Fixes: 7bdccb93078e ("eal: fix ARM build with clang") Cc: stable@dpdk.org Signed-off-by: Ilya Maximets --- lib/librte_eal/common/include/generic/rte_atomic.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/librte_eal/common/include/generic/rte_atomic.h b/lib/librte_eal/common/include/generic/rte_atomic.h index d0c464fb1..4afd1acc3 100644 --- a/lib/librte_eal/common/include/generic/rte_atomic.h +++ b/lib/librte_eal/common/include/generic/rte_atomic.h @@ -212,7 +212,7 @@ rte_atomic16_exchange(volatile uint16_t *dst, uint16_t val); static inline uint16_t rte_atomic16_exchange(volatile uint16_t *dst, uint16_t val) { -#if defined(RTE_ARCH_ARM64) && defined(__clang__) +#if defined(__clang__) return __atomic_exchange_n(dst, val, __ATOMIC_SEQ_CST); #else return __atomic_exchange_2(dst, val, __ATOMIC_SEQ_CST); @@ -495,7 +495,7 @@ rte_atomic32_exchange(volatile uint32_t *dst, uint32_t val); static inline uint32_t rte_atomic32_exchange(volatile uint32_t *dst, uint32_t val) { -#if defined(RTE_ARCH_ARM64) && defined(__clang__) +#if defined(__clang__) return __atomic_exchange_n(dst, val, __ATOMIC_SEQ_CST); #else return __atomic_exchange_4(dst, val, __ATOMIC_SEQ_CST); @@ -777,7 +777,7 @@ rte_atomic64_exchange(volatile uint64_t *dst, uint64_t val); static inline uint64_t rte_atomic64_exchange(volatile uint64_t *dst, uint64_t val) { -#if defined(RTE_ARCH_ARM64) && defined(__clang__) +#if defined(__clang__) return __atomic_exchange_n(dst, val, __ATOMIC_SEQ_CST); #else return __atomic_exchange_8(dst, val, __ATOMIC_SEQ_CST); -- 2.17.1