From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f178.google.com (mail-wr0-f178.google.com [209.85.128.178]) by dpdk.org (Postfix) with ESMTP id 65014231E for ; Thu, 20 Jul 2017 10:52:51 +0200 (CEST) Received: by mail-wr0-f178.google.com with SMTP id 12so67974159wrb.1 for ; Thu, 20 Jul 2017 01:52:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/dJWgUewWDPbcuGb8WfdBeIJcIsexg/kwkU+7RVdUNc=; b=fkOhrmmZConiR7iVadrAcuZj4PQo+SGaKCgGokMh85T933xckwACABs5s9oji7U163 YPwXhfHJqSZ01z98ZVefw35EWg5aGWq+GnhFQW6Z+WKW8/zSvjxY47j3dKfN4rfhUsEU EQQkfttMNR+If3u+3D3MRgcjCE+9a4NW9SeaFDyGie2+ybX5bSTkkUr3GzkCr26ZyWI/ X/cGRyD0ltt+Q+6a4tKnURvoFddqOcX7ohhP5qNYlyUJsl3hiV+183H2tHCSKXMYuxcC /FpxFbLgXSNg2ENIlv4welOognAusMgktf3ouhKKuk8XG+P5KaCm42oTt+Y1uqKOS81w iUJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=/dJWgUewWDPbcuGb8WfdBeIJcIsexg/kwkU+7RVdUNc=; b=DeH88Du7RX4Zi2mPyu7W9KmNHgMqDe2Xk48hQEiDl0yz56t1IDXlyHQjkZf8T1A5EN ZgFw37LGI9B08bep0Sat/yjU7QKF7wV0OT+VaJPSu0YCrKJDRHCjDDNcw9MdQs5RDmUe pt8Yh2f6WIeHNxVcMdxXi7pq2Z4uyF6xA3cSdV40HJ/dkHqGI60gTOhmxmTkRTi6NB3d vocA8voXvI0fnXTZpbQq+rqf6oV/FiVahbm4RMCNfWND7Q/Jgv4S7GI6niI6Bx1k0smO D5pmWxqdcU4E8APHiZpIEpWBGpGEAabKMF43C3UxFZ5KSZ82qH2oFNpkpnw4oBn6NBLA OeaA== X-Gm-Message-State: AIVw112Ge20Qt/SoRCtdV1RAu7/cNPeBNOFYmU1PvT7TGAZfSj/+OwhS F67oN3La8h+YJlcl6hM= X-Received: by 10.223.152.3 with SMTP id v3mr6260550wrb.8.1500540770850; Thu, 20 Jul 2017 01:52:50 -0700 (PDT) Received: from platinum (2a01cb0c03c651000226b0fffeed02fc.ipv6.abo.wanadoo.fr. [2a01:cb0c:3c6:5100:226:b0ff:feed:2fc]) by smtp.gmail.com with ESMTPSA id t125sm1758587wmt.20.2017.07.20.01.52.50 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 20 Jul 2017 01:52:50 -0700 (PDT) Date: Thu, 20 Jul 2017 10:52:48 +0200 From: Olivier Matz To: dev@dpdk.org Cc: bruce.richardson@intel.com, konstantin.ananyev@intel.com, daniel.verkamp@intel.com Message-ID: <20170720105248.7f9b1ec1@platinum> In-Reply-To: <20170630142609.6180-1-olivier.matz@6wind.com> References: <20170630142609.6180-1-olivier.matz@6wind.com> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [RFC] ring: relax alignment constraint on ring structure X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Jul 2017 08:52:51 -0000 Hi, On Fri, 30 Jun 2017 16:26:09 +0200, Olivier Matz wrote: > The initial objective of > commit d9f0d3a1ffd4 ("ring: remove split cacheline build setting") > was to add an empty cache line betwee, the producer and consumer > data (on platform with cache line size = 64B), preventing from > having them on adjacent cache lines. > > Following discussion on the mailing list, it appears that this > also imposes an alignment constraint that is not required. > > This patch removes the extra alignment constraint and adds the > empty cache lines using padding fields in the structure. The > size of rte_ring structure and the offset of the fields remain > the same on platforms with cache line size = 64B: > > rte_ring = 384 > rte_ring.name = 0 > rte_ring.flags = 32 > rte_ring.memzone = 40 > rte_ring.size = 48 > rte_ring.mask = 52 > rte_ring.prod = 128 > rte_ring.cons = 256 > > But it has an impact on platform where cache line size is 128B: > > rte_ring = 384 -> 768 > rte_ring.name = 0 > rte_ring.flags = 32 > rte_ring.memzone = 40 > rte_ring.size = 48 > rte_ring.mask = 52 > rte_ring.prod = 128 -> 256 > rte_ring.cons = 256 -> 512 > > Link: http://dpdk.org/dev/patchwork/patch/25039/ > Suggested-by: Konstantin Ananyev > Signed-off-by: Olivier Matz > --- > > I'm sending this patch to throw the discussion again, but since it > breaks the ABI on platform with cache lines = 128B, I think we should > follow the usual ABI breakage process. > > If everybody agree, I'll send a notice and resend a similar patch after > 17.08. > If there is no comment, I'll send a deprecation notice in the coming days. Thanks, Olivier