From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail138.messagelabs.com (mail138.messagelabs.com [216.82.249.35]) by kanga.kvack.org (Postfix) with ESMTP id 3746D6B01F3 for ; Fri, 2 Apr 2010 15:04:38 -0400 (EDT) Received: from wpaz37.hot.corp.google.com (wpaz37.hot.corp.google.com [172.24.198.101]) by smtp-out.google.com with ESMTP id o32J4WC6004260 for ; Fri, 2 Apr 2010 12:04:32 -0700 Received: from pwi1 (pwi1.prod.google.com [10.241.219.1]) by wpaz37.hot.corp.google.com with ESMTP id o32J4VbL009075 for ; Fri, 2 Apr 2010 12:04:31 -0700 Received: by pwi1 with SMTP id 1so1801396pwi.39 for ; Fri, 02 Apr 2010 12:04:31 -0700 (PDT) Date: Fri, 2 Apr 2010 12:04:28 -0700 (PDT) From: David Rientjes Subject: Re: [PATCH -mm 4/4] oom: oom_forkbomb_penalty: move thread_group_cputime() out of task_lock() In-Reply-To: <20100402183309.GE31723@redhat.com> Message-ID: References: <20100330154659.GA12416@redhat.com> <20100331175836.GA11635@redhat.com> <20100331204718.GD11635@redhat.com> <20100401135927.GA12460@redhat.com> <20100402111406.GA4432@redhat.com> <20100402183057.GA31723@redhat.com> <20100402183309.GE31723@redhat.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-linux-mm@kvack.org To: Oleg Nesterov Cc: Andrew Morton , anfei , KOSAKI Motohiro , nishimura@mxp.nes.nec.co.jp, KAMEZAWA Hiroyuki , Mel Gorman , linux-mm@kvack.org, linux-kernel@vger.kernel.org List-ID: On Fri, 2 Apr 2010, Oleg Nesterov wrote: > It doesn't make sense to call thread_group_cputime() under task_lock(), > we can drop this lock right after we read get_mm_rss() and save the > value in the local variable. > > Note: probably it makes more sense to use sum_exec_runtime instead > of utime + stime, it is much more precise. A task can eat a lot of > CPU time, but its Xtime can be zero. > > Signed-off-by: Oleg Nesterov Acked-by: David Rientjes -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org