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 EEC36A0C43; Tue, 19 Oct 2021 13:27:42 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8D88A411CC; Tue, 19 Oct 2021 13:26:26 +0200 (CEST) Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by mails.dpdk.org (Postfix) with ESMTP id 3277A411C1; Tue, 19 Oct 2021 13:26:21 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10141"; a="251953673" X-IronPort-AV: E=Sophos;i="5.85,384,1624345200"; d="scan'208";a="251953673" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Oct 2021 04:26:20 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.85,384,1624345200"; d="scan'208";a="566912532" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by FMSMGA003.fm.intel.com with ESMTP; 19 Oct 2021 04:26:19 -0700 Received: from orsmsx608.amr.corp.intel.com (10.22.229.21) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12; Tue, 19 Oct 2021 04:26:19 -0700 Received: from ORSEDG601.ED.cps.intel.com (10.7.248.6) by orsmsx608.amr.corp.intel.com (10.22.229.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2242.12 via Frontend Transport; Tue, 19 Oct 2021 04:26:19 -0700 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.174) 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; Tue, 19 Oct 2021 04:26:19 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RxBkw8hSw5cxFEfrVmDRX8ROc2awEawFQ1RhU2wlkScDDMGDzaZvcZOiCjm4xKNbx8Zj5UzSh77ekyVerD+qVsjhoQB+PH+rxMuGj3MIbMwKBnceBKWjrSCI/jeo/tCCOxgANYD6Oa10jHxbgd98aC7BG0HN7nwOPwTwgzd/KOyCZ5Xs3PZFAmzQghYn2KXwL/K7ylQRbLD+cwlgfb4SAF06Nq7WFMAxPft9dGnZ+GYaFqcpQXfJ9RZm79hNJ+jD9CqlavsKbtFgU9MC1wlAdBkN49YYoLYBn8cJOdjHhOy3XAJWpF7PMdWxCzfmL7wo7fWUYD1cI0xEzxSnVLbpRA== 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=YirZekZnhb38nH15LHrg8AHqA04mxqFb4yLvdLrL4Jc=; b=fZw/3jAmB1wjfoP3h/euy4mm4h7d/ANAigGFCruE20XPCdkjY/TsKIK+gIaWiBJMG69kK4ml6pQ5CBJ4cgRfswYlYgCV2CQ8dbdDaIJW+9hE7B0bmyySMPtuW7QJtyzRDjTsVuHUtIZpTuuxxonnVUBOTq2PQ/iEuKjeGZ1zQmvkBbnGtOdmOMcYcfIP2tO/+gGw3EhIlG8K2b+rw1lGCu8ZRnOLNkG+RJUn4RbilQ2+R8WEZlGlS/Y3RFtiL+kr4v4d4l/tAiOBu/R0I2JUgZsPXdVlEXLdkU+lZraof62ZmjZDZJPnFGdIX6+idMktWO1nSo4sX61gb8O5BbDFTQ== 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=YirZekZnhb38nH15LHrg8AHqA04mxqFb4yLvdLrL4Jc=; b=KYtqNlDJSe4TZpo0vB2tirKam4ceKGVbTJxAU1C7TcLqK+pmEVaMIeSQ4VD9Vc7q0ovKAkDQqtVeiy8wTQ3aoWkkCIIWnmQOw63kHf79blWZcI47g3E2lHm1FAUCiTEed/eK601xbqdnzUgktUTk6QC2rwey8zNMGEBHCFbAP2s= Received: from DM8PR11MB5670.namprd11.prod.outlook.com (2603:10b6:8:37::12) by DM8PR11MB5624.namprd11.prod.outlook.com (2603:10b6:8:35::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4608.16; Tue, 19 Oct 2021 11:26:18 +0000 Received: from DM8PR11MB5670.namprd11.prod.outlook.com ([fe80::c0f1:1135:ceb5:ac10]) by DM8PR11MB5670.namprd11.prod.outlook.com ([fe80::c0f1:1135:ceb5:ac10%9]) with mapi id 15.20.4608.018; Tue, 19 Oct 2021 11:26:18 +0000 From: "Dumitrescu, Cristian" 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" Thread-Topic: [PATCH v10 3/4] pipeline: Fix compilation error with gcc ASan Thread-Index: AQHXwdb4fgusEoCIykul3Qb0NwXkI6vYsRKggAAJ4ACAAXbXQA== Date: Tue, 19 Oct 2021 11:26:18 +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-version: 11.6.200.16 dlp-reaction: no-action 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: cb257932-97bc-4d68-0e52-08d992f344fe x-ms-traffictypediagnostic: DM8PR11MB5624: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:9508; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: OEsligt9ygT9brKkIr+nSYzCuEhcPZB1lUA5nJw0KexSemCnDKxhwnwqGutJKb5KeF/CrYHnsz1H0pUSA5xdDDBDRXYpkJFHbGKHhpVePU3FYdR4mdyoMH3a2cAXLHU4ZMhz6MKJEIJ5QXdlk+Mh5Y032ADl9G5oQ52aQGMxe2tpggDWBsLxG2/J4dAKzWIrBG3N3ferSn813WI7oMP/MxpUKiF6KnLkrCklWJk5ZZsK6VceEkyMq33p6uSZUqE68KnMaZofigCNatQwy1yyZNHOXt/FOuXnzNYm5uoC5VQd6A4P7t2L7OLDqo0brDtQvw1NrWNebubDJq3ifnO4iLHF+w1MOyXmSV02tcDJsxXpsMLsV+jCMF2gOTM9Y4Lqzl1+PKcmxlotcHU+vT6bId6xRZZEQgSP6Bw5Z8EQNfYh78AStWgBcvEGPXjVAT9fOdeFLURujej9QKHSJVQI83BzIgleS2LF6MpqkbjrtcIFK2eLYtVflNOFN7MAU5YwbKJXEf84ZbWYz9V5LhbSGBhiCzkwb+q77A3sNlF+7O6LPz9lQ/IL7sJpy0uB6rFqeVxs95cmK1IHgrQ0A/7QsL//sEWIHi35xNck+aH2m6Wvebj2HqZErwX2RNQRfkmdFWIR+Dq8eOfi1Jxie58srRMorRNOjBsiE13c619UaVhDlIFIhgz0ROXP+8oHuORFc5p5WLqWQmWlVfrYfSbtKzK3G5YDNa2zmhhiWhJIFhs= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM8PR11MB5670.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(83380400001)(5660300002)(66946007)(71200400001)(8676002)(54906003)(53546011)(64756008)(6506007)(66556008)(186003)(33656002)(66476007)(4326008)(82960400001)(26005)(76116006)(7696005)(8936002)(66446008)(38070700005)(86362001)(2906002)(508600001)(6636002)(316002)(38100700002)(921005)(52536014)(55016002)(122000001)(110136005)(9686003); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?ajnhFVS72+WjBJZSdhATt5bvPrMhs5VokUctIk+cMQvWt+NuQ5qUH/NogZXS?= =?us-ascii?Q?aHTVF4YSMBDBazoTaez8fuu93w8gLI4hNoj8ln2e/K/4m7WtfJLBOCZYynHW?= =?us-ascii?Q?PptogCf+KpFGKSCkuyIR/22JVUhG8HcNZMC4/tomNvqOpJlSc+lMGqkhVQYi?= =?us-ascii?Q?/sFE8NkdqBJ/qVEMa6akfbtdM8+PKl5U2h9hW+qGZ5c46DrE3CuGpxJx6p+w?= =?us-ascii?Q?reHEOBGlRIj3OaF8Aqo0NdtiC/9glor8KbplHS89R5xKDyMqfwFTkR2X58eH?= =?us-ascii?Q?aXaL/MyrwXtVeau5SHaSYkriCUCTyEjjAe5mhM+Wxr0rsDVCb9VcAGvAI60S?= =?us-ascii?Q?0Sz0JOVHPMby9icSHZUQC0qUb/QL6qYokjMpyJq9xTzKY4z4bY9GCxCHx3Hk?= =?us-ascii?Q?cHbk6zDbhZsqoqaz6okwAAaiut6KD3p1aJ/6TiN0NUH3vMv3O/SyPspL2rNX?= =?us-ascii?Q?StEl5ObDsgeSufqnrYYrNCupFT0l4TlsLkxvEU7qzuZp/+/zRTmwih2jGm46?= =?us-ascii?Q?UowVukm33ai2diN0XXcORuYfgH9eyI+NolLrO6MRZUf8ky5r8GghDR35wQRW?= =?us-ascii?Q?RiCmjjDAZ2QITPqiDhA4ORvtAU1sJGQS8g5YlOZ29u+TVz/tBcu9g/KU0HRQ?= =?us-ascii?Q?SGcgYWDqc0iKyWWyZgnIMgwocSc60jEY6jWn8OeWVbiINRfEOgBQG70U99r8?= =?us-ascii?Q?P6OY4vdZipsg9sT/IUfg67dH8NuqGHyVQasJb3AwM8Njca6m7RoFyY+T50yO?= =?us-ascii?Q?or4k9opC9v/kJ8TF4KutrPAGVW/sRpZJ2L7BPHuQzFrwENOo2dpCtGgkIQaf?= =?us-ascii?Q?A8XZFoO52oYpUns72WWSk/TfSqF6nyjp/AwwfqeiOgsSxLhKn2BcFH1/Et6k?= =?us-ascii?Q?LzHonc0ME/clp/ZtM34S0d19ypMm28rumoSkGej+dNln168SXUgOnz9jm46p?= =?us-ascii?Q?VqgsBOb/RuLZXnfB9eYMGELhBqIeLvg1/baqXDeWNMSNL5VUTpbQ9m3qbxgX?= =?us-ascii?Q?RiA/ME5DPyObrblaKc3Jeu6v13q5TK3t0ucpaY5yw8D0eqOre0teuaC2T3I3?= =?us-ascii?Q?YIy1bh1QutgAPvllgpg9J7VuYFfWXvlG47uj3eFGYNsCeHCJWgI85ZIQZcv+?= =?us-ascii?Q?gNVuww+VYdgtlzl/ZGOp6n3CH78/FBzq/ZxwoeSPxNiGDsVp9Qllkj+kzyZR?= =?us-ascii?Q?oEjjY28mDwzMf5oEyertxt5RrMFDZiKuZM3hRoM3R/lfyW1vRvNewbVHteEn?= =?us-ascii?Q?ZERKkhzzKSCsPqhVqyDXjjatmxjydNKr8t3W93MaAIEKqrQ3VUQvPFVhhvx0?= =?us-ascii?Q?J7DPmKhCQXANOOej3aDATz/4?= 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: DM8PR11MB5670.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: cb257932-97bc-4d68-0e52-08d992f344fe X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Oct 2021 11:26:18.0201 (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: ju++KTngT9Zv6tO885SFi3ZuffMPSfywtIId0bl7EyopqJXvmytTiD7TBmE/2NQ8EN7/FVIUsdbnST7YTufznUXnnI3f/mIl5YX1LW1tlW4= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM8PR11MB5624 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: Peng, ZhihongX > Sent: Monday, October 18, 2021 1:55 PM > 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 > Subject: RE: [PATCH v10 3/4] pipeline: Fix compilation error with gcc ASa= n >=20 > > -----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 A= San > > > > > > > > > -----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 ASa= n > > > > > > 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 > > > > NACK. > > > > This is a false issue, no bug is here. CHECK(0, EINVAL) translates to a= n > > 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? >=20 > Yes, this is not a bug, it just solves the problem that cannot be passed = after > adding the asan compiler option. > Only part of the macro reports errors, which may be caused by the tool it= self, > but this tool is part of gcc and clang, so we still have to make the code= not > report errors. > > Regards, > > Cristian Hi Zhihong, If this is not a bug in the pipeline library, why then does your patch has = fix in the tile, has the Fixes label and CC-es stable@dpdk.org? Please remo= ve and rephrase accordingly. I agree this is not a bug, and based on your statements I understand this i= s a sort of issue or limitation with the tool . I would prefer we fix the t= ool rather than fixing correct code in order to please the tool. This is li= kely not going to be an isolated case, but a recurring issue. Hence, I am reluctantly OK to ack this patch in order to allow the tool in = (after the "fix" claim is removed), hopefully the tool will prove its benef= it to DPDK. Regards, Cristian