From: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
To: rakib.mullick@gmail.com
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
akpm@linux-foundation.org, cl@linux.com,
kamezawa.hiroyu@jp.fujitsu.com, mel@csn.ul.ie
Subject: Re: [PATCH] mm, vmstat: Use cond_resched only when !CONFIG_PREEMPT
Date: Tue, 31 May 2011 11:23:21 +0900 [thread overview]
Message-ID: <4DE45119.9040108@jp.fujitsu.com> (raw)
In-Reply-To: <1306774744.4061.5.camel@localhost.localdomain>
> diff --git a/mm/vmstat.c b/mm/vmstat.c
> index 20c18b7..72cf857 100644
> --- a/mm/vmstat.c
> +++ b/mm/vmstat.c
> @@ -461,7 +461,11 @@ void refresh_cpu_vm_stats(int cpu)
> p->expire = 3;
> #endif
> }
> +
> +#ifndef CONFIG_PREEMPT
> cond_resched();
> +#endif
> +
In general, we should avoid #ifdef CONFIG_PREEMPT for maintainancebility as far as possible.
Is there any observable benefit? Can you please demonstrate it?
WARNING: multiple messages have this Message-ID (diff)
From: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
To: rakib.mullick@gmail.com
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
akpm@linux-foundation.org, cl@linux.com,
kamezawa.hiroyu@jp.fujitsu.com, mel@csn.ul.ie
Subject: Re: [PATCH] mm, vmstat: Use cond_resched only when !CONFIG_PREEMPT
Date: Tue, 31 May 2011 11:23:21 +0900 [thread overview]
Message-ID: <4DE45119.9040108@jp.fujitsu.com> (raw)
In-Reply-To: <1306774744.4061.5.camel@localhost.localdomain>
> diff --git a/mm/vmstat.c b/mm/vmstat.c
> index 20c18b7..72cf857 100644
> --- a/mm/vmstat.c
> +++ b/mm/vmstat.c
> @@ -461,7 +461,11 @@ void refresh_cpu_vm_stats(int cpu)
> p->expire = 3;
> #endif
> }
> +
> +#ifndef CONFIG_PREEMPT
> cond_resched();
> +#endif
> +
In general, we should avoid #ifdef CONFIG_PREEMPT for maintainancebility as far as possible.
Is there any observable benefit? Can you please demonstrate it?
--
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/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2011-05-31 2:23 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-30 16:59 [PATCH] mm, vmstat: Use cond_resched only when !CONFIG_PREEMPT Rakib Mullick
2011-05-30 16:59 ` Rakib Mullick
2011-05-30 23:38 ` KAMEZAWA Hiroyuki
2011-05-30 23:38 ` KAMEZAWA Hiroyuki
2011-05-31 3:13 ` Rakib Mullick
2011-05-31 3:13 ` Rakib Mullick
2011-05-31 3:18 ` KAMEZAWA Hiroyuki
2011-05-31 3:18 ` KAMEZAWA Hiroyuki
2011-05-31 3:58 ` Rakib Mullick
2011-05-31 3:58 ` Rakib Mullick
2011-05-31 4:29 ` KAMEZAWA Hiroyuki
2011-05-31 4:29 ` KAMEZAWA Hiroyuki
2011-05-31 2:23 ` KOSAKI Motohiro [this message]
2011-05-31 2:23 ` KOSAKI Motohiro
2011-05-31 3:19 ` Rakib Mullick
2011-05-31 3:19 ` Rakib Mullick
2011-05-31 5:55 ` Minchan Kim
2011-05-31 5:55 ` Minchan Kim
2011-05-31 5:57 ` Minchan Kim
2011-05-31 5:57 ` Minchan Kim
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4DE45119.9040108@jp.fujitsu.com \
--to=kosaki.motohiro@jp.fujitsu.com \
--cc=akpm@linux-foundation.org \
--cc=cl@linux.com \
--cc=kamezawa.hiroyu@jp.fujitsu.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mel@csn.ul.ie \
--cc=rakib.mullick@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.