From owner-svn-src-head@freebsd.org Mon Apr 2 21:38:23 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id C31BDF86EFE; Mon, 2 Apr 2018 21:38:23 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (glebi.us [96.95.210.25]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "cell.glebi.us", Issuer "cell.glebi.us" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id D271A73854; Mon, 2 Apr 2018 21:38:22 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.glebi.us (localhost [127.0.0.1]) by cell.glebi.us (8.15.2/8.15.2) with ESMTPS id w32La4S6046487 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 2 Apr 2018 14:36:04 -0700 (PDT) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.glebi.us (8.15.2/8.15.2/Submit) id w32La4uN046486; Mon, 2 Apr 2018 14:36:04 -0700 (PDT) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.glebi.us: glebius set sender to glebius@FreeBSD.org using -f Date: Mon, 2 Apr 2018 14:36:04 -0700 From: Gleb Smirnoff To: Alexander Motin Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r331414 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys Message-ID: <20180402213604.GC1917@FreeBSD.org> References: <201803230250.w2N2odbi085924@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201803230250.w2N2odbi085924@repo.freebsd.org> User-Agent: Mutt/1.9.3 (2018-01-21) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Apr 2018 21:38:23 -0000 Alexander, Does it make sense to leave the manual padding at all, if you got compiler hint __aligned(CACHE_LINE_SIZE)? With manual padding can get broken again later. On Fri, Mar 23, 2018 at 02:50:39AM +0000, Alexander Motin wrote: A> Author: mav A> Date: Fri Mar 23 02:50:38 2018 A> New Revision: 331414 A> URL: https://svnweb.freebsd.org/changeset/base/331414 A> A> Log: A> Reduce struct aggsum_bucket padding to fit into one cache line. A> A> Reported by: mjg A> A> Modified: A> head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/aggsum.h A> A> Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/aggsum.h A> ============================================================================== A> --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/aggsum.h Fri Mar 23 02:45:09 2018 (r331413) A> +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/sys/aggsum.h Fri Mar 23 02:50:38 2018 (r331414) A> @@ -29,7 +29,7 @@ typedef struct aggsum_bucket { A> kmutex_t asc_lock; A> int64_t asc_delta; A> uint64_t asc_borrowed; A> - uint64_t asc_pad[4]; /* pad out to cache line (64 bytes) */ A> + uint64_t asc_pad[2]; /* pad out to cache line (64 bytes) */ A> } aggsum_bucket_t __aligned(CACHE_LINE_SIZE); A> A> /* A> -- Gleb Smirnoff