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 1729E42925; Wed, 12 Apr 2023 10:48:09 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A4DE840FAE; Wed, 12 Apr 2023 10:48:08 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by mails.dpdk.org (Postfix) with ESMTP id 7DBC04067B for ; Wed, 12 Apr 2023 10:48:07 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 33C8BV6S014517; Wed, 12 Apr 2023 01:48:06 -0700 Received: from nam12-dm6-obe.outbound.protection.outlook.com (mail-dm6nam12lp2177.outbound.protection.outlook.com [104.47.59.177]) by mx0a-0016f401.pphosted.com (PPS) with ESMTPS id 3pwf5ju5ky-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 12 Apr 2023 01:48:06 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jRX9AzkjeCxTW5YRT7aZU8EgFensAPi+1rzkLZyhV5aZuJDkFSjOO4NFLjNRqXyboCxUnjF9ePCQDIxT/MlM196DsdgxUriGX6SiEnvrG8tG4/z6gdC+L2SZkdSvY+gTBqzEijEkgLnzxJxC0nl5Qh/IlGob9wWXJal45NFYl6pFBCmoXze/doCwuhzjDEeBULr0y37OEo6v+iA/YxVkas1jLi6bkNUQKfinkmNMGUQV83wub4u/+7bGt1YWq5bKN6mN/mVTjIsoKA/mqxFVjxEgQKrMWEeYgq2ZF0XkO/yIsrPdbnXCtWCeYlSYF73wk2fHDOZ0JcgaKx/ENhuuAg== 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=HJ0C7H0PCaiEC7cVCRspq59tD5C1wmhAIDNJc/kuTdQ=; b=ZZMaa6Q4jQXH/52+bmlYhPy+fmc/GT/gOOQDkEdKDLk37M7xir/HVtaTv4dPoEYoavdtSmbKqmbpZP9EgaE2JebF22b98G35cG2fMlsjvBQI0l2G2Tiv+ZJwevH08JabBzplQQh5ySgIAkT/VK6GZiztrsOMX3/QLu5jBg8hHup94qiJEmlW7DBWCYVa3HyGMSPSdHeR1rcjQXChxZJz25Q/h3RX8ZYa/autLcGPvFq7rXYsq2g8QvFMdUNnvpFtPGO+A/ostS53pdKKvJAccSjUjs1SLFannKtArVhr47pNnzkJEnwa8W5MG0hvbvsWKyVuUyYnjPmo7nbQL1RVGg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=marvell.com; dmarc=pass action=none header.from=marvell.com; dkim=pass header.d=marvell.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector1-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=HJ0C7H0PCaiEC7cVCRspq59tD5C1wmhAIDNJc/kuTdQ=; b=qmCMAFjAaa1I9bt3+Lpk62RDYSt5IYHlWi4inkP8zYs53YTqtBNuOlX6V+KRQScA7WgGg+5d4LYi4T8Kc6fqtmpIsJ9n+z0aLEVoJqFXhJhYlHdaWFI7loz+cQpyeLmd6EdpxNk2iwVeBVVqNdwMIPDHmWRyGB7WvN/4TSV+5vo= Received: from CO6PR18MB3939.namprd18.prod.outlook.com (2603:10b6:5:34d::18) by SJ0PR18MB4107.namprd18.prod.outlook.com (2603:10b6:a03:2e6::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6277.36; Wed, 12 Apr 2023 08:48:02 +0000 Received: from CO6PR18MB3939.namprd18.prod.outlook.com ([fe80::17ae:c59c:5662:45ce]) by CO6PR18MB3939.namprd18.prod.outlook.com ([fe80::17ae:c59c:5662:45ce%6]) with mapi id 15.20.6298.030; Wed, 12 Apr 2023 08:48:01 +0000 From: Srikanth Yalavarthi To: Stephen Hemminger CC: Anup Prabhu , "dev@dpdk.org" , Shivah Shankar Shankar Narayan Rao , Prince Takkar , Srikanth Yalavarthi Subject: RE: [EXT] Re: [PATCH 1/1] app/mldev: add internal function for file read Thread-Topic: [EXT] Re: [PATCH 1/1] app/mldev: add internal function for file read Thread-Index: AQHZXZwRAK9JocYynE6FsBjcY04zMa8QX2GAgBcaXKA= Date: Wed, 12 Apr 2023 08:48:01 +0000 Message-ID: References: <20230323152801.27666-1-syalavarthi@marvell.com> <20230328085229.51e5dc06@hermes.local> In-Reply-To: <20230328085229.51e5dc06@hermes.local> Accept-Language: en-IN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-dg-ref: =?us-ascii?Q?PG1ldGE+PGF0IG5tPSJib2R5LnR4dCIgcD0iYzpcdXNlcnNcc3lhbGF2YXJ0?= =?us-ascii?Q?aGlcYXBwZGF0YVxyb2FtaW5nXDA5ZDg0OWI2LTMyZDMtNGE0MC04NWVlLTZi?= =?us-ascii?Q?ODRiYTI5ZTM1Ylxtc2dzXG1zZy1iN2MwMWFlZS1kOTBlLTExZWQtOWYwMS00?= =?us-ascii?Q?ODJhZTNiNmU1MWFcYW1lLXRlc3RcYjdjMDFhZjAtZDkwZS0xMWVkLTlmMDEt?= =?us-ascii?Q?NDgyYWUzYjZlNTFhYm9keS50eHQiIHN6PSIyNDEzIiB0PSIxMzMyNTc2Mjg3?= =?us-ascii?Q?NjQ1NTI4ODQiIGg9ImtGYXpMaUZ3bXNNbWdBakhOV1RRREdFdU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QWJRQmhBSElBZGdCbEFHd0FiQUJmQUhBQWNnQnZBR29BWlFC?= =?us-ascii?Q?akFIUUFYd0JqQUc4QVpBQmxBSE1BQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFCQUFBQUFBQUFBQUlBQUFBQUFKNEFBQUJ0QUdF?= =?us-ascii?Q?QWNnQjJBR1VBYkFCc0FGOEFkQUJsQUhJQWJRQnBBRzRBZFFCekFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBRUFBQUFBQUFBQUFnQUFBQUFBIi8+PC9tZXRhPg=3D=3D?= x-dg-rorf: true x-ms-publictraffictype: Email x-ms-traffictypediagnostic: CO6PR18MB3939:EE_|SJ0PR18MB4107:EE_ x-ms-office365-filtering-correlation-id: 8dcc2bf7-61a4-4402-d1ef-08db3b329f8d x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: ZUPYLZNjDX1Sq2sOC8iMCrL2oWED7qEXTxkXANFcL1zczSOrl/kV9ijRECAr0rMLF2UQTq2mpIcVNx9j9Z/87jXkoWSOWL3MSkBuHvyEub5gEszTOc/a5de5kz+I8+zq3IBeHqJwxxxJR7SkpbA5UG9AOCdaC0wI0E+TbVERyyxvCTVHE5xl4WjGh+aZAlmbiNBc5f6DHiBDGFB0GUzxDvq+oasZFNXH78WmGVxSUMQLgWlnaP4U/hrRBqDCXzyf01fuRGFXxuusHuC/WqVV79Sy+W1ecXE6VJjZEvGqcRVNzPnoX/edFY4cYsplaLKQUSqdOw0CIGXAXpWe3uU4PsrciVazZsAEQIUP1UYOc23FK6ngGQwAlQIqVIl7iTSh3c7rmcOXb3dtcXR9tZPLQoI/zlSTAqaNigjbj2DGWqeir5bhuaVqEwVcrKaQia8wZVzoCgOpSm1JxZYuunPpybNa/Ik8tAFjDBPIZXnC4Rz82JoX0gz891y3hf1LGOysHoyYC46O7ohqGmkL1YdJmnm65zzxBaSj9JxeIFJf9BVdm9ufeYCuK58W45PrTAOONKGv+E0jJiyr7iQM0DLGHRxdVKe4lm+1CD7f3oQLwa2fdKCI0zVCPZ1E3bF9uL6i x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CO6PR18MB3939.namprd18.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230028)(4636009)(396003)(376002)(136003)(39860400002)(346002)(366004)(451199021)(107886003)(8936002)(55016003)(52536014)(7696005)(5660300002)(6916009)(86362001)(4326008)(66556008)(8676002)(53546011)(64756008)(66476007)(66446008)(66946007)(76116006)(478600001)(33656002)(38100700002)(38070700005)(316002)(122000001)(54906003)(2906002)(83380400001)(71200400001)(6506007)(9686003)(186003)(41300700001)(26005); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?vvERlvF2pj4eIy9PM7WIGfW92kioL9bAoiCRZZPTfc+D+RFeRuAJ0ldIqhn0?= =?us-ascii?Q?ISx9nWYCZljSlZLReBwFagnXkEILAozrtviSNhAhNzuMgFNFklb+WQaHlvip?= =?us-ascii?Q?yQBH6uf3E2hppzKq3eUCIkGInxDaEb38t6rq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A+uyHZuV5QTHzwfWttwqhsSgiDuX+3PndA/r5N6Y/izn8CMZgvrYPurd?= =?us-ascii?Q?MjA+sbFHObYeAGBKdURbBbS8NVdbukoQVVylDSt9FAdL6lkNU1XxMl2WN6hH?= =?us-ascii?Q?iOrcNPixacRiGx9fVvUf4dilP6zrkFOnekHJX6BXU6RPmscZV2benhtwVoAw?= =?us-ascii?Q?5C65iglsDeps0tesWzsOMGWA0c/IdYBuTKwKi/W2Z/+cJkYogVMmOrFifvoF?= =?us-ascii?Q?SVTzSLafsbedY5iNulzbcVjEt/N99d9f8W/xlGTDXnotZ5mscPwM/D3rtSJC?= =?us-ascii?Q?J+fKIBqF5TTeMY0g4t7SStsRREg183Tu21KsEjmanQqAVN8mdAG2AXmv/cuj?= =?us-ascii?Q?69JNKJGT0uaZXD9Q2QgaBygtjK8z0K8avvS24x6SPyK6MhL7wz1Tw9y3E7Qz?= =?us-ascii?Q?NfzwHZ/yhaC7g5cM+Yrp14YTNZ6uFD8TK+tKfOJnEeAJZw2jLJVDkSsU67cb?= =?us-ascii?Q?HGwlw0Rb1rpHYjZDFKR/eOmsnWaAZpsGxqZtiM6VvxUOIJ1skhDe7Xw8O7tq?= =?us-ascii?Q?+N4aulsJykn2DbdD9rt3h7WVLayV7VIPXRbsp0Yz?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: marvell.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: CO6PR18MB3939.namprd18.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 8dcc2bf7-61a4-4402-d1ef-08db3b329f8d X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Apr 2023 08:48:01.3709 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 70e1fb47-1155-421d-87fc-2e58f638b6e0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: aHn0ZnD5wmXgBSyVuX1I3osZkMjL/sA5m7AjvK5CX5w18WPQ7E7vXVlloOokWii3VzmA/qACJ9lMQVIZM24emA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0PR18MB4107 X-Proofpoint-ORIG-GUID: qcnE5uTqmzm03Iw2jxCy96REWTMikkrJ X-Proofpoint-GUID: qcnE5uTqmzm03Iw2jxCy96REWTMikkrJ X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.254,Aquarius:18.0.942,Hydra:6.0.573,FMLib:17.11.170.22 definitions=2023-04-12_02,2023-04-11_02,2023-02-09_01 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 > -----Original Message----- > From: Stephen Hemminger > Sent: 28 March 2023 21:22 > To: Srikanth Yalavarthi > Cc: Anup Prabhu ; dev@dpdk.org; Shivah Shankar > Shankar Narayan Rao ; Prince Takkar > ; Srikanth Yalavarthi > Subject: [EXT] Re: [PATCH 1/1] app/mldev: add internal function for file = read >=20 > External Email >=20 > ---------------------------------------------------------------------- > On Thu, 23 Mar 2023 08:28:01 -0700 > Srikanth Yalavarthi wrote: >=20 > > + if (fseek(fp, 0, SEEK_END) =3D=3D 0) { > > + file_size =3D ftell(fp); > > + if (file_size =3D=3D -1) { > > + ret =3D -EIO; > > + goto error; > > + } > > + > > + file_buffer =3D rte_malloc(NULL, file_size, > RTE_CACHE_LINE_SIZE); > > + if (file_buffer =3D=3D NULL) { > > + ml_err("Failed to allocate memory: %s\n", file); > > + ret =3D -ENOMEM; > > + goto error; > > + } > > + > > + if (fseek(fp, 0, SEEK_SET) !=3D 0) { > > + ret =3D -EIO; > > + goto error; > > + } > > + > > + if (fread(file_buffer, sizeof(char), file_size, fp) !=3D (unsigned > long)file_size) { > > + ml_err("Failed to read file : %s\n", file); > > + ret =3D -EIO; > > + goto error; > > + } > > + fclose(fp); > > + } else { > > + ret =3D -EIO; > > + goto error; > > + } > > + > > + *buffer =3D file_buffer; > > + *size =3D file_size; > > + > > + return 0; >=20 > Granted this only test code, but is the slowest way to do this. > Stdio is buffered (in 4K chunks). And using rte_malloc comes from > hugepages. >=20 > Three levels of improvement are possible: > 1. don't use rte_malloc() use malloc() instead. Agree on this. Will update in next version. > 2. use direct system call for I/O > 3. use mmap() to directly map in the file instead read Agree on the improvements. But, considering that this is a test code and these operations are done in = slow-path, I would prefer to have the implementation based on C library cal= ls rather than using system calls. Also, using system calls may not make this code portable? Though we are not= supporting this app on platforms other than Linux, as of now. Pls let me know what you think.