Messages in this thread | | | Subject | Re: sched_yield() on "SCHED_FIFO" | From | 須崎有康 Kuniyasu SUZAKI <> | Date | Fri, 30 Jul 1999 15:59:00 +0900 |
| |
Dear,
Thank you for your reply. However ...
The supposed action of my program depended on the Round Robin scheduling on 1 CPU. The program produced two processes and they would be executed alternately, because it yielded each other on 1 CPU. The main problem is one process monopolied a CPU even if it executed sched_yield().
On SMP two processes were executed at the same time and caused race condition. The action would not be forecasted.
>>From: NIIBE Yutaka <gniibe@chroot.org> >>Subject: sched_yield() on "SCHED_FIFO" >> >>Kuniyasu SUZAKI writes: >> > The process is executed by super user. I was thinking this process >> > could measure the time for context switch on the real time class >> > "SCHED_FIFO" and it was measured on kernel 2.0.36 and Solaris. But on >> > 2.2.5-15 the parent process didn't yield. >> >>Result of my environment (two CPU PII 266MHz x2). >> >># ./context >>Context swicth time 6 us from 11792 to 11793 >>Context swicth time 13 us from 11793 to 11792 >>Context swicth time 4 us from 11792 to 11792 >>Context swicth time 10 us from 11792 to 11792 >>Context swicth time 3 us from 11792 to 11793 >>Context swicth time 4 us from 11793 to 11792 >>Context swicth time 5 us from 11792 to 11793 >>Context swicth time 3 us from 11793 to 11792 >>Context swicth time 5 us from 11792 to 11793 >># cat /proc/version >>Linux version 2.2.10 (root@qwe) (gcc version egcs-2.91.66 19990314 (egcs-1.1.2 release)) #1 SMP Sat Jul 24 17:41:19 JST 1999 >># >> >>Sometimes it switch to other, sometimes not. >>-- >>Niibe Yutaka >>
------ suzaki
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |