From patchwork Thu Oct 14 19:05:00 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Christensen X-Patchwork-Id: 101678 X-Patchwork-Delegate: qi.z.zhang@intel.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 C1457A0C4B; Thu, 14 Oct 2021 21:05:14 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8668B4067C; Thu, 14 Oct 2021 21:05:14 +0200 (CEST) Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by mails.dpdk.org (Postfix) with ESMTP id 7FE5F40041; Thu, 14 Oct 2021 21:05:13 +0200 (CEST) Received: from pps.filterd (m0187473.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 19EI2Hcl032961; Thu, 14 Oct 2021 15:05:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id : content-transfer-encoding : mime-version; s=pp1; bh=HgwJhJ4HFKZTWo4pvcbAEjbrSx79w2MWz4O47xHn5Cg=; b=XcY/lf3BJcaI4Xet+wjLAxpByBNbL0ys0q1N4fP7K1J0rOs/IYfwUjql5z5uAxP9Xve7 JvRFpUkPjuiLK1XcprEBGixw63cR77kx+gJ8Z3aiAxU0pTnMrR+RccGFybAirEwVxJuv lqEgaaQp/QvY8a38/gapALN5XobbZpj5rML2S2KtMIdhOJa1e6sL18jJCVb58KL3wRvb QamP62l50FB+z9kKlBZbc7yFtauk4KB80G/q69DLOgzpd3f+XQky15P+IAOODBX7jxfs IhQdwLIHKSKyGEXq2lmouwFafD3VHh0q3M8oJGGhVR5ETkw2zl18Gvia7ljyK06Pp3Pi PQ== Received: from ppma05wdc.us.ibm.com (1b.90.2fa9.ip4.static.sl-reverse.com [169.47.144.27]) by mx0a-001b2d01.pphosted.com with ESMTP id 3bpm7bjma8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 14 Oct 2021 15:05:12 -0400 Received: from pps.filterd (ppma05wdc.us.ibm.com [127.0.0.1]) by ppma05wdc.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 19EJ1nMO019484; Thu, 14 Oct 2021 19:05:11 GMT Received: from b01cxnp22034.gho.pok.ibm.com (b01cxnp22034.gho.pok.ibm.com [9.57.198.24]) by ppma05wdc.us.ibm.com with ESMTP id 3bk2qcq140-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 14 Oct 2021 19:05:11 +0000 Received: from b01ledav002.gho.pok.ibm.com (b01ledav002.gho.pok.ibm.com [9.57.199.107]) by b01cxnp22034.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 19EJ5ACh37945736 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 14 Oct 2021 19:05:10 GMT Received: from b01ledav002.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 64AA4124064; Thu, 14 Oct 2021 19:05:10 +0000 (GMT) Received: from b01ledav002.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 534A3124074; Thu, 14 Oct 2021 19:05:10 +0000 (GMT) Received: from localhost.localdomain (unknown [9.114.224.51]) by b01ledav002.gho.pok.ibm.com (Postfix) with ESMTP; Thu, 14 Oct 2021 19:05:10 +0000 (GMT) From: David Christensen To: dev@dpdk.org, beilei.xing@intel.com Cc: stable@dpdk.org, David Christensen Date: Thu, 14 Oct 2021 12:05:00 -0700 Message-Id: <20211014190500.2657413-1-drc@linux.vnet.ibm.com> X-Mailer: git-send-email 2.27.0 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: MX_G5k0BvkeIkn-VwnJcZIhIifUNu3GM X-Proofpoint-ORIG-GUID: MX_G5k0BvkeIkn-VwnJcZIhIifUNu3GM X-Proofpoint-UnRewURL: 0 URL was un-rewritten MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.425,FMLib:17.0.607.475 definitions=2021-10-14_10,2021-10-14_02,2020-04-07_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 suspectscore=0 adultscore=0 clxscore=1011 mlxscore=0 mlxlogscore=999 malwarescore=0 spamscore=0 phishscore=0 impostorscore=0 bulkscore=0 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2109230001 definitions=main-2110140107 Subject: [dpdk-dev] [PATCH] net/i40e: fix gcc 11 build warning on POWER architecture 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" Building DPDK with a gcc 11 based compiler such as the IBM Advanced Toolchain 15 (1) generates a stringop-overflow warning when using -O3 optimization (DPDK default for production releases): writing 1 byte into a region of size 0 [-Wstringop-overflow=] The issue has been reported to the gcc project (2) but can be resolved by preventing the compiler from unrolling the loop as part of the -O3 optimization. (1) https://www.ibm.com/support/pages/advance-toolchain-linux-power (2) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102316 Bugzilla ID: 743 Signed-off-by: David Christensen --- drivers/net/i40e/i40e_flow.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/net/i40e/i40e_flow.c b/drivers/net/i40e/i40e_flow.c index e41a84f1d7..17ab7ad9b9 100644 --- a/drivers/net/i40e/i40e_flow.c +++ b/drivers/net/i40e/i40e_flow.c @@ -3047,6 +3047,10 @@ i40e_flow_parse_fdir_pattern(struct rte_eth_dev *dev, return -rte_errno; } +#if defined(RTE_ARCH_PPC_64) && defined(RTE_TOOLCHAIN_GCC) && \ +(GCC_VERSION >= 110000) +#pragma GCC unroll 1 +#endif for (i = 0; i < raw_spec->length; i++) { j = i + next_dst_off; filter->input.flow_ext.flexbytes[j] =