public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v3 0/5] Tunable sched_mc_power_savings=n
@ 2008-11-10 18:32 Vaidyanathan Srinivasan
  2008-11-10 18:33 ` [RFC PATCH v3 1/5] sched: Framework for sched_mc/smt_power_savings=N Vaidyanathan Srinivasan
                   ` (5 more replies)
  0 siblings, 6 replies; 21+ messages in thread
From: Vaidyanathan Srinivasan @ 2008-11-10 18:32 UTC (permalink / raw)
  To: Linux Kernel, Suresh B Siddha, Venkatesh Pallipadi,
	Peter Zijlstra
  Cc: Ingo Molnar, Dipankar Sarma, Balbir Singh, Vatsa,
	Gautham R Shenoy, Andi Kleen, David Collier-Brown, Tim Connors,
	Max Krasnyansky, Vaidyanathan Srinivasan

Hi,

The existing power saving loadbalancer CONFIG_SCHED_MC attempts to run
the workload in the system on minimum number of CPU packages and tries
to keep rest of the CPU packages idle for longer duration. Thus
consolidating workloads to fewer packages help other packages to be in
idle state and save power.  The current implementation is very
conservative and does not work effectively across different workloads.
Initial idea of tunable sched_mc_power_savings=n was proposed to
enable tuning of the power saving load balancer based on the system
configuration, workload characteristics and end user requirements.

The power savings and performance of the given workload in an under
utilised system can be controlled by setting values of 0, 1 or 2 to
/sys/devices/system/cpu/sched_mc_power_savings with 0 being highest
performance and least power savings and level 2 indicating maximum
power savings even at the cost of slight performance degradation.

Please refer to the following discussions and article for details.

[1]Making power policy just work
http://lwn.net/Articles/287924/ 

[2][RFC v1] Tunable sched_mc_power_savings=n
http://lwn.net/Articles/287882/
                                                                                                               
[3][RFC PATCH v2 0/7] Tunable sched_mc_power_savings=n                                                                                                   
http://lwn.net/Articles/297306/

The following series of patch demonstrates the basic framework for
tunable sched_mc_power_savings.

This version of the patch incorporates comments and feedback received
on the previous post.  Thanks to Peter Zijlstra for the review and
comments.

Changes from v2:
----------------

* Fixed locking order issue in active-balance-new-idle
* Moved the wakeup biasing code to wake_idle() function and preserve
  wake_affine function.  Previous version would break wake_affine in
  order to aggressively consolidate tasks  
* Removed sched_mc_preferred_wakeup_cpu global variable and moved to
  doms_cur/dattr_cur and added a per_cpu pointer to appropriate
  storage in partitioned sched domain.  This changed is needed to
  preserve functionality in case of partitioned sched domains
* Patch on 2.6.28-rc3 kernel  

Notes:
------

* The patch has been tested on x86 with basic cpusets and kernbench.  
  Correct functionality in the case of partitioned sched domain need 
  to be analysed.

Results:
--------

Basic functionality of the code has not changed and the power vs
performance benefits for kernbench are similar to the ones posted
earlier.

KERNBENCH Runs: make -j4 on a x86 8 core, dual socket quad core cpu
package system

SchedMC Run Time     Package Idle    Energy  Power
0	81.61s       53.07% 52.81%  1.00x J 1.00y W
1	81.52s       40.83% 65.45%  0.96x J 0.96y W 
2	74.66s       22.20% 83.94%  0.90x J 0.98y W

*** This is RFC code and not for inclusion ***

Please feel free to test, and let me know your comments and feedback.

Thanks,
Vaidy

Signed-off-by: Vaidyanathan Srinivasan <svaidy@linux.vnet.ibm.com>

---

Gautham R Shenoy (1):
      sched: Framework for sched_mc/smt_power_savings=N

Vaidyanathan Srinivasan (4):
      sched: activate active load balancing in new idle cpus
      sched: bias task wakeups to preferred semi-idle packages
      sched: nominate preferred wakeup cpu
      sched: favour lower logical cpu number for sched_mc balance


 include/linux/sched.h |   12 +++++++
 kernel/sched.c        |   89 ++++++++++++++++++++++++++++++++++++++++++++++---
 kernel/sched_fair.c   |   17 +++++++++
 3 files changed, 112 insertions(+), 6 deletions(-)

-- 

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2008-11-11 17:28 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-10 18:32 [RFC PATCH v3 0/5] Tunable sched_mc_power_savings=n Vaidyanathan Srinivasan
2008-11-10 18:33 ` [RFC PATCH v3 1/5] sched: Framework for sched_mc/smt_power_savings=N Vaidyanathan Srinivasan
2008-11-10 18:33 ` [RFC PATCH v3 2/5] sched: favour lower logical cpu number for sched_mc balance Vaidyanathan Srinivasan
2008-11-10 18:33 ` [RFC PATCH v3 3/5] sched: nominate preferred wakeup cpu Vaidyanathan Srinivasan
2008-11-11 13:43   ` Peter Zijlstra
2008-11-11 14:07     ` Gregory Haskins
2008-11-11 15:21       ` Srivatsa Vaddagiri
2008-11-11 15:26         ` Peter Zijlstra
2008-11-11 17:15           ` Vaidyanathan Srinivasan
2008-11-11 17:17       ` Vaidyanathan Srinivasan
2008-11-11 16:48     ` Vaidyanathan Srinivasan
2008-11-11 16:49       ` Balbir Singh
2008-11-11 17:27         ` Vaidyanathan Srinivasan
2008-11-10 18:33 ` [RFC PATCH v3 4/5] sched: bias task wakeups to preferred semi-idle packages Vaidyanathan Srinivasan
2008-11-10 18:33 ` [RFC PATCH v3 5/5] sched: activate active load balancing in new idle cpus Vaidyanathan Srinivasan
2008-11-11 13:47   ` Peter Zijlstra
2008-11-11 17:04     ` Vaidyanathan Srinivasan
2008-11-11 17:21       ` Peter Zijlstra
2008-11-11 17:31         ` Vaidyanathan Srinivasan
2008-11-10 18:50 ` [RFC PATCH v3 0/5] Tunable sched_mc_power_savings=n Peter Zijlstra
2008-11-11  4:52   ` Vaidyanathan Srinivasan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox