Re: [RFC/RFT] calloutng

From: Alexander Motin <mav_at_FreeBSD.org>
Date: Thu, 03 Jan 2013 18:12:17 +0200
On 03.01.2013 16:45, Bruce Evans wrote:
> On Wed, 2 Jan 2013, Alexander Motin wrote:
>> More important for scheduling fairness thread's CPU percentage is also
>> based on hardclock() and hiding from it was trivial before, since all
>> sleep primitives were strictly aligned to hardclock(). Now it is
>> slightly less trivial, since this alignment was removed and user-level
>> APIs provide no easy way to enforce it.
>
> %cpu is actually based on statclock(), and not even used for scheduling.

May be for SCHED_4BSD, but not for SCHED_ULE.  In SCHED_ULE both %cpu 
and thread priority based on the same ts_ticks counter, that is based on 
hardclock() as time source. Interactivity calculation uses alike logic 
and uses the same time source.

-- 
Alexander Motin
Received on Thu Jan 03 2013 - 15:12:26 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:33 UTC