lkml.org 
[lkml]   [2011]   [May]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRe: Very high CPU values in top on idle system (3.0-rc1)
FromPeter Zijlstra <>
DateTue, 31 May 2011 11:55:45 +0200
On Tue, 2011-05-31 at 00:12 +0200, Peter Zijlstra wrote:
>
> I poked around with some skip_rq_update bits but couldn't make it go
> away, will try more tomorrow.

Gah, that was annoying, and explains why I wasn't seeing it on my main
dev box but could see it on my desktop (wsm tsc is much better synced
than the core2 tsc).

Could you confirm that this indeed cures the problem? I'll probably
commit a version without the toggle, but that was easy for verifying it
indeed made a difference..

---
Index: linux-2.6/kernel/sched.c
===================================================================
--- linux-2.6.orig/kernel/sched.c
+++ linux-2.6/kernel/sched.c
@@ -2604,6 +2601,8 @@ static void ttwu_queue(struct task_struc

#if defined(CONFIG_SMP)
if (sched_feat(TTWU_QUEUE) && cpu != smp_processor_id()) {
+ if (sched_feat(TTWU_SYNC_CLOCK))
+ sched_clock_cpu(cpu); /* sync clocks x-cpu */
ttwu_queue_remote(p, cpu);
return;
}
Index: linux-2.6/kernel/sched_features.h
===================================================================
--- linux-2.6.orig/kernel/sched_features.h
+++ linux-2.6/kernel/sched_features.h
@@ -70,3 +70,4 @@ SCHED_FEAT(NONIRQ_POWER, 1)
* using the scheduler IPI. Reduces rq->lock contention/bounces.
*/
SCHED_FEAT(TTWU_QUEUE, 1)
+SCHED_FEAT(TTWU_SYNC_CLOCK, 1)


\
 
 \ /
  Last update: 2011-05-31 11:59    [from the cache]
©2003-2010