RuneUI high CPU usage in stream

Please report any bug found here

RuneUI high CPU usage in stream

Postby The Setlaz » 27 Mar 2016, 11:45

Hi,

I noticed my laptop CPU usage goes to 80% usage when browsing on RuneUI interface when streaming audio through DLNA. Resources are taken by Browser and Xorg.
As soon as I switch tab or set pause the music from RuneUI, CPU usage goes back to normal (10%).
This only happens from streaming through DLNA / listening to Web radio, but not when playing music from RuneAudio Library.

I wonder if this has something to do with the time counter / circle drawing?
Or is it just my too old CPU? :oops:

EDIT: this also happens on my Android phone on with the RuneAudio app

RuneAudio on Raspberry Pi 2 with latest RuneAudio (git pulled)
OS: Ubuntu 16.04
Browser: Firefox / Chromium
CPU: Intel Core2Duo T7100 (don't laugh, it's still working fine :mrgreen: )
Phone: HTC One S (MSM8960)
Attachments
Rune_phone.png
Phone CPU usage
Rune_phone.png (60.03 KiB) Viewed 1871 times
Rune_CPU.png
Laptop CPU usage
Rune_CPU.png (188.02 KiB) Viewed 1872 times
The Setlaz
 
Posts: 17
Joined: 12 Jun 2015, 13:46

Re: RuneUI high CPU usage in stream

Postby PeteB » 27 Mar 2016, 17:05

The Setlaz wrote:I wonder if this has something to do with the time counter / circle drawing?
Or is it just my too old CPU? ...

I can confirm that, I checked this morning, and the CPU load definitely goes up when playing a radio stream.

It's not your CPU, I am at 37% CPU on an Intel Core I5 2.5GHz laptop when it happens, and back down to 5~8% when I stop it.

It may actually explain another problem I have had running the UI on an old Nexus tablet, so I am grateful you posted this.

Pete
PeteB
 
Posts: 421
Joined: 06 Feb 2016, 05:07

Re: RuneUI high CPU usage in stream

Postby The Setlaz » 27 Mar 2016, 18:19

Thanks for the confirmation Pete!
Now that you mention it, I went on RuneUI from my desktop (Ubuntu 14.04 + Firefox) that has a Core i5 3570K, top reports 60% CPU usage :o (System-monitor shows the 4 CPUs averaging around 25% each instead of 5%)
That would definitely be a battery killer on mobile devices too.
Attachments
Desktop_CPU_usage.png
Desktop_CPU_usage.png (195.47 KiB) Viewed 1857 times
The Setlaz
 
Posts: 17
Joined: 12 Jun 2015, 13:46

Re: RuneUI high CPU usage in stream

Postby PeteB » 27 Mar 2016, 20:43

In general, I am quite happy running the remote app on a "slow" tablet, and I don't mind dedicating a Nexus 7 I bought used on ebay to running the UI. It works quite well for that with the XBMC/Kodi remote app, and most of the time it works well with the Rune Remote App also.

Now I think I may know why it just seems to stall or bog down some of the time... I was not even suspecting the processor load while enjoying my new streaming radio stations, LOL. It was really annoying, (not so much because it happened, but because I did not know why)

The tablet just stops, and the spinning circle starts, and unfortunately it does not recover w/o restarting the remote control app. Then I walk over to the laptop, and everything seems fine there!
PeteB
 
Posts: 421
Joined: 06 Feb 2016, 05:07

Re: RuneUI high CPU usage in stream

Postby hondagx35 » 27 Mar 2016, 22:33

Hi The Setlaz,

i have made some tests:

Test are made with webradio and DLNA on the latest image.
- no problems on Windows7 / Firefox
- no problems on Windows7 / Chrome
- no problems on Ubuntu 12.04 / Firefox

Your files have 00:00 duration, this may be a problem (division by zero) on your browser.
Please check the console in Firefox (F12).

Frank
User avatar
hondagx35
 
Posts: 3042
Joined: 11 Sep 2014, 22:06
Location: Germany

Re: RuneUI high CPU usage in stream

Postby The Setlaz » 27 Mar 2016, 23:08

Hi Frank,

Thanks for your test. There are no "files". RuneAudio decides the stream (radio or DLNA) is 00:00 long.
I don't see anything in the Firefox console (although I'm not quite sure what to look for, but there are no errors reported there)

Is the image available any different from an updated RuneAudio via gitpull?

Thanks again!
The Setlaz
 
Posts: 17
Joined: 12 Jun 2015, 13:46

Re: RuneUI high CPU usage in stream

Postby hondagx35 » 27 Mar 2016, 23:33

Hi,

Is the image available any different from an updated RuneAudio via gitpull?

Download the new RP2/RP3 image from the link in my last post.

Frank
User avatar
hondagx35
 
Posts: 3042
Joined: 11 Sep 2014, 22:06
Location: Germany

Re: RuneUI high CPU usage in stream

Postby The Setlaz » 28 Mar 2016, 01:39

Hi Frank,

I just flashed the new image, unfortunately I'm still seeing the problem. :oops:
Webradio shows time as infinity but DLNA stream shows 00:00.
In both cases, I have high CPU usage. It also seems that CPU usage is higher once the time-circle is fully drawn (blue)

I also tried on Windows 7 + Firefox on my desktop and I also see "above than normal" CPU usage (but not as bad as on Ubuntu).

Thanks for helping on this!
The Setlaz
 
Posts: 17
Joined: 12 Jun 2015, 13:46

Re: RuneUI high CPU usage in stream

Postby PeteB » 28 Mar 2016, 03:16

For completeness, I am running the 3/13 Image, Ubuntu 14.04, and latest Android available on my two android devices. Firefox/Ubuntu, Chrome on Android. The high processor load is only observable when the window or tab with the UI has focus. The moment I click on anything else, the processor load drops down to a normal ~5-10%.
PeteB
 
Posts: 421
Joined: 06 Feb 2016, 05:07

Re: RuneUI high CPU usage in stream

Postby hondagx35 » 28 Mar 2016, 10:34

Hi,

i did some more tests and i'm able to reproduce your issues partially.

I also get higher CPU loads when playing files with missing tags or webradios without streaming information.
So there is an java script issue on the browser.

@ The Setlaz:
What is this "stream.flac" file you have shown in the picture?

Frank
User avatar
hondagx35
 
Posts: 3042
Joined: 11 Sep 2014, 22:06
Location: Germany

support RuneAudio Donate with PayPal

Next

Return to Bug report

Who is online

Users browsing this forum: No registered users and 2 guests