lca13: big.little mp updates
DESCRIPTION
Resource: LCA13 Name: big.LITTLE MP Updates Date: 04-03-2013 Speaker: Vincent GuittotTRANSCRIPT
ASIA 2013 (LCA13)
big.LITTLE updatePower Management Working Group - v2Vincent Guittot / Amit Kucheria / Morten Rasmussen
ASIA 2013 (LCA13)
www.linaro.org
Content
StatusPolicyPatchesOpen issuesDetails
ASIA 2013 (LCA13)
www.linaro.org
Status
Current Linaro kernel uses old HMP patches
New patches designed to not be HMP specific
Patches under internal review and testsCurrently under review and test by ARM and Linaro1st results are aligned with old HMP patches
Available on git.linaro.orgSee patches section
Few use cases need to be improvedSee open issues section
ASIA 2013 (LCA13)
www.linaro.org
Policy
As simple as 3 rules
Pack small tasks on LITTLE cores at wake up
Balance long running tasks in priority
Choose core with best capacity
ASIA 2013 (LCA13)
www.linaro.org
Patches : some fixes
Fix nr_busy_cpusRemove spurious trig of Idle Load Balancehttps://lkml.org/lkml/2013/2/21/53v5 under preparation
Fix load_avg with -rt taskFix the load average tracking if only -rt tasks run on a corehttps://lkml.org/lkml/2013/2/13/71
Fix active migrationFix the target CPU of active load balance if only 1 task run on a corehttps://lkml.org/lkml/2013/2/12/158
ASIA 2013 (LCA13)
www.linaro.org
Patches : load balance (1/2)
Pack small tasksPack small tasks on few cores (A7 for b.L)http://lwn.net/Articles/528883/v3 under test
Use per task load averageWeight the task contribution with the run timeOnly nice priority before
Use LB_MIN featureBalance long running tasks in priorityPST takes care of small task
ASIA 2013 (LCA13)
www.linaro.org
Patches : load balance (2/2)
Migrate on CPU with highest capacityUse CPU with highest capacity
Tune sched_domain for b.LTunings for b.L platformReduce Periodic load balance for responsiveness
Scaling InvarianceEnsure load invariance across core and running frequencyNot available yet
ASIA 2013 (LCA13)
www.linaro.org
Open issue: nice priority - load_avg_contrib
Nice priority define a “runtime slice allocation”
load_avg_contrib is %runnable x nice_prionice priority -20 @ 10% : 887nice priority 0 @ 100% : 1024nice priority 10 @ 100% : 110
What is the best place for :
A long running task with low priority ?AsyncTask in Android as an example
A short running tasks with high priority ?
ASIA 2013 (LCA13)
www.linaro.org
A15 clustercapacity of 2882
CPU0
Open issue: Offloading to A7
Use A7 instead of overloading A15
Load balance puts more tasks on A15 and let an A7 idleExample with sysbench and 5 threads
T0
CPU1
T1
T2
A7 clustercapacity of 1883
CPU3
T3
CPU4
T4
CPU2
ASIA 2013 (LCA13)
www.linaro.org
Pack small tasks in details
Pack small taskson LITTLE core for big.LITTLE
Powertop results for Android MP3 playback
A15 Cluster CPU0 CPU1
WFI 0% 0%
C1 99,4% 99,9%
A7 Cluster CPU2 CPU3 CPU4
WFI 0,2% 0,1% 0,0%
C1 80,1% 97,6% 98,2%
ASIA 2013 (LCA13)
www.linaro.org
Use best core in details
Use the core with highest capacity
Periodic load balance focuses long running tasksEnsure long running tasks are balanced in priority
A15
A15
A7
A7
A7
ASIA 2013 (LCA13)
www.linaro.org
Bbench example
Page rendering example with audio playback
WebViewCore-Thread
SurfaceFlinger
Android.browserAudio Threads
A15
A15
A7
A7
A7
A15
A15
A7
A7
A7
More about Linaro Connect: www.linaro.org/connect/ More about Linaro: www.linaro.org/about/
More about Linaro engineering: www.linaro.org/engineering/
ASIA 2013 (LCA13)