From patchwork Wed Jun 23 16:12:46 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Christensen X-Patchwork-Id: 94765 X-Patchwork-Delegate: david.marchand@redhat.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7204EA0C41; Wed, 23 Jun 2021 18:12:54 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 04E684003F; Wed, 23 Jun 2021 18:12:54 +0200 (CEST) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by mails.dpdk.org (Postfix) with ESMTP id 438354003E for ; Wed, 23 Jun 2021 18:12:53 +0200 (CEST) Received: from pps.filterd (m0098394.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 15NG4Kk3017664 for ; Wed, 23 Jun 2021 12:12:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding; s=pp1; bh=vinAkuA+cqx3x0ecBthkYUzCMOBsbNeqjHvGpzwPHMo=; b=eYbPgzQ4rDJHcOd748lyVUm5DP9PfZpX8+3PfZ3HxBskeGIrRSZ8rpsrrtnDhFbp5OSE U06c2KfXD44z+71oyBeWntlYumKdNJHiEM+eKHBuOgGE1erEXFctOlvrTi04mMzjR0M8 FmWBU0p+k5fkYPiJljfn0nO9AAXlv7Ja9H5iXC6GQwbZiDw4oq8h1CufCOoRHj83qmDz HFBGSPtP2V8rBFv08UpDDtiP1BykwcoHLQXEC9YImIv9lyOxAjCatjbknDYrXGK5DSM6 So2IrV7d/25OO79NidXP6dhIiCCiwyKk4lf2r7xeB52pI1hcyeFhxxqKsqUYM1SovYuG 7g== Received: from ppma01wdc.us.ibm.com (fd.55.37a9.ip4.static.sl-reverse.com [169.55.85.253]) by mx0a-001b2d01.pphosted.com with ESMTP id 39c69p4ufa-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 23 Jun 2021 12:12:52 -0400 Received: from pps.filterd (ppma01wdc.us.ibm.com [127.0.0.1]) by ppma01wdc.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 15NG854X019587 for ; Wed, 23 Jun 2021 16:12:51 GMT Received: from b03cxnp07028.gho.boulder.ibm.com (b03cxnp07028.gho.boulder.ibm.com [9.17.130.15]) by ppma01wdc.us.ibm.com with ESMTP id 3998791qt3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Wed, 23 Jun 2021 16:12:51 +0000 Received: from b03ledav003.gho.boulder.ibm.com (b03ledav003.gho.boulder.ibm.com [9.17.130.234]) by b03cxnp07028.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 15NGCorR13435194 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 23 Jun 2021 16:12:50 GMT Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 20DB96A047; Wed, 23 Jun 2021 16:12:50 +0000 (GMT) Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id DC1066A04D; Wed, 23 Jun 2021 16:12:49 +0000 (GMT) Received: from localhost.localdomain (unknown [9.114.224.51]) by b03ledav003.gho.boulder.ibm.com (Postfix) with ESMTP; Wed, 23 Jun 2021 16:12:49 +0000 (GMT) From: David Christensen To: dev@dpdk.org Cc: David Christensen Date: Wed, 23 Jun 2021 09:12:46 -0700 Message-Id: <20210623161246.49474-1-drc@linux.vnet.ibm.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: ljiqn_r6oVEBbpm6pAeMyHitz_YpB9Ew X-Proofpoint-ORIG-GUID: ljiqn_r6oVEBbpm6pAeMyHitz_YpB9Ew X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391, 18.0.790 definitions=2021-06-23_12:2021-06-23, 2021-06-23 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 priorityscore=1501 adultscore=0 phishscore=0 lowpriorityscore=0 mlxlogscore=999 impostorscore=0 mlxscore=0 bulkscore=0 suspectscore=0 spamscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2104190000 definitions=main-2106230093 Subject: [dpdk-dev] [PATCH] eal/ppc: ignore gcc 10 stringop-overflow warnings X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 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" Suppress gcc warning "warning: writing 16 bytes into a region of size 0" for users of the POWER rte_memcpy() function. Existing rte_memcpy() code takes different code paths based on the actual size of the move so the warning is already addressed. See also commit b5b3ea803e47 ("eal/x86: ignore gcc 10 stringop-overflow warnings") Signed-off-by: David Christensen --- lib/eal/ppc/include/rte_memcpy.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/lib/eal/ppc/include/rte_memcpy.h b/lib/eal/ppc/include/rte_memcpy.h index c2a1f356d5..a84893cf8e 100644 --- a/lib/eal/ppc/include/rte_memcpy.h +++ b/lib/eal/ppc/include/rte_memcpy.h @@ -18,11 +18,16 @@ extern "C" { #include "generic/rte_memcpy.h" -#if (GCC_VERSION >= 90000 && GCC_VERSION < 90400) +#if defined(RTE_TOOLCHAIN_GCC) && (GCC_VERSION >= 90000) #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Warray-bounds" #endif +#if defined(RTE_TOOLCHAIN_GCC) && (GCC_VERSION >= 100000) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wstringop-overflow" +#endif + static inline void rte_mov16(uint8_t *dst, const uint8_t *src) { @@ -198,7 +203,11 @@ rte_memcpy_func(void *dst, const void *src, size_t n) return ret; } -#if (GCC_VERSION >= 90000 && GCC_VERSION < 90400) +#if defined(RTE_TOOLCHAIN_GCC) && (GCC_VERSION >= 100000) +#pragma GCC diagnostic pop +#endif + +#if defined(RTE_TOOLCHAIN_GCC) && (GCC_VERSION >= 90000) #pragma GCC diagnostic pop #endif