"niced" processes on leopard

Toby Peterson toby at macports.org
Fri Sep 11 11:29:23 PDT 2009


On Fri, Sep 11, 2009 at 06:25, Daniel J. Luke <dluke at geeklair.net> wrote:
> On Sep 11, 2009, at 8:47 AM, Yen, Wenchieh wrote:
>>
>> By creating 2 'yes > /dev/null' and one 'nice -n 19 yes > /dev/null' on
>> my core2duo, I would expect to see 2 cpus get near 100% load while one
>> get supressed due to a lower priority.
>>
>> What I got was quite equally distributed cpu cycles to these 3 (though
>> the niced one seemed to have a slightly lower load). I checked it with
>> 'top' or 'Activity Monitor'.
>>
>> In the mean time I checked the niced one with 'ps'. The STAT column
>> showed 'RN+' -- implying it was niced.
>
>
> You can file a bug with Apple if you want to see something like a 'scavenge
> class' for nice (or some way to mark a process so it only gets 'idle' or
> otherwise unused CPU cycles)... maybe it will eventually be implemented.
>
> I don't have 10.6 yet, so I don't know how different it is (or seems to be),
> but you haven't been able to nice things to work that way on any release of
> Mac OS X (going back prior to 10.0, even).

How many OSes even support this? Nice'ing a process just lowers its
scheduling priority... obviously, it will still get scheduled.

- Toby


More information about the macports-dev mailing list