Re: how to let all others run

2001-04-05 Thread Ion Badulescu
On Thu, 5 Apr 2001 12:52:28 -0400 (EDT), Richard B. Johnson <[EMAIL PROTECTED]> wrote: > Only an observation: > > > main() > { >nice(19); >for(;;) >sched_yield(); > } > > does... > [...] > > It consumes 99.1 percent CPU, just spinning. And, umm, what *exactly* would you

Re: how to let all others run

2001-04-05 Thread Richard B. Johnson
On Thu, 5 Apr 2001 [EMAIL PROTECTED] wrote: > > Doesn't even show on `top`. Further, it gets the CPU about 100 times > > a second (HZ). This is normally what you want for something that > > polls, buts needs to give up the CPU so that whatever it's waiting > > for can get done as soon as

Re: how to let all others run

2001-04-05 Thread Oliver.Neukum
> Doesn't even show on `top`. Further, it gets the CPU about 100 times > a second (HZ). This is normally what you want for something that > polls, buts needs to give up the CPU so that whatever it's waiting > for can get done as soon as possible. Hi, first of all I want to do this in kernel. I

Re: how to let all others run

2001-04-05 Thread Richard B. Johnson
On 5 Apr 2001, John Fremlin wrote: > "Richard B. Johnson" <[EMAIL PROTECTED]> writes: > > > On 4 Apr 2001, John Fremlin wrote: > > > > > > Hi Oliver! > > > > > > Oliver Neukum <[EMAIL PROTECTED]> writes: > > > > > > > is there a way to let all other runable tasks run until they block > > >

Re: how to let all others run

2001-04-05 Thread John Fremlin
"Richard B. Johnson" <[EMAIL PROTECTED]> writes: > On 4 Apr 2001, John Fremlin wrote: > > > > Hi Oliver! > > > > Oliver Neukum <[EMAIL PROTECTED]> writes: > > > > > is there a way to let all other runable tasks run until they block > > > or return to user space, before the task wishing to do

Re: how to let all others run

2001-04-05 Thread John Fremlin
"Richard B. Johnson" [EMAIL PROTECTED] writes: On 4 Apr 2001, John Fremlin wrote: Hi Oliver! Oliver Neukum [EMAIL PROTECTED] writes: is there a way to let all other runable tasks run until they block or return to user space, before the task wishing to do so is run again ?

Re: how to let all others run

2001-04-05 Thread Richard B. Johnson
On 5 Apr 2001, John Fremlin wrote: "Richard B. Johnson" [EMAIL PROTECTED] writes: On 4 Apr 2001, John Fremlin wrote: Hi Oliver! Oliver Neukum [EMAIL PROTECTED] writes: is there a way to let all other runable tasks run until they block or return to user space,

Re: how to let all others run

2001-04-05 Thread Oliver.Neukum
Doesn't even show on `top`. Further, it gets the CPU about 100 times a second (HZ). This is normally what you want for something that polls, buts needs to give up the CPU so that whatever it's waiting for can get done as soon as possible. Hi, first of all I want to do this in kernel. I need

Re: how to let all others run

2001-04-05 Thread Richard B. Johnson
On Thu, 5 Apr 2001 [EMAIL PROTECTED] wrote: Doesn't even show on `top`. Further, it gets the CPU about 100 times a second (HZ). This is normally what you want for something that polls, buts needs to give up the CPU so that whatever it's waiting for can get done as soon as possible.

Re: how to let all others run

2001-04-05 Thread Ion Badulescu
On Thu, 5 Apr 2001 12:52:28 -0400 (EDT), Richard B. Johnson [EMAIL PROTECTED] wrote: Only an observation: main() { nice(19); for(;;) sched_yield(); } does... [...] It consumes 99.1 percent CPU, just spinning. And, umm, what *exactly* would you expect it to do?

Re: how to let all others run

2001-04-04 Thread Richard B. Johnson
On 4 Apr 2001, John Fremlin wrote: > > Hi Oliver! > > Oliver Neukum <[EMAIL PROTECTED]> writes: > > > is there a way to let all other runable tasks run until they block > > or return to user space, before the task wishing to do so is run > > again ? > > Are you trying to do this in kernel

Re: how to let all others run

2001-04-04 Thread John Fremlin
Hi Oliver! Oliver Neukum <[EMAIL PROTECTED]> writes: > is there a way to let all other runable tasks run until they block > or return to user space, before the task wishing to do so is run > again ? Are you trying to do this in kernel or something? From userspace you can use nice(2) then

Re: how to let all others run

2001-04-04 Thread John Fremlin
Hi Oliver! Oliver Neukum [EMAIL PROTECTED] writes: is there a way to let all other runable tasks run until they block or return to user space, before the task wishing to do so is run again ? Are you trying to do this in kernel or something? From userspace you can use nice(2) then

Re: how to let all others run

2001-04-04 Thread Richard B. Johnson
On 4 Apr 2001, John Fremlin wrote: Hi Oliver! Oliver Neukum [EMAIL PROTECTED] writes: is there a way to let all other runable tasks run until they block or return to user space, before the task wishing to do so is run again ? Are you trying to do this in kernel or something?