Date: Sat, 1 Dec 2007 23:20:47 GMT From: Peter Wemm <peter@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 129915 for review Message-ID: <200712012320.lB1NKll0093058@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=129915 Change 129915 by peter@peter_daintree on 2007/12/01 23:20:40 compile fixes (catch up from reversion) Affected files ... .. //depot/projects/bike_sched/sys/kern/sched_4bsd.c#11 edit .. //depot/projects/bike_sched/sys/kern/sched_ule.c#10 edit Differences ... ==== //depot/projects/bike_sched/sys/kern/sched_4bsd.c#11 (text+ko) ==== @@ -611,21 +611,13 @@ * charge childs scheduling cpu usage to parent. */ void -sched_exit(struct proc *p, struct thread *td) +sched_exit(struct proc *p, struct thread *child) { + struct thread *td; CTR3(KTR_SCHED, "sched_exit: %p(%s) prio %d", - td, td->td_name, td->td_priority); - PROC_SLOCK_ASSERT(p, MA_OWNED); - sched_exit_thread(FIRST_THREAD_IN_PROC(p), td); -} - -void -sched_exit_thread(struct thread *td, struct thread *child) -{ - - CTR3(KTR_SCHED, "sched_exit_thread: %p(%s) prio %d", child, child->td_name, child->td_priority); + td = FIRST_THREAD_IN_PROC(p); thread_lock(td); td->td_estcpu = ESTCPULIM(td->td_estcpu + child->td_estcpu); thread_unlock(td); ==== //depot/projects/bike_sched/sys/kern/sched_ule.c#10 (text+ko) ==== @@ -2070,32 +2070,20 @@ /* * Return some of the child's priority and interactivity to the parent. - */ -void -sched_exit(struct proc *p, struct thread *child) -{ - struct thread *td; - - CTR3(KTR_SCHED, "sched_exit: %p(%s) prio %d", - child, child->td_name, child->td_priority); - - PROC_SLOCK_ASSERT(p, MA_OWNED); - td = FIRST_THREAD_IN_PROC(p); - sched_exit_thread(td, child); -} - -/* + * * Penalize another thread for the time spent on this one. This helps to * worsen the priority and interactivity of processes which schedule batch * jobs such as make. This has little effect on the make process itself but * causes new processes spawned by it to receive worse scores immediately. */ void -sched_exit_thread(struct thread *td, struct thread *child) +sched_exit(struct proc *p, struct thread *child) { + struct thread *td; - CTR3(KTR_SCHED, "sched_exit_thread: %p(%s) prio %d", + CTR3(KTR_SCHED, "sched_exit: %p(%s) prio %d", child, child->td_name, child->td_priority); + td = FIRST_THREAD_IN_PROC(p); /* * Give the child's runtime to the parent without returning the @@ -2396,7 +2384,7 @@ /* * Remove a thread from a run-queue without running it. This is used * when we're stealing a thread from a remote queue. Otherwise all threads - * exit by calling sched_exit_thread() and sched_throw() themselves. + * exit by calling sched_exit() and sched_throw() themselves. */ void sched_rem(struct thread *td)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200712012320.lB1NKll0093058>