From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 18423A0C43; Mon, 18 Oct 2021 14:54:46 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 06D6340683; Mon, 18 Oct 2021 14:54:46 +0200 (CEST) Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by mails.dpdk.org (Postfix) with ESMTP id 5E24240141; Mon, 18 Oct 2021 14:54:43 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10140"; a="215167521" X-IronPort-AV: E=Sophos;i="5.85,382,1624345200"; d="scan'208";a="215167521" Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Oct 2021 05:54:42 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.85,382,1624345200"; d="scan'208";a="462315373" Received: from orsmsx604.amr.corp.intel.com ([10.22.229.17]) by orsmga002.jf.intel.com with ESMTP; 18 Oct 2021 05:54:42 -0700 Received: from orsmsx611.amr.corp.intel.com (10.22.229.24) by ORSMSX604.amr.corp.intel.com (10.22.229.17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12; Mon, 18 Oct 2021 05:54:42 -0700 Received: from ORSEDG601.ED.cps.intel.com (10.7.248.6) by orsmsx611.amr.corp.intel.com (10.22.229.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12 via Frontend Transport; Mon, 18 Oct 2021 05:54:42 -0700 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.175) by edgegateway.intel.com (134.134.137.102) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2242.12; Mon, 18 Oct 2021 05:54:41 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=PQExS7xGZ3Qx8klD38R7lJEpChoFLJKxFxtnmvMgtJTcKQfjUop/3W7bn+zT+V+pQn3X1jeXdB4d6H0qe44HGYOSybAkMzuFwVG5opgNzmk0gXU9W9V3+423oRXktn7q/O7SmsWQ35t8kkgIn9mWHhOaesfuCherbZa53+pVvColNsbPOOvTKqeORUq3Pxolhstz1dsWQC4CSgIDfQlNglzghDVp2n1GY/cnK++tSM3eay3ojTXiDf8/4HveJUXP0ZIf4HYBuNFHJvGZZYsY3N1SYng+5kFz+tmAjKPVCTwjAvFHsFvIf/2ewipgYwogWRxA+oMBvwQ5IrfTwZCY7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=9wgP2zZzk1OuOM6yiir73dB8n5p2HBnCtNjHjpKZVjc=; b=dG8NfIXY7vhdJYPK8hvN4ySfQwx44O+F8pYzmv01hvU+qCa9uAq12h5W8BQIYrwz9wRjcvou9hmszfl/oIgGwkjeKDWGBnYpqF6Plc8sT2dmY3Ru1sJhbD5BFylVvR/IoNU66Rh2FCCmLpWFKybfaNGjVCrkro+snKzZ76P4DH/jaK36spLLc0c4IPzLcrxik59gT5fYaQLgMbaXRkRbtJaNBVJYOrlhzG/y/ZAtIdG41LNXQkHKwxznuUUYILDSRUqXJ6EFkawiMCeViC920oxRA4mkCYMp79r2O3yRtzl4zNRQ1GkLrIMlrBCUe40xhoRdUh5ZXWLmSd6aJGtKtA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=9wgP2zZzk1OuOM6yiir73dB8n5p2HBnCtNjHjpKZVjc=; b=XCgNJy2NdARLu2RxIC8/90p0uJfgB2P3wznk3UWwHASos7JEvzHtxmDzlHwgMBPh6/jTPAcpXK1I5p5QL4ACXBAQCzoPi+rjBj2cBDPjuAahxzhGwK8oILrFsCx5F/OeOjw+aW38WmeUUGhUwbbt3kLhTtDpuDE6HgU5YbGMGZ8= Received: from DM8PR11MB5591.namprd11.prod.outlook.com (2603:10b6:8:38::23) by DM8PR11MB5670.namprd11.prod.outlook.com (2603:10b6:8:37::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4608.16; Mon, 18 Oct 2021 12:54:40 +0000 Received: from DM8PR11MB5591.namprd11.prod.outlook.com ([fe80::3d47:b590:aa2a:d5cc]) by DM8PR11MB5591.namprd11.prod.outlook.com ([fe80::3d47:b590:aa2a:d5cc%9]) with mapi id 15.20.4608.018; Mon, 18 Oct 2021 12:54:40 +0000 From: "Peng, ZhihongX" To: "Dumitrescu, Cristian" , "david.marchand@redhat.com" , "Burakov, Anatoly" , "Ananyev, Konstantin" , "stephen@networkplumber.org" , "Mcnamara, John" CC: "dev@dpdk.org" , "Lin, Xueqin" , "stable@dpdk.org" Thread-Topic: [PATCH v10 3/4] pipeline: Fix compilation error with gcc ASan Thread-Index: AQHXwdb4MCLzvrSLWE2rXVTEXkKXIqvYscmAgAAE9PA= Date: Mon, 18 Oct 2021 12:54:40 +0000 Message-ID: References: <20211012094318.1154727-3-zhihongx.peng@intel.com> <20211015151110.1876850-1-zhihongx.peng@intel.com> <20211015151110.1876850-3-zhihongx.peng@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-reaction: no-action dlp-version: 11.6.200.16 dlp-product: dlpe-windows authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 1664ad76-3559-4e71-8375-08d99236731d x-ms-traffictypediagnostic: DM8PR11MB5670: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:5797; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: hwd9vjdErW61nK317RUivdFggxpRUWYlK/fNka9zAmB8V0wf/bcBfm1s0R2vqDzxxpFWV8v5NKVj4Kww39lkXqJjWi6MI0cnLbXmp5VDsVPCbXQKNvnVNrNtggrDANhpHkATr00oKpD8s+a6qqdIanRRyRJfg4GV284S1aI3DzEUtKZuEVnl6Rj60DM68RDYzVdDlG94T/5e1Cr3Sa5Yc6plzXJ5zIK53QYKY9koH1A842p/6/xT2Nx+97Vo1tihDzx/fOZ+KgwlI7Wp7vM3EhsH/t6jlovu6scbGSowWB8VwPV39V/BtldZwB0szSk9xBJzwJJwHscRWeCWXCzYQGga+b80fu5p8ddYHRwQoJIvW5k6eY27yqsIKMTa833JKmQg1B7f+V96EhU7rWz7EG7pGNPE3WgDcJDKDdlydP4NKh3C/scNbs99V369xoKy02Fc80q93CoMPI0dJOEObx6lm04NJBpe68wX3OyOCv7Jdy/QT3PTc4Bh0m6qH7RRgWDg43657dgzz+AwV2jmrkyQMhwGGSBkXVpRxPSKmpiTBmBNdE0U3EjIfhgdXciY+3upvx0+nSovCNs/sYbuIRuI9kvPA+dJpoxcsJ8w4NqIWk0oIRySpxV8JEXbrM3XsFpLbzSiv+jpw1ZSqfHjaEHJGOdZXqh6noCu1NWoq60Rf68GHl/NCC52RiRJxI5m519+la433ADJlwpyhFMw0+HBazIdo4tHLMdUuKls00s= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM8PR11MB5591.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(83380400001)(2906002)(186003)(6636002)(54906003)(316002)(53546011)(71200400001)(6506007)(7696005)(122000001)(8676002)(66946007)(38100700002)(33656002)(5660300002)(4326008)(82960400001)(86362001)(110136005)(8936002)(52536014)(76116006)(508600001)(9686003)(66446008)(66476007)(64756008)(921005)(66556008)(55016002)(38070700005); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?UKlkyIOIZB0I2kJsvpb4CQJ/I/KXJW+EJhOLBX8kFrN4tAtVxK3x/jvQ6pB6?= =?us-ascii?Q?dLyssO6VvIvdTS8dvZVBX1kyuB+clnIDMvDLRcBCm+7y8Hgphp/WmWl6lJ+d?= =?us-ascii?Q?lA2x5h+Mwlw1XueAYtf2Ae/4II7ZIy7pQARS4wNzoR9I6klSb9iVCMYPzJmZ?= =?us-ascii?Q?siuqZc7FClnm1qsMspIowCUg7JmT9SCqnUO3OsP7D1G3XMzJih230xkpTKQJ?= =?us-ascii?Q?raLb2JVbBKi6yFoi7hyi+NRjxf4LHCaiEJ/t8y6XAnQSAkcqQYTY2y4jDFyV?= =?us-ascii?Q?lZypkldJNywBH1IHINUvZpWsNiRJwZP3Aa610ZBZIC5sF0cFzjO5n8Xerm2m?= =?us-ascii?Q?oFzlYD/6kEpWuNfxrDut9iLMFKkoNZisTfxXlI71vNm34wfd+bPBNgco4iUK?= =?us-ascii?Q?s4f5ROx1g7g6U9UP9WapjJt5ypW3gvlbDvFhH00XPhVqOwfhpz+k+OhoRyJC?= =?us-ascii?Q?++hT8D/cdKmsmXX+bqfzNE5Pr3fXU/8ThM8hyql2IAq2vSDbR3w9a0cH7qdG?= =?us-ascii?Q?x0m0ZujHpp2ny9IElCcrMvaQt4yyAq3LcZDHN+3NQSHSVmf2vn42/9YkTxL5?= =?us-ascii?Q?Tf6MRr1s2tFb+7jTw2fydRa9dnXQWs4DkQEwSapaRn3lv4XTpIUiOLfdxgDD?= =?us-ascii?Q?YCXUUUBU8ZxspJpnG0x6L3ImM9okCFrXP5x4vCgmPUKptw+NrkKI4xYRl03V?= =?us-ascii?Q?/hdkT8UfoQtKDemad258bmfftNzbPbaZqlDPWFWsF/xMZnrEOAYF63VOWrtY?= =?us-ascii?Q?i1H+74ZDRFWgck3phDD/e7m2W+SE/Qgv6M8cPnXO2BloN5HkhYVFOR202R+G?= =?us-ascii?Q?X41WGgkaiCp2AABGD8snzPX8YM25y2T4Qe3tHeN2KE1hOuuJExUqX0uhA22b?= =?us-ascii?Q?WTK+T7WdyvOPzi4NiF3qrYVAT2+TI30ZQiiJJ3VIkDEelEq8YLenhzFeR03/?= =?us-ascii?Q?C6CPg3YLxShBglCbXgMcR0QFpDunNWRrhKyuQi5HuwnvI0C4ZjYCZZkXq56S?= =?us-ascii?Q?ziqHxV5GgEV5sX64acinej7PRlwHQwfwaUzoWU6SH/nIMOFWKgCq2dbCh5rP?= =?us-ascii?Q?xpdR4u7FCc4hYXmxZI7n3jucpBJttT6iIGFc6AX+XUupS5J59W5f097NAOi0?= =?us-ascii?Q?LAKBpK4+Lgy+cAXW0uxD8OMTOgUzK1kmC48D0c6hsvKcE4WHP83iPKHXOzCk?= =?us-ascii?Q?dbo1gKT15dZJL10nOCiCAEDfUjDnozYczz7K9qJi3OzCuGVBhCeAwBgy9JGa?= =?us-ascii?Q?XFIUiqf6CEsizpQE5oVkdTaAAJquaIj3I9qbyt9fySecCeJFeLiRCVxM60DJ?= =?us-ascii?Q?YfJZF19rSvnyj2j42KWOIdS9sY5LSGlbUb46ckSwsvPrx617fXE0FOyCKtg3?= =?us-ascii?Q?5KdPPTqwzq807ezg/icGnDfF689Q?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM8PR11MB5591.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1664ad76-3559-4e71-8375-08d99236731d X-MS-Exchange-CrossTenant-originalarrivaltime: 18 Oct 2021 12:54:40.6192 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: QbCl9KXXJcrWsR6FVlkkAZ1nIFpfesteWTC6Y17ygYz9JwZ0HVYyehfG8QbL317loDAyfoZz/pIDol/HODJmPg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM8PR11MB5670 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH v10 3/4] pipeline: Fix compilation error with gcc ASan 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" > -----Original Message----- > From: Dumitrescu, Cristian > Sent: Monday, October 18, 2021 8:22 PM > To: Peng, ZhihongX ; > david.marchand@redhat.com; Burakov, Anatoly > ; Ananyev, Konstantin > ; stephen@networkplumber.org; > Mcnamara, John > Cc: dev@dpdk.org; Lin, Xueqin ; stable@dpdk.org > Subject: RE: [PATCH v10 3/4] pipeline: Fix compilation error with gcc ASa= n >=20 >=20 >=20 > > -----Original Message----- > > From: Peng, ZhihongX > > Sent: Friday, October 15, 2021 4:11 PM > > To: david.marchand@redhat.com; Burakov, Anatoly > > ; Ananyev, Konstantin > > ; stephen@networkplumber.org; > > Dumitrescu, Cristian ; Mcnamara, John > > > > Cc: dev@dpdk.org; Lin, Xueqin ; Peng, ZhihongX > > ; stable@dpdk.org > > Subject: [PATCH v10 3/4] pipeline: Fix compilation error with gcc ASan > > > > From: Zhihong Peng > > > > The gcc will check code more stricter when ASan enabled. > > "Control reaches end of non-void function" error occurs here. > > > > Fixes: f38913b7fb8e ("pipeline: add meter array to SWX") > > Cc: stable@dpdk.org > > > > Signed-off-by: Xueqin Lin > > Signed-off-by: Zhihong Peng > > --- > > v7: no change > > v8: no change > > v9: Modify the submit log > > v10:no change > > --- > > lib/pipeline/rte_swx_pipeline.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/lib/pipeline/rte_swx_pipeline.c > > b/lib/pipeline/rte_swx_pipeline.c index 1cd09a4b44..0acd6c6752 100644 > > --- a/lib/pipeline/rte_swx_pipeline.c > > +++ b/lib/pipeline/rte_swx_pipeline.c > > @@ -4642,7 +4642,7 @@ instr_meter_translate(struct rte_swx_pipeline *p, > > return 0; > > } > > > > - CHECK(0, EINVAL); > > + return -EINVAL; > > } > > > > static inline void > > @@ -5937,7 +5937,7 @@ instr_translate(struct rte_swx_pipeline *p, > > instr, > > data); > > > > - CHECK(0, EINVAL); > > + return -EINVAL; > > } > > > > static struct instruction_data * > > -- > > 2.25.1 >=20 > NACK. >=20 > This is a false issue, no bug is here. CHECK(0, EINVAL) translates to an > unconditional return -EINVAL. > Does this tool work correctly when macros are present? Maybe the tool > should parse the preprocessed C code as opposed to initial C code? Yes, this is not a bug, it just solves the problem that cannot be passed af= ter adding the asan compiler option. Only part of the macro reports errors, which may be caused by the tool itse= lf, but this tool is part of gcc and clang, so we still have to make the code n= ot report errors. > Regards, > Cristian