[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: ITS#3950





On Thu, 5 Jan 2006, Kurt D. Zeilenga wrote:

At 08:05 PM 1/5/2006, Kurt D. Zeilenga wrote:
I suppose we could devise some kind of test that uses two processes, one that spins eating CPU cycles, and another that spawns one thread that does a yield, while the main thread does a computation. If the yield causes the entire process to lose the CPU, the main thread's computation will be impeded. But it may be better to just test $build_os for now.

For now, yes

Okay, I've committed a basic detection code for REPLACE_SCHED_YIELD as well as updated replacement code. Currently uses select(2), but can be switched to nanosleep(2).

I've only tested on FreeBSD4 where this is a no-op.
Now pushing to a Linux box for real testing.

nanosleep(2) should work on Solaris (at least 8, 9 and 10) as well.

--
Igor