From owner-freebsd-hackers@FreeBSD.ORG Fri Aug 6 11:13:00 2010 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9C7A01065677; Fri, 6 Aug 2010 11:13:00 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from mail.zoral.com.ua (mx0.zoral.com.ua [91.193.166.200]) by mx1.freebsd.org (Postfix) with ESMTP id 1A0E38FC1D; Fri, 6 Aug 2010 11:12:59 +0000 (UTC) Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by mail.zoral.com.ua (8.14.2/8.14.2) with ESMTP id o76BBVFQ013997 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 6 Aug 2010 14:11:31 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4) with ESMTP id o76BBViV053769; Fri, 6 Aug 2010 14:11:31 +0300 (EEST) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.4/8.14.4/Submit) id o76BBVwt053768; Fri, 6 Aug 2010 14:11:31 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Fri, 6 Aug 2010 14:11:31 +0300 From: Kostik Belousov To: Marius Strobl Message-ID: <20100806111131.GN22295@deviant.kiev.zoral.com.ua> References: <20100806050633.GK14016@felucia.tataz.chchile.org> <20100806090404.GI22295@deviant.kiev.zoral.com.ua> <20100806110807.GA68489@alchemy.franken.de> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="txKCGZfNyLhwRtdd" Content-Disposition: inline In-Reply-To: <20100806110807.GA68489@alchemy.franken.de> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: clamav-milter 0.95.2 at skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-2.2 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_50, DNS_FROM_OPENWHOIS autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on skuns.kiev.zoral.com.ua Cc: FreeBSD Hackers , Jeremie Le Hen , nwhitehorn@freebsd.org Subject: Re: Avoiding sysctl at program startup using ELF aux vector (was: concurrent sysctl implementation) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Aug 2010 11:13:00 -0000 --txKCGZfNyLhwRtdd Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Aug 06, 2010 at 01:08:08PM +0200, Marius Strobl wrote: > On Fri, Aug 06, 2010 at 12:04:04PM +0300, Kostik Belousov wrote: > > On Fri, Aug 06, 2010 at 07:06:33AM +0200, Jeremie Le Hen wrote: > > > Hi Kib, > > >=20 > > > In-Reply-To: <20100629083901.GG13238@deviant.kiev.zoral.com.ua> > > > On Tue, Jun 29, 2010 at 11:39:01AM +0300, Kostik Belousov wrote: > > > > On Tue, Jun 29, 2010 at 10:26:39AM +0200, Marius Strobl wrote: > > > > > On Mon, Jun 28, 2010 at 05:48:59PM +0300, Kostik Belousov wrote: > > > > > > On Wed, Jun 23, 2010 at 11:09:59PM +0200, Jeremie Le Hen wrote: > > > > > > > Hi Kostik, > > > > > > >=20 > > > > > > > This patch seems to have faded out from memory. Is it possib= le to go > > > > > > > forward and commit it? > > > > > > I refreshed the patch. Hopefully, nobody will object, and I com= mit it > > > > > > shortly. > > > > > >=20 > > > > > > >=20 > > > > > > > Thanks, > > > > > > > Regards. > > > > > > >=20 > > > > > > > On Sat, Jul 25, 2009 at 12:29:16AM +0300, Kostik Belousov wro= te: > > > > > > > > Below is the prototype that seems to work for me both with = patched and > > > > > > > > old rtld on i386. Patch also contains bits for amd64 that I= did not > > > > > > > > tested yet. All other arches are not buildable for now. > > > > > > > >=20 > > > > > > > > Patch completely eliminates sysctl syscalls from the rtld a= nd libc > > > > > > > > startup. Without the patch, a single run of /bin/ls did 6 s= ysctls, > > > > > > > > with the patch, no sysctls is queried at all. > > > > > > > >=20 > > > > > > Comparing with the originally posted patch, I added support for= all > > > > > > architectures, tested amd64 and ia32 on amd64, and converted ge= tpagesizes(3) > > > > > > that added two more startup sysctls. > > > > > >=20 > > > > > > Would be nice to get a testing for at least some !x86 architect= ures > > > > > > before the commit, I added some people who helped me in past, t= o the Cc:. > > > > > >=20 > > > > >=20 > > > > > Doesn't look good on sparc64: > > > > > <...> > > > > > NFS ROOT: 192.168.1.40:/usr/data/nfsroot/sparc64 > > > > > dc1: link state changed to UP > > > > > pid 24 (ifconfig), uid 0: exited on signal 11 > > > > > Segmentation fault > > > > > Interface IP-Address Broadcast > > > > > pid 29 (rcorder), uid 0: exited on signal 11 > > > > > Segmentation fault > > > > > pid 30 (grep), uid 0: exited on signal 11 > > > > > Segmentation fault > > > > > pid 31 (rcorder), uid 0: exited on signal 11 > > > > > Segmentation fault > > > > > =20 > > > > > pid 32 (date), uid 0: exited on signal 11 > > > > > Segmentation fault > > > > > Jun 29 12:20:50 getty[36]: open /dev/ttyv3: No such file or direc= tory > > > > > <...> > > > > >=20 > > > > > Unfortunately, I currently lack the time to debug this. > > > >=20 > > > > Thank you. > > >=20 > > > Did yu have time to look at this problem? It would be nice to have t= his > > > in the tree. > >=20 > > I cannot move forward without the help from somebody having access to > > sparc64 system where the problem is reproducable. >=20 > Do you have a debug version of the patch which outputs the necessary > information? I would suggest to build rtld and libc with debugging symbols and get full backtrace from the faults. --txKCGZfNyLhwRtdd Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (FreeBSD) iEYEARECAAYFAkxb7eIACgkQC3+MBN1Mb4i2jQCg01khz784JFRZt8ZOGIdK/rQN 6k4AoNhxTOrhteKhrIfCqz+CJgUh6P/l =XxKl -----END PGP SIGNATURE----- --txKCGZfNyLhwRtdd--