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 C1FE043BE9; Tue, 27 Feb 2024 10:51:01 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AE5C74027D; Tue, 27 Feb 2024 10:51:01 +0100 (CET) Received: from NAM10-MW2-obe.outbound.protection.outlook.com (mail-mw2nam10on2087.outbound.protection.outlook.com [40.107.94.87]) by mails.dpdk.org (Postfix) with ESMTP id 552A340150; Tue, 27 Feb 2024 10:51:00 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YX8ygfZAg0Pv+CiqN9eqLaCJ0GxDFWIhFoOmRdBtCVi4T8WWkaLYY0ur1FCVxg45a+zNW/0c7Mu9LmRNF9qaXySdv3A3SUO+Uu970zgZtfYSJGN2pBcEw1e2IwflQo8q45Wy9CZJfqJOwHxVkOAtjKCAUjT5IZpCuBURQ8q8j7TSn5ipilY4wd21NWykZnk1tLIA6LZVShcYf+9AK7+j9KmmI3bJH/eeJnujwxZjk+QAXMWFkAMZDFIHzWHRrAcfo5vqgbRFCdkywzjU3ay3MS7Zo8yMc1zd66CMFMaPN49H1e0Eb5926O/aQmNUxNZN1LGYJZ7dAUPm0g4iQXvqPg== 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=hf0vpDpP6kPDUwyDa1HBfjxzqWh8m5YztO3uRw4lrjY=; b=RwBZSQLnyiyc0WvaCHtw3BYgHrrkGU1pcQMD9Z6hKVLM4KbVQjyC5Nm6U0RbreW6E9+9+Uw8gldAJYyjQw9cj8xusWfM1FftwCRcNR63Omdp7yGFaQ+ALzSVAvU8BBqI0MulxWt820rWB57HQDk3iQTSty8w1xQvV1twxwdvFgFmPhrenYaT+MLQ5+soHAjb6CLaMAc/Z0d/UUrB122AJs22tnaIu9LDSQKTIK0kPgEYo0V7L7Z7yyEi5G+lFiHfScuPiAoLbxg0Edd37Bq6TRzFw8gXbunErSP8MbATnUFWL1GLM8tLbTiD+0GHqT+XplYAlP6Y1MLAoSwqekWw6g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=hf0vpDpP6kPDUwyDa1HBfjxzqWh8m5YztO3uRw4lrjY=; b=ZIrUEC8v+M/snnJ/cxKdthrh6WeSRShjxTBmfE8JAy+s7ccY9saz9UTTBZ9iM9926XFZF5UkExLSE1dcMn4ukNRyroORKW5sQtal9J70zxBBMXfFdtiGgiRysr/4HDGNGoYd0SHoijQc9oGgu+Ugn68heDR/hw/GS3pmilHg90Y= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from PH7PR12MB8596.namprd12.prod.outlook.com (2603:10b6:510:1b7::6) by DS0PR12MB9398.namprd12.prod.outlook.com (2603:10b6:8:1b3::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7316.36; Tue, 27 Feb 2024 09:50:58 +0000 Received: from PH7PR12MB8596.namprd12.prod.outlook.com ([fe80::5f0d:af7:7f6b:9b9c]) by PH7PR12MB8596.namprd12.prod.outlook.com ([fe80::5f0d:af7:7f6b:9b9c%5]) with mapi id 15.20.7316.035; Tue, 27 Feb 2024 09:50:58 +0000 Message-ID: Date: Tue, 27 Feb 2024 15:20:50 +0530 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] app/dma-perf: add average latency per worker Content-Language: en-US To: fengchengwen , dev@dpdk.org, stable@dpdk.org, honest.jiang@foxmail.com, gmuthukrishn@marvell.com, ferruh.yigit@amd.com References: <20231219164021.858-1-vipin.varghese@amd.com> <9acefd53-f617-28c1-1d6b-21b137d336eb@huawei.com> From: "Varghese, Vipin" In-Reply-To: <9acefd53-f617-28c1-1d6b-21b137d336eb@huawei.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: PN2PR01CA0176.INDPRD01.PROD.OUTLOOK.COM (2603:1096:c01:26::31) To PH7PR12MB8596.namprd12.prod.outlook.com (2603:10b6:510:1b7::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PH7PR12MB8596:EE_|DS0PR12MB9398:EE_ X-MS-Office365-Filtering-Correlation-Id: 697c7f4d-3550-4c6e-1317-08dc37799912 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: m+fExNeF5q9+uw8xOtqjQywCqU+TG0Bwq9+LEUhPm/4SoxPPFjg4oTVhTqQKZjGlgnUZbqZozy7qXq09nWM3W9iHuObbHHV+FSoMG1IEAMB7izx5kuc+Q71KoV/tp1WvJLWuF4D6ajs5Dob4nL+HaKStpOgLj/P/DsPvxNbWy2b4u92Tu/+P7XEuS8HMPXViwkbAvsFk2Py7lVhcskwxyFos2c9R1YhIIOefELHJZTi2MmFcX0h2gSki5EiQpR1qDc6ZcQ1DHXU0jODsdFLX3TkUZKUsEfQRPtA3r9mqEW2tKErGREF0LkihjbRjsMvyCzN5NWWpsk8cu/kCBg+0jJDsZKIPs/M+j8Ru+ZdPqK21Uv8228ZmFlm74Pjh2ze3F4a1opbHpVL3HemYXDqczlaD/6NRFUjiin27fObNyQM1GaExNimJyk0yx/HftrMD7vmS+2BU5Pd1HPp1rlG63Z6xJpcZFX7yY0w6yE7+ulDJX3PELfUMSr4QpLdAvoLFKEV9kWXt1HeZJzSj17Y9/NPAIuV4P29tsHPXGg6hiML8Dpcc7qRXNlf130Kb/BvkFEGEifhfCrFNPbjIdc7+lMQ4S4T5wi1WKrK3YNcH34xr5RCYKrmZzB5kUmaXSDy1siId+lgK5j9H2coQF6Wr4G08JdjWHDBEpEpCxfktyOE= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH7PR12MB8596.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(230273577357003); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?NE9ubkpqWlJDQlVjL1RrVVFOSHBDN293cmlSYW55UGdxNXNIY0VYN3UvTEc2?= =?utf-8?B?aVVvTUFzMW85bitQZ2tZWUtSNFVqMVovTXRRVU16c2VnQ0EyaDE3QzJoc09D?= =?utf-8?B?QU1EQ2tQNUxIanNSRzVJUlNtSVVKKzNBU0loTmlTNUduTmwzMTUzSTE0YWNj?= =?utf-8?B?Zm5yVmc5WnlvTStCTHU0ZFhWbFVrb0JZQ3FNQklJUGNwbG41SkJRdllSWitj?= =?utf-8?B?NUZ0N2YreHhiMzFMM291OXJwVHRrTVhPcERYbUw4UnptUm9LemFpWnM1ZlZP?= =?utf-8?B?b0daMWJzRTFwQ29FaG9mY1l4QitsUGNQWmtqYVYzN0Q1MVRITiszMlFxUWtn?= =?utf-8?B?OXE0YkowdytIVmNIb0F4UEJLMHIxK0pER1BVR2Q5OVlUVHNJMkFTOG5jaGhm?= =?utf-8?B?ZzBaT29rcXhXODJWUlowY2tlc0Ivekk4NW5PYmNTeVVjYTZEZTJ5RG1QZW1a?= =?utf-8?B?eWx6R29ld0ZHSXR6YUZVMVFQWExJc2ZjVXd4NUZHQXhaRzZObjhIMG8vUWZT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WwrQVhDRVRxUCtM?= =?utf-8?B?Ym5kZzJ0UHBSUFdmSU9ZeGNIcnBKMXlRVUNHRzY2cUZwTWZRZENvMU9sVC9H?= =?utf-8?B?b3orODR0Q01sbTU4ZGpXZzFTYU90SXh3M0xNUnVZeWZkdzZkQTNqV2lCSU4v?= =?utf-8?B?TUNnVzkrT1BKRi9kQVJrYnVxUE9TQWFNZ1dPdVd6TlpPU2VYa2ZKNzFYS1Nm?= =?utf-8?B?QXQxa0crZXloWi9TRFZqRkRhOTBvMldhQmtsQndkYUQ3YjhPTklxZEVFR3VZ?= =?utf-8?B?Q2RIamJSbytFNHRHNEFtbk1Jejd6V3lwaDFSREVndHhKOGh2b3VROGtWKzdz?= =?utf-8?B?YU1KVG40ZDhhTHpNQ2c4RVVCbGtzUUcrd3pyYmFocHpZUyt0RTNNSjAwajlr?= =?utf-8?B?eWI1RG1VaDZhVUZ4K3hyOXJnWjY5c3dCU3Myb3JQaEY5MFFYa3pkUlhTa0xG?= =?utf-8?B?Q0JFTTRYcjhwZkwzcmFibFppWjV2V2g1c2gxMjhiaFBPMENFelVRK2oxaXZU?= =?utf-8?B?STBKZERnckR4ZUQ2SVZYRnNqN2o1em1UUTFDdjgyTElQc0ZxUTM4c2hpOTMz?= =?utf-8?B?eVlsdzh5eklQMWtDdEd0eWhLU2dlVmdVU0RVd1BlRXNOSHFSZ3I2SlR2dHBR?= =?utf-8?B?dm5zRzBaZGU0eTNBTzBtZGFuYTl3bHlROWI5Ry9QaDV4NTV1Qlk1Wk1QY2gv?= =?utf-8?Q?TKlk65Fncy2KucZILvg9vvd1g?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 697c7f4d-3550-4c6e-1317-08dc37799912 X-MS-Exchange-CrossTenant-AuthSource: PH7PR12MB8596.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Feb 2024 09:50:58.1460 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: g91lbbvg1vT3l0KJUDQRlGVeu+jXWWGHihOtWgEtNonP5UjkRIH0guX4ilb3U20sxB+J+5931bFoNW7MMopqGA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR12MB9398 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 On 2/23/2024 3:15 PM, fengchengwen wrote: > Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding. > > > Hi Vipin, > > On 2023/12/20 0:40, Vipin Varghese wrote: >> Modify the user display data with total average latency per worker. >> >> Signed-off-by: Vipin Varghese >> --- >> app/test-dma-perf/benchmark.c | 3 ++- >> 1 file changed, 2 insertions(+), 1 deletion(-) >> >> diff --git a/app/test-dma-perf/benchmark.c b/app/test-dma-perf/benchmark.c >> index 9b1f58c78c..8b6886af62 100644 >> --- a/app/test-dma-perf/benchmark.c >> +++ b/app/test-dma-perf/benchmark.c >> @@ -470,7 +470,8 @@ mem_copy_benchmark(struct test_configure *cfg, bool is_dma) >> bandwidth_total += bandwidth; >> avg_cycles_total += avg_cycles; >> } >> - printf("\nTotal Bandwidth: %.3lf Gbps, Total MOps: %.3lf\n", bandwidth_total, mops_total); >> + printf("\nAverage Cycles/op: %.2lf, Total Bandwidth: %.3lf Gbps, Total MOps: %.3lf\n", >> + (float) avg_cycles_total / nb_workers, bandwidth_total, mops_total); thanks for the suggestions, please find my observations below > Because this is total stats, suggest add Total prefix, e.g. "Total Average Cycles/op" I did not follow this, so please let me try to explain my understanding. For `n` operation we count the average cycles, then we add the cycles to form `total average cycles`; this is then divide by `n` operations. Making this per operation what is the average cycles taken for the round trip time. Hence `Total Average Cyeles/op` does not sound right, but `Average Cycles / op` does. > I think print format keep one-digit precision is enough. Also please modify CSV_TOTAL_LINE_FMT > make sure the csv also have same precision of Cycles/op. We have checked the CSV formatting a find 1. the precision for average cycle/op is 2 digits precision. 2. already the CVS format has average cycles/op integrated. Hence no change is required. > > Thanks > >> snprintf(output_str[MAX_WORKER_NB], MAX_OUTPUT_STR_LEN, CSV_TOTAL_LINE_FMT, >> cfg->scenario_id, nr_buf, memory * nb_workers, >> avg_cycles_total / nb_workers, bandwidth_total, mops_total); >>