From owner-freebsd-arch@FreeBSD.ORG Sun Jan 13 15:06:47 2013 Return-Path: Delivered-To: arch@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 709DECAA; Sun, 13 Jan 2013 15:06:47 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id F1C73909; Sun, 13 Jan 2013 15:06:46 +0000 (UTC) Received: from tom.home (kostik@localhost [127.0.0.1]) by kib.kiev.ua (8.14.6/8.14.6) with ESMTP id r0DF6XjZ050925; Sun, 13 Jan 2013 17:06:33 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.7.4 kib.kiev.ua r0DF6XjZ050925 Received: (from kostik@localhost) by tom.home (8.14.6/8.14.6/Submit) id r0DF6Xih050924; Sun, 13 Jan 2013 17:06:33 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Sun, 13 Jan 2013 17:06:33 +0200 From: Konstantin Belousov To: Ian Lepore Subject: Re: Fast sigblock (AKA rtld speedup) Message-ID: <20130113150633.GV2561@kib.kiev.ua> References: <20130107182235.GA65279@kib.kiev.ua> <50EBAA1F.9070303@freebsd.org> <20130112230435.GJ1410@funkthat.com> <1358088614.32417.23.camel@revolution.hippie.lan> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="xxgoS+Xwt19NyhFM" Content-Disposition: inline In-Reply-To: <1358088614.32417.23.camel@revolution.hippie.lan> User-Agent: Mutt/1.5.21 (2010-09-15) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on tom.home Cc: arch@freebsd.org, John-Mark Gurney , David Xu , toolchain@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 13 Jan 2013 15:06:47 -0000 --xxgoS+Xwt19NyhFM Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Jan 13, 2013 at 07:50:14AM -0700, Ian Lepore wrote: > On Sat, 2013-01-12 at 15:04 -0800, John-Mark Gurney wrote: > > David Xu wrote this message on Tue, Jan 08, 2013 at 13:09 +0800: > > > and can not be freed until process is exited, the page is doubly > > > mapped into in kernel and userland, accessing the shared data > > > in kernel has zero overhead though. > >=20 > > Don't forget that there are arches out there w/ VIVT caches which will > > probably eliminate most of the performance benifits if we have the same > > page mapped writable in two different virtual addresses.. > >=20 >=20 > Even worse than eliminate the benefits, since multiple mappings with one > writable disables caching on the whole page, there can be a big penalty > depending on what other data is nearby that suddenly becomes > uncacheable. I was initially very interested in the work to read system > clocks without a syscall until I realized it was going to suffer from > the same problem. Since only kernel writes to the shared page, it should be not a problem. At least there is a specific point where you can insert the neccessary cache flush commands. Also, I suspect that even for arms, the writes are executed from the same core, which could simplify things even more. --xxgoS+Xwt19NyhFM Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iQIcBAEBAgAGBQJQ8s14AAoJEJDCuSvBvK1BgsAP/3I1KlKAMW9MESzj+WJBnKXh 5mhjDWuogY6QN9Cyg03nOcNO5OBLsXBSDB/rWT6qy8zyWqcMpPQ5QJ2y6gktn24L 09Ex6lTUZ8Ej9zIVsLhvdBTUSasr4+GqOEWHFT/iR2WG0PJqmDUwAEOQGHuQ7tq/ 6bmFzlZvFq5UjiBpGOXrr8Ip1j7umbKdYQ5GwZqz2OAxFsQbXEYLPRBhuK5a5mfU Tmtn2iYTethep5ey5cgUj2DfzKxM6cM/YNow0bFefoMPwXZ4taGx1xv+wfcgEs/K RINT3ER7y0t0UtJQFZGBNmX+tTdGCC8v0nHIJI6s98iQu+Pb/Q87E3bXZ+KIoQsf jkP0ENSAIUOmeLs55pt/5REe/e0hXadLr8D43qHUrvCDdKHfJBTKo2ZMSutlDA9g G+9r7PVMIw9egY3V55/l1jZB3szqc8MG6d2I4WgNh3NFXlsL83RhnVwiBhcbXi8k Wn4RLE5/9TpfoBRP4nSOkPEh+rEqVu4GIhsFJSXZ7usiJlxcgnWGSCuMj3M31UKe Vixvqi7+jaHVAzjqpPythaxW/19e2HxX7ZE5ABAMVSqAjYC7BNbf0y7Nr+i765Qj 1wtz7UX19y38GNaHjVbAFYs2Hhm79rjHTqhlZ39u8XSFgTU1MFLPpMXMOgUdCQ7j iRKhKtEVaWRIjPREA7q9 =BbUz -----END PGP SIGNATURE----- --xxgoS+Xwt19NyhFM--