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 0EF2D43EF7; Wed, 24 Apr 2024 12:22:01 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 876A5400D6; Wed, 24 Apr 2024 12:22:00 +0200 (CEST) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2071.outbound.protection.outlook.com [40.107.220.71]) by mails.dpdk.org (Postfix) with ESMTP id F40D140042 for ; Wed, 24 Apr 2024 12:21:58 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hcN+3oICsG9UdM/vHGRdi2zB/rjbrOQHViovQi7io5gyiFra2CqQFnn3HGyGlMrWoQUz4moVKp06XDtWvc/bLGsotm4ZJiOux7ug6T74IUZTh4uLTK9LN5Bg87v+2l0s1mMS8hjqJma+0PBWFc4XKi7k6OAL0lUBycvMWjurt/tZggoTmQuV5Mauv2KTxKuez4e/x50XJ/5l6fp8j6+a6P9GaP3+X9OmrQSPgk+k1mgbG/AnzDw5+9D9PgEEJyeHwU5LrMjw2ImHjQ/jgGLRYU2pRLtbW4V1EHVLgzStiScRl3BcsZamaWh//3IevphRFFkwgKF0VeT1NFN7/b7C8Q== 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=wWaCmrkd0dGOwQM+G92/yuccrmbfYx9uALaqgqVsu4s=; b=QpaXu1nKR/tRvovV6WrXi9ofuXUlozpeei5R76MFmd3AFHhglrrE5OJz1RNkGUMUiljfLiFMpnayQ9taC/FhGBm4RbjQOHUBbXFmcUCHwQ1KU1bc3QLd/z0P/vcBU1pPe58ZoPrudTVzT8jcOdLPM4tMQjJFvL5I0T/NYx5iEXmN8hX7MYi5gaG2WvuBJeTp2s3kHbKhoQ5ypKcn3S1P9FoocxFgKq4Em0jS3x/pMZHIUKgT0aWKN459BkqgtQ48FE31vYpl8kJDG4AGupe+hiN+SOworAWOiOrIbvUf6E88H/aZPO6E2I32HJNgnMPHBwpDtrytN+soGXnicm7IqQ== 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=wWaCmrkd0dGOwQM+G92/yuccrmbfYx9uALaqgqVsu4s=; b=rW4TPQvSerJn6iQS7HXjDlQQFLrPlFCqKPZOHvyFux1SYDslYrHa4/OiGRmt3YeCkhjLDH252EnWEGT2KAT1Vipe0d6TA1QQ7aDtHuvS3e35IICFLgETPSVzcAy4O57yETvAZliZy01jy0mixoGjyROuc0jTmqpr659jv7zNqwQ= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) by PH7PR12MB5805.namprd12.prod.outlook.com (2603:10b6:510:1d1::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7472.44; Wed, 24 Apr 2024 10:21:56 +0000 Received: from CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::282f:29d3:cac1:cde3]) by CH2PR12MB4294.namprd12.prod.outlook.com ([fe80::282f:29d3:cac1:cde3%7]) with mapi id 15.20.7472.044; Wed, 24 Apr 2024 10:21:56 +0000 Message-ID: <5d2a0887-527a-4948-943c-65f1dfda9328@amd.com> Date: Wed, 24 Apr 2024 11:21:52 +0100 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] net/af_packet: cache align Rx/Tx structs To: =?UTF-8?Q?Mattias_R=C3=B6nnblom?= , =?UTF-8?Q?Mattias_R=C3=B6nnblom?= , "John W . Linville" Cc: dev@dpdk.org, Tyler Retzlaff , Honnappa Nagarahalli References: <20240423090813.94110-1-mattias.ronnblom@ericsson.com> <6f7aabcb-2c12-4cfe-ae9d-73b42bfd4977@amd.com> <63dbb564-61f6-4d9f-9c13-4a21f5e97dc9@lysator.liu.se> Content-Language: en-US From: Ferruh Yigit Autocrypt: addr=ferruh.yigit@amd.com; keydata= xsFNBGJDD3EBEAC/M7Tk/DfQSmP1K96vyzdhfSBzlCaGtcxNXorq4fALruqVsD3oi0yfyEz9 4YN8x7py0o9EL8ZdpOX0skc0AMCDAaw033uWhCn0GLMeGRKUbfOAPvL6ecSDvGD7CJIO9j0J eZUvasBgPdM/435PEr9DmC6Ggzdzt8IuG4PoLi5jpFSfcqxZFCCxLUDEo/w0nuguk2FTuYJg B2zEZ4JTBZrw7hIHiFh8D8hr6YA6a5uTofq1tr+l048lbtdFUl8TR0aIExVzE4Z8qKZlcE+9 RQaewjK5Al1jLE4sHdmd3GN+IvgDF3D/fLsi25SKJDeGSdeHkOmaX0qGeM4WKIfU6iARRCiQ N3AmBIxZ/A7UXBKLaOyZ+/i3sE6Wb53nrO4i8+0K2Qwyh6LjTeiJAIjYKN43ppxz3DaI+QwQ vI+uyHr4Gg0Da9EPPz/YyKauSeOZCfCB5gIfICO0j6x0SCl8uQ2nLpjxcZkf0gjcwUzP3h+S 3x6NfDji9YEij0zczW/dcSpGgZ6vsFpPrtnP9ZXy6J53yp0kJtOJoOlkEFFdU2yCZnCDseum CoudmGLZVvS0/DzHDJejq+3kK3FDGktZBOxZIIpal+nFqS7lVgOZc4+huVv3jyhzoAUOEyXA XK5j6o7g8STUY+z33QNnHpdLvecMwuzmvqy0jR54yAbZ64mB9QARAQABzSNGZXJydWggWWln aXQgPGZlc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/2qVe cMh1CLUHXF1GlofpGbe1lj4KUJVse5g3qwV7i9VrseA8c4VIZewdIjkzAhmmbxl+8rM/LKBH dZUMTzME5PFCXJIZ83qkZQ795MTe2YScp9dIV7fsS5tpDwIs7BZNVM1l3NAdK+DLHqNxKuyO 8Zk= In-Reply-To: <63dbb564-61f6-4d9f-9c13-4a21f5e97dc9@lysator.liu.se> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-ClientProxiedBy: DB7PR05CA0024.eurprd05.prod.outlook.com (2603:10a6:10:36::37) To CH2PR12MB4294.namprd12.prod.outlook.com (2603:10b6:610:a9::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH2PR12MB4294:EE_|PH7PR12MB5805:EE_ X-MS-Office365-Filtering-Correlation-Id: 7a95ff8f-cd41-47af-7bec-08dc64485df7 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: =?utf-8?B?U1pCWHphQkNsaC9qblZlY2FYQjNxK1BBV05nTjdxWS9QejZKdXNrR2hXakFG?= =?utf-8?B?WnlZU0VJRUlIYldJN0QzRlZFTXhsUTN0bllTb0pyYXJVRE9SODduTi9ReGdZ?= =?utf-8?B?a2g4ODhUVUp5SVdJMmg5M2d2WHNGcjVPQzBiM1ExRXE2Z0Q0eGpDeWs5VDNs?= =?utf-8?B?YnVOU1dyczh3ZVE5aE4xNS9nT3dvVGlDazRDaUJhK1VlcGJkV0hzME5FbC8r?= =?utf-8?B?Q0diM0F6R3NSS2ZVbkMrQlE3Q25DV1Y1QVhGSCtjak9zU25SS0NYSzdRLzVC?= =?utf-8?B?K1M2eEYyaFJRNUU4YzBxN3JnSzllblNDdXdtTWNuNDk5MVJsZnNWZCtteXR6?= =?utf-8?B?RHAyMjdYTWhvL251QTdUREI5Vmd5RWErcW10K3kvYnFQQUtaK0NjYlltdEdY?= =?utf-8?B?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?B?Y1JqUFo3Qkx4ZWdIbVY1L3Q0dmhkbmNmSlc0MUh0azZsRjFCempqOVhGbHZx?= =?utf-8?B?ek9xTG1TNG85ZytmU2taWG5FRk1EUzRwMUZuR1YzaG56RzFKeDVZL3A4dWR6?= =?utf-8?B?WFphenJKVXdqbCsxZ0lrblpwZXkrcXhwUkdIOFFiWnU3RUNJY3Y5ZzBGV1J2?= =?utf-8?B?RENPWGI5K2xMc0N1UFlFUVVJcUdVMFFiRkJ4TGMrWmdYNnZ5UXAyYWR2U2cv?= =?utf-8?B?QTVDZUFMWWEzM3FYd0gvc1ZhS0hGeUVneHdNNjF4N1hGRTRBM0M2SkErcTJ0?= =?utf-8?B?L0xoQnI4RDA0dkJWWU9LaTZGWHZvK0FQQXBOWmJqdWR5ZUVZcmxwcG1mUTh3?= =?utf-8?B?SnZpYy8vd21QUjhnU0JUVit4WUxUSlFFb0F5akxoN2JJYzdMMnAwRmZRPT0=?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CH2PR12MB4294.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(366007)(376005)(1800799015); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?WWZCNUhMQUx2cW9qRlhPaVlhcVJEVGVNNFNNa2x3bFQ0YTdLZEMvcWdnS1Z2?= =?utf-8?B?TUMzbHg3cmkyQUZmT21MdjQrUHpvemFKRHphRkxEL1VIemFLNVpCaFlCRmNI?= =?utf-8?B?MTc5NStsamFMNXBURVljd095aXV0RnNpQ0ZRcmhuNDdBY24rdkh0RncxaS9h?= =?utf-8?B?TDcyZ0dGQTdRa0NDV1RyclBnTTFncjNDNHZXVUZmTnZub1cxREU3OW01Rm9n?= =?utf-8?B?bk1ISHk4dVNGTm41RjVxSkQ3eGpYVGh4VHR5SThvYUdHSm1iVWhTVk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MUFnT3Qxc1BEYmcyd3lqOFJkdG9GNVdSMkdZOUVQ?= =?utf-8?Q?9UFxJReFWZ7vtkMhePVJSBr8q?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 7a95ff8f-cd41-47af-7bec-08dc64485df7 X-MS-Exchange-CrossTenant-AuthSource: CH2PR12MB4294.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Apr 2024 10:21:55.9289 (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: boTnwpBkriwTeDbgP50UR/cK3upg5maQbu+5QkBQswAMjVRyrZrbUv2ZTyzPpK9E X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR12MB5805 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 4/23/2024 9:56 PM, Mattias Rönnblom wrote: > On 2024-04-23 13:15, Ferruh Yigit wrote: >> On 4/23/2024 10:08 AM, Mattias Rönnblom wrote: >>> Cache align Rx and Tx queue struct to avoid false sharing. >>> >>> RX struct happens to be 64 bytes on x86_64 already, so cache alignment >>> makes no change there, but it does on 32-bit ISAs. >>> >>> TX struct is 56 bytes on x86_64. >>> >> >> Hi Mattias, >> >> No objection to the patch. Is the improvement theoretical or do you >> measure any improvement practically, if so how much is the improvement? >> > > I didn't run any benchmarks. > > Two cores storing to a (falsely) shared cache line on a per-packet basis > is going to be very expensive, at least for "light touch" applications. > ack I expect for af_packet bottleneck is the kernel side, so I don't expect any visible improvement practically, but OK to fix this theoretical issue. >>> Both structs keep counters, and in the RX case they are updated even >>> for empty polls. >>> >> >> Do you think does it help if move 'rx_pkts' & 'rx_bytes' update within >> the loop? >> > > No, why? Wouldn't that be worse? Especially since rx_pkts and rx_bytes > are declared volatile, so you are forcing a load-modify-store cycle for > every increment. > My intention was to prevent updating stats in empty polls, I thought stats will be hot in the cache but won't work with volatile. > I would drop "volatile", or replace it with an atomic (although *not* > use an atomic add for incrementing, but rather atomic load + > non-atomic adds + atomic store). > As only single core polls from an Rx queue, I assume atomics is required only for stats reset case. And for that case won't we need atomic add? And do you know if there is a performance difference between atomic add and keeping volatile qualifier? >>> Signed-off-by: Mattias Rönnblom >>> --- >>>   drivers/net/af_packet/rte_eth_af_packet.c | 5 +++-- >>>   1 file changed, 3 insertions(+), 2 deletions(-) >>> >>> diff --git a/drivers/net/af_packet/rte_eth_af_packet.c >>> b/drivers/net/af_packet/rte_eth_af_packet.c >>> index 397a32db58..28aeb7d08e 100644 >>> --- a/drivers/net/af_packet/rte_eth_af_packet.c >>> +++ b/drivers/net/af_packet/rte_eth_af_packet.c >>> @@ -6,6 +6,7 @@ >>>    * All rights reserved. >>>    */ >>>   +#include >>>   #include >>>   #include >>>   #include >>> @@ -53,7 +54,7 @@ struct pkt_rx_queue { >>>         volatile unsigned long rx_pkts; >>>       volatile unsigned long rx_bytes; >>> -}; >>> +} __rte_cache_aligned; >>>   >> >> Latest location for '__rte_cache_aligned' tag is at the beginning of the >> struct [1], so something like: >> `struct __rte_cache_aligned pkt_rx_queue {` >> >> [1] >> https://patchwork.dpdk.org/project/dpdk/list/?series=31746&state=%2A&archive=both