From owner-cvs-src@FreeBSD.ORG Wed Jun 23 01:58:32 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1308316A4CE; Wed, 23 Jun 2004 01:58:32 +0000 (GMT) Received: from rwcrmhc12.comcast.net (rwcrmhc12.comcast.net [216.148.227.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id EEC3243D48; Wed, 23 Jun 2004 01:58:31 +0000 (GMT) (envelope-from julian@elischer.org) Received: from interjet.elischer.org ([24.7.73.28]) by comcast.net (rwcrmhc12) with ESMTP id <20040623015814014001861ne>; Wed, 23 Jun 2004 01:58:14 +0000 Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id SAA60310; Tue, 22 Jun 2004 18:58:12 -0700 (PDT) Date: Tue, 22 Jun 2004 18:58:11 -0700 (PDT) From: Julian Elischer To: David Xu In-Reply-To: <40D8E168.4050007@freebsd.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: cvs-src@FreeBSD.org cc: src-committers@FreeBSD.org cc: Bruce Evans cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/kern kern_exit.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Jun 2004 01:58:32 -0000 On Wed, 23 Jun 2004, David Xu wrote: > Bruce Evans wrote: > >bde 2004-06-21 14:49:50 UTC > > > > FreeBSD src repository > > > > Modified files: > > sys/kern kern_exit.c > > Log: > > (1) Removed the bogus condition "p->p_pid != 1" on calling >sched_exit() > > from exit1(). sched_exit() must be called unconditionally from > >exit1(). > > It was called almost unconditionally because the only exits on > >system > > shutdown if at all. > > > > (2) Removed the comment that presumed to know what sched_exit() does. > > sched_exit() does different things for the ULE case. The call > >became > > essential when it started doing load average stuff, but its caller > > should not know that. > > But this change loses a semantic, in most time, init is waitting there > to recycle runnaway processes, those process were not created by init, > if you call sched_exit for init unconditionally, the runnaway process's > cpu usage are all merged into init, this is unfair for init, is there > any benifit to lower init's priority under load to slow down recycling > speed ? I don't think so. I think scheduler's sched_exit should be > fixed at same time to keep this semantic. exaclty.. Actually this doesn't CHANGE anything because "p->p_pid != 1 was ALWAYS TRUE. you are however correct.. sched_exit should not pass cpu-usage to init. That is a differnt change however and I will include it in my nsched patch I am building in p4. (have you been able to look at p4 yet?) julian > > David Xu > > >