From owner-freebsd-current@FreeBSD.ORG Sat Aug 25 11:33:37 2007 Return-Path: Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B0A5F16A419; Sat, 25 Aug 2007 11:33:37 +0000 (UTC) (envelope-from peterjeremy@optushome.com.au) Received: from turion.vk2pj.dyndns.org (c220-239-20-82.belrs4.nsw.optusnet.com.au [220.239.20.82]) by mx1.freebsd.org (Postfix) with ESMTP id 2858613C45B; Sat, 25 Aug 2007 11:33:34 +0000 (UTC) (envelope-from peterjeremy@optushome.com.au) Received: from turion.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1]) by turion.vk2pj.dyndns.org (8.14.1/8.14.1) with ESMTP id l7PBXXO3018389; Sat, 25 Aug 2007 21:33:33 +1000 (EST) (envelope-from peter@turion.vk2pj.dyndns.org) Received: (from peter@localhost) by turion.vk2pj.dyndns.org (8.14.1/8.14.1/Submit) id l7PBXXAB018388; Sat, 25 Aug 2007 21:33:33 +1000 (EST) (envelope-from peter) Date: Sat, 25 Aug 2007 21:33:33 +1000 From: Peter Jeremy To: Robert Watson Message-ID: <20070825113333.GA18197@turion.vk2pj.dyndns.org> References: <20070823101737.GA1161@turion.vk2pj.dyndns.org> <20070823162802.T2662@fledge.watson.org> <20070823192322.GQ1161@turion.vk2pj.dyndns.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="HcAYCG3uE/tztfnV" Content-Disposition: inline In-Reply-To: <20070823192322.GQ1161@turion.vk2pj.dyndns.org> X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc User-Agent: Mutt/1.5.16 (2007-06-09) Cc: freebsd-current@FreeBSD.org Subject: Re: idprio(1) broken in recent -current X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Aug 2007 11:33:37 -0000 --HcAYCG3uE/tztfnV Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2007-Aug-24 05:23:22 +1000, Peter Jeremy = wrote: >boinc_client is supposed to write a watchdog flag in a shared SysV SHM >block every second. The setiathome process regularly polls the SHM >and if it doesn't see the watchdog for 31 seconds, it will abort. >boinc_client basically sits in a loop and uses select() timeouts. >I wrote a program to monitor the SHM and it shows that SHM is not >being updated. > >It looks like the kernel isn't cleanly handling the situation where >there are multiple idprio processes. I will try some more experimenting >this evening. Sorry for the delay. The select() in boinc_client is not timing out and so isn't returning until the child process dies. When I 'nice' boinc_client, 'ps' shows is waiting in 'select' - which is what I would expect. When I 'idprio' it, 'ps' shows it remaining running, though it is non-responsive. The setiathome process is deliberately allowing context switches (by calling usleep() regularly). It looks like a recent scheduler change means that multiple idprio processes don't round-robin but instead re-schedules the previously running process. I'm running SCHED_4BSD. Pity I don't have dtrace... --=20 Peter Jeremy --HcAYCG3uE/tztfnV Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (FreeBSD) iD8DBQFG0BON/opHv/APuIcRAjQ8AJ9EcdKuleW7o8nXe1FD8rRRiuFYgQCfRcEf fwRQ6TfuYSdCvxR3v7pAkj0= =0GmH -----END PGP SIGNATURE----- --HcAYCG3uE/tztfnV--