tech-userlevel archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: pthread_rwlock starvation
On Sat, 17 Apr 2010 12:19:42 +0100
Sad Clouds <cryintothebluesky%googlemail.com@localhost> wrote:
> I've attached a program that reproduces the issue. Run it a couple of
> times and watch top, or vmstat. Sooner or later one CPU will sit idle
> 100% for 10-30 seconds, until something nudges it back into work.
I wanted to test this as well, because in a multithreaded server I seem
to see similar occasional freezes of a few seconds where the CPU is
idle, as the server is flooded with requests from ab (apache benchmark
program). Although the code does use some mutexes they're not
read-write locks, and the user code uses less locks than the kernel (as
part of syscalls implementation) in this very case.
However, I seem unable to reproduce the problem on a uniprocessor
netbsd-5 (i686 optimized on 32-bit hardware) using the test case you
posted.
--
Matt
Home |
Main Index |
Thread Index |
Old Index