From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id CBC142B84 for ; Wed, 5 Apr 2017 17:56:56 +0200 (CEST) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga104.jf.intel.com with ESMTP; 05 Apr 2017 08:56:55 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.36,279,1486454400"; d="scan'208";a="842293659" Received: from bricha3-mobl3.ger.corp.intel.com ([10.237.221.140]) by FMSMGA003.fm.intel.com with SMTP; 05 Apr 2017 08:56:53 -0700 Received: by (sSMTP sendmail emulation); Wed, 05 Apr 2017 16:56:52 +0100 Date: Wed, 5 Apr 2017 16:56:52 +0100 From: Bruce Richardson To: Thomas Monjalon Cc: Ferruh Yigit , dev@dpdk.org Message-ID: <20170405155652.GA15156@bricha3-MOBL3.ger.corp.intel.com> References: <20170405150312.20960-1-ferruh.yigit@intel.com> <2101638.L2PhFsoQeI@xps13> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2101638.L2PhFsoQeI@xps13> Organization: Intel Research and =?iso-8859-1?Q?De=ACvel?= =?iso-8859-1?Q?opment?= Ireland Ltd. User-Agent: Mutt/1.8.0 (2017-02-23) Subject: Re: [dpdk-dev] [PATCH] ring: fix build with icc 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: Wed, 05 Apr 2017 15:56:57 -0000 On Wed, Apr 05, 2017 at 05:29:48PM +0200, Thomas Monjalon wrote: > 2017-04-05 16:03, Ferruh Yigit: > > build error: > > In file included from .../lib/librte_ring/rte_ring.c(90): > > .../lib/librte_ring/rte_ring.h(162): > > error #1366: a reduction in alignment without the "packed" attribute > > is ignored > > } __rte_cache_aligned; > > ^ > > > > Alignment attribute moved to first element of the struct > > The fix is surprising. > Is it really doing the same thing as > } __rte_cache_aligned; > at the end of the struct? > It should be. Aligning the whole structure to start on a cache-line boundary should be exactly the same as telling the compiler to put the first field of the structure on a cacheline boundary. /Bruce