Re: [PATCH] RUSAGE_THREAD

2010-05-06 Thread Bruce Evans
On Thu, 6 May 2010, Kostik Belousov wrote: On Thu, May 06, 2010 at 04:42:39PM +0400, Alexander Krizhanovsky wrote: ... Indeed, I concerned more about PROC_LOCK/PROC_SLOCK - they are acquired both in kern_getrusage() and could be a problem in multithreaded process with intensive performance acco

Re: [PATCH] RUSAGE_THREAD

2010-05-06 Thread Kostik Belousov
On Thu, May 06, 2010 at 04:42:39PM +0400, Alexander Krizhanovsky wrote: > On 05/05/10 01:24, Kostik Belousov wrote: > > On Wed, May 05, 2010 at 12:48:53AM +, Alexander Krizhanovsky wrote: > > > >> Konstantin, > >> > >> Concerning i/o counters we collect them in rucollect() in for loop and >

Re: [PATCH] RUSAGE_THREAD

2010-05-06 Thread Alexander Krizhanovsky
On 05/05/10 01:24, Kostik Belousov wrote: > On Wed, May 05, 2010 at 12:48:53AM +, Alexander Krizhanovsky wrote: > >> Konstantin, >> >> Concerning i/o counters we collect them in rucollect() in for loop and >> update in various places, for example in vfs_bio.c. Rusage of an exiting >> threa

Re: [PATCH] RUSAGE_THREAD

2010-05-04 Thread Kostik Belousov
On Wed, May 05, 2010 at 12:48:53AM +, Alexander Krizhanovsky wrote: > Konstantin, > > Concerning i/o counters we collect them in rucollect() in for loop and > update in various places, for example in vfs_bio.c. Rusage of an exiting > threads is handled in exit1() -> ruadd(). > > Your versio

Re: [PATCH] RUSAGE_THREAD

2010-05-04 Thread Alexander Krizhanovsky
Konstantin, Concerning i/o counters we collect them in rucollect() in for loop and update in various places, for example in vfs_bio.c. Rusage of an exiting threads is handled in exit1() -> ruadd(). Your version of the patch certainly is more robust, however I'm still concerning about followi

Re: [PATCH] RUSAGE_THREAD

2010-05-03 Thread Kostik Belousov
On Mon, May 03, 2010 at 08:13:00PM +, Alexander Krizhanovsky wrote: > Kostik, > > thank you very much for the review! > > Kostik Belousov wrote: > >On Mon, Apr 19, 2010 at 12:46:48AM +, Alexander Krizhanovsky wrote: > > > >>Hi all! > >> > >>This patch implements per-thread rusage statis

Re: [PATCH] RUSAGE_THREAD

2010-05-03 Thread Alexander Krizhanovsky
Kostik, thank you very much for the review! Kostik Belousov wrote: On Mon, Apr 19, 2010 at 12:46:48AM +, Alexander Krizhanovsky wrote: Hi all! This patch implements per-thread rusage statistic (like RUSAGE_THREAD in Linux and RUSAGE_LWP in OpenSolaris). Unfortunately, we have to acq

Re: [PATCH] RUSAGE_THREAD

2010-04-25 Thread Kostik Belousov
On Mon, Apr 19, 2010 at 12:46:48AM +, Alexander Krizhanovsky wrote: > Hi all! > > This patch implements per-thread rusage statistic (like RUSAGE_THREAD in > Linux and RUSAGE_LWP in OpenSolaris). > > Unfortunately, we have to acquire a number of locks to read/update > system and user times f

[PATCH] RUSAGE_THREAD

2010-04-18 Thread Alexander Krizhanovsky
Hi all! This patch implements per-thread rusage statistic (like RUSAGE_THREAD in Linux and RUSAGE_LWP in OpenSolaris). Unfortunately, we have to acquire a number of locks to read/update system and user times for current thread rusage information because it's also used for whole process stati