NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: lib/41019: pthreads: high load when using varnish (locking/unlocking causes 98% WCPU)

On Mar 22,  2:10pm, (Michael Stapelberg) 
-- Subject: Re: lib/41019: pthreads: high load when using varnish (locking/un

|  Hi,
|  I just wanted to inform you that this problem report can be closed as I was
|  wrong with the cause of the clock_gettime()-calls. They were, in fact, issued
|  by varnish.
|  They were issued so often because the return code of usleep() wasnâ??t 
|  and NetBSD does not handle values >= 1,000,000. See ticket #475 [1] in 
|  bugtracker.
|  So, sorry to have wasted your time and thanks for your help.
|  Best regards,
|  Michael
|  [1]

It is not a NetBSD issue:

And in your fix you are not using nanosleep because you claim it has
similar issues. I think it does not, so in reality the code should be
converted to use nanosleep(), or if you want to use something like your

#define U2S     1000000
        if (usec >= U2S) {
                unsigned int sec = usec / U2S;
                usec %= U2S;



Home | Main Index | Thread Index | Old Index