High CPU usage on arale when running simple clients with animations
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mir |
Confirmed
|
Undecided
|
Unassigned | ||
mir (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned | ||
qtmir (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned | ||
unity8 (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
It seems that independently from which Mir server I use (mir_demo_server, qtmir-demo-shell, unity8) the CPU usage on Arale when running any simple client seems to be quite high.
My investigation started with a designer contacting me about
https:/
and
https:/
Since the activity indicator visual has to be updated anyway, we were looking at the options we had to also make it less CPU consuming at the same time.
It turned out it's not a matter of how you render it, anything that causes redraw at 60fps will cause high cpu usage, here are the results I got:
Tools:
phablet-shell to run the commands
top to see cpu usage
Device:
Arale, rc-proposed r370
Setup:
clean flash + apt-get install qtmir-tests mir-demos
(qtmir-tests will remove qtmir-android, you'll have to reinstall it until https:/
echo 806000 > /sys/devices/
echo 806000 > /sys/devices/
and the same for cpu1 and cpu2 (after bringing them online by scrolling scopes)
Results:
=== Minimal Mir server + egltriangle demo ===
sudo su
stop lightdm
echo 2047 > /sys/class/
sudo mir_demo_
(separate shell, phablet user)
mir_demo_
1 CORE ONLINE
mir_demo_server: 12.5%
mir_demo_client: 11%
=== Mir demo server + egltriangle demo ===
sudo su
stop lightdm
echo 2047 > /sys/class/
LD_PRELOAD=
1 CORE ONLINE
mir demo server: 20%
mir_demo_client: 9%
=== Qt Mir demo shell + egltriangle demo ===
sudo su
stop lightdm
echo 2047 > /sys/class/
cd /usr/share/
MIR_SERVER_
(on a separate shell, phablet user)
MIR_SOCKET=
1 to 2 CORES ONLINE (varying)
qmlscene (Mir server): 27.5% CPU
mir_demo_client: 10% CPU
=== Unity8 + test qml app ===
qmlscene test.qml --desktop_
2 CORES ONLINE
Unity8: 30%
qmlscene: 15%
USC: 10%
==== QML TEST FILE ====
import QtQuick 2.4
import Ubuntu.Components 1.3
Item {
anchors.fill: parent
/*AnimatedS
id: sprite
width: 69
height: 69
source: "spinner-
frameCount: 74
frameSync: true
frameWidth: 81
loops: 100
}*/
/*ActivityI
id: indicator
running: true
}*/
Rectangle {
id: rect
width: 69
height: 69
color: "orange"
loops: Animation.Infinite
from: 0
to: 360
}*/
loops: Animation.Infinite
from: 0
to: 360
}*/
XAnimator {
target: rect;
from: 0;
to: 360;
}
}
Timer {
interval: 10000
running: true
}
}
description: | updated |
tags: | added: performance |
summary: |
- High CPU usage when running simple clients with animations + High CPU usage on arale when running simple clients with animations |
Changed in mir: | |
status: | Expired → Confirmed |
Changed in qtmir: | |
status: | Expired → Confirmed |
Changed in unity8 (Ubuntu): | |
status: | Expired → Confirmed |
Changed in mir (Ubuntu): | |
status: | Expired → Confirmed |
Changed in qtmir (Ubuntu): | |
status: | Expired → Confirmed |
no longer affects: | qtmir |
Status changed to 'Confirmed' because the bug affects multiple users.