Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 03 Oct 2000 11:24:57 -0700 (PDT)
From:      John Baldwin <jhb@FreeBSD.org>
To:        Zhiui Zhang <zzhang@cs.binghamton.edu>
Cc:        freebsd-hackers@FreeBSD.org
Subject:   RE: process scheduling quantum
Message-ID:  <XFMail.001003112457.jhb@FreeBSD.org>
In-Reply-To: <Pine.SOL.4.21.0010031017410.16764-100000@jade>

next in thread | previous in thread | raw e-mail | index | archive | help

On 03-Oct-00 Zhiui Zhang wrote:
> 
> On Tue, 3 Oct 2000, John Baldwin wrote:
>> 
>> On 02-Oct-00 Zhiui Zhang wrote:
>> > 
>> > Suppose a process is scheduled to run, will it run until its quantum ends
>> > unless it calls tsleep() on his own? In other words, is it possible for a
>> > process to give up its quantum earlier without having it to do so 
>> > voluntarily? Thanks.
>> 
>> If an interrupt occurs and puts a thread on the run queue (which will have
>> higher priority than the currently running proceess) then the current
>> process will be stopped so that the interrupt thread can run.
> 
> Thanks. But I guess that you are talking about the new SMP threads.  For
> FreeBSD 4.1-Release, I am not sure this can happen. I am wondering any
> time taken by interrupts (hardware or software) will be accounted to the
> current process. If so, the process's quantum is stolen away and nothing
> useful for that process is done.

Yes, in pre-SMPng, interrupts use up part of the current process's quantum.

-- 

John Baldwin <jhb@FreeBSD.org> -- http://www.FreeBSD.org/~jhb/
PGP Key: http://www.baldwin.cx/~john/pgpkey.asc
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?XFMail.001003112457.jhb>