Worse performance when power supply plugged in!

Optimize your system for ultimate performance.

Moderators: khz, MattKingUSA

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Worse performance when power supply plugged in!

Postby Musicteacher » Tue Apr 09, 2019 7:45 pm

Hi,
I have made a very strange observation: My system performance is terrible, when my power supply is plugged in!

If I put it out again, everything is fine. If not, I get abysmal sound, thousands of xruns, and a warning "cpu overload".

I have a thinkpad l380 yoga. Any hints are very welcome!

This is a serious problem for me, for longer concerts I really need the power supply! I am completely baffled, shouldn't the performance be BETTER when the power supply is in?

Regards,
Andreas

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Tue Apr 09, 2019 8:16 pm

I found out something more: The performance is worst, when I set the cpu governor to performance + power supply plugged in.

If I don't do that, performance is medium, but nowhere near as good as when in battery-mode with performance set to "performance".

Is that a hardware - bug? Anyone heard of something like this?

Any help is appreciated!

Andreas

User avatar
lilith
Established Member
Posts: 989
Joined: Fri May 27, 2016 11:41 pm
Location: bLACK fOREST
Contact:

Re: Worse performance when power supply plugged in!

Postby lilith » Tue Apr 09, 2019 8:33 pm

Can you test it with e.g. a live AVLinux? Never heard of such an issue, but I guess there's a solution for it.
https://soundcloud.com/lilith_93

_____________________________
Debian 9 (XFCE) & KXStudio repos

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Tue Apr 09, 2019 9:45 pm

That's a really good idea! This way I can rule out misconfiguration on my side. I'll do that tomorrow!

Thanks,
Andreas

zoco
Established Member
Posts: 177
Joined: Fri Jan 25, 2019 4:04 pm

Re: Worse performance when power supply plugged in!

Postby zoco » Tue Apr 09, 2019 10:37 pm

It is possible that your power supply output is not smoothed out properly or is no longer smoothed out, causing a disruptive signal. You could try a different power supply to test this.

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Tue Apr 09, 2019 11:07 pm

Thank you, too. My wife has a suitable power supply, I will try that tomorrow.

In the meantime I have de-activated intel speed-step in bios, now the worst drop-outs are gone.

But this cuts down performance quite drastically (top-speed is 1.6 gHz then, instead of 3.4 maximum speed with speed-step turned on).

I think that it might be the case that with power supply in, the cpu is pushed harder and then drops down lower when it's too hot (just a theory).

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Wed Apr 10, 2019 7:36 am

Hi,
I am at my wits end: This morning, everything is fine with power-supply in.

So I guess that yesterday evening the cpu was hot, and with power supply in it got even hotter which lead to sudden throttling and dropouts.

I cannot say "fine, now it works", because I need to rely on this machine for live performances.

The new kernel uses intel_pstate driver for cpu-speed-scaling. Maybe I should turn that off and use the older driver.

If I completely de-activate intel speedstep, I am on the safe side, but I have pretty low overall performance then. I get on the edge of the possible when using pianoteq + guitarix on the same machine.

Anyone here with experience with intel_pstate vs acpi-cpufreq ? As described here:

https://wiki.archlinux.org/index.php/CP ... cy_scaling

Any ideas are really welcome!

Regards,
Andreas

User avatar
sysrqer
Established Member
Posts: 1811
Joined: Thu Nov 14, 2013 11:47 pm
Contact:

Re: Worse performance when power supply plugged in!

Postby sysrqer » Wed Apr 10, 2019 7:41 am

Do you have tlp or anything like that installed? You could try powertop to see if there are any obvious issues.

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Wed Apr 10, 2019 7:54 am

tlp is not installed.
What would be an obvious issue shown with powertop? I can have a look if the problem reappears.

At the moment I am thinking in the lines of controlling fan-speed to keep cpu temperatures lower to avoid sudden throttling. What is your opition on that?

I have installed psensor and saw that after disabling performance mode, cpu temperature lowered (in about 5 minutes) by 10 degrees. But I still do not know if I am on the right track.

Maybe I should do some serios recording this evening and see if the problem reappears. Then I can have a look at cpu temperatures.

The general question (mabe better in a differend thread): What do you guys do with
- intel speed step
- cpu power management
- performance governor

I had also thought that maybe I should set the maximum frequency to a lower value than 3.4gHz, to avoid overheating and still get a good performance (like, to 2.8 gHz or so).

But maybe all of you do not use notebooks, so you do not have problems like that.

Thanks for your advice,
Andreas

User avatar
sysrqer
Established Member
Posts: 1811
Joined: Thu Nov 14, 2013 11:47 pm
Contact:

Re: Worse performance when power supply plugged in!

Postby sysrqer » Wed Apr 10, 2019 9:18 am

I'm not sure what to look out for with powertop, I've only used it to spot issues with power consumption but it might show something.

Your issue is odd though. What exactly are you doing, using jack, ardour etc? What have you done to optimise for audio? Which kernel are you using and are you using the microcode package for your processor? Does the realtimeconfigscan show any problems when you run it with the power plugged in?

I have speed step enabled, and generally have the governor set to powersave unless I do audio when I manually change it to performance if I notice issues.

User avatar
Linuxmusician01
Established Member
Posts: 585
Joined: Mon Feb 23, 2015 2:38 pm
Location: Holland

Re: Worse performance when power supply plugged in!

Postby Linuxmusician01 » Wed Apr 10, 2019 10:42 am

sysrqer wrote:[...] You could try powertop to see if there are any obvious issues.

Never heard of the program. Installed it: thanks for your super tip! :)

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Wed Apr 10, 2019 1:28 pm

I'm on arch, rt-kernel 5.0.5 .

I do:

I summarize what I do on my system:
- use linux-rt kernel (which does not seem to make a real difference, at least as shown by xruncounter)
- set cpu governor to performance
- disable hyperthreading
- suspend baloo (with the command balooctl suspend )
- disable compositing
- disable kde power managemend
- set kde to plane-mode (this disables wlan + bluetooth)
- set realtime irq optimizations (rtirq start)


I use a behringer umc 1820 as soundcard, 96 bit buffer (or 48 bit), 3 periods (qjackctl shows 4 ms latency, which is probably 8 ms roundtrip).

If I do all of this, usually I only get xruns when I start a new program. But yesterday evening when I plugged in the power supply, I got thousands of xruns, xruncounter reportet first xruns at about 30%, I got a warning "cpu overload" in jack. Pianoteq was unusable, other stuff still gave sound, but several audible xruns every minute.

As soon as I plugged out the power supply or changed the performance governor from performance to powersave, things improved, but I still got the occasional xrun (which is normally not the case, as said above).

My theory, as I said, is that this is a thermal problem.

Maybe I shouldn't set the governor to performance but instead rise in powersave mode the lower bound of the frequency to, say, 1.6gHz (which is the frequency the system has without intel speedstep, a frequency that should be possible constantly).

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Thu Apr 11, 2019 10:22 am

Hi,

I think I have progressed a bit (can I say it like this? Made some progress?)

Yesterday I watched some movies on the said notebook. After that, the battery was quite drained. I went to my music room, plugged it the supply and made some music. Performance was really bad again.

Explanation: From watching movies the notebook was quite hot already. The battery gets really hot when being charged. This way, the turbo-boost frequency cannot be kept for a long time, if at all.

The performance-governor tries to turbo-boost all the time.

This also explains the very unreliable results from xruncounter. The "load" is calculated via the cpu-speed. If the cpu is changing speed all the time, the load "jumps" when xruncounter runs. On my machine, you sometimes get into an infinite loop with xruncounter, because cpu is jumping all the time.

So to be on the safe side, for music speedstep should be de-activated (that is the easy solution).

If you really need higher frequencies, take care of extra-well cooling and make extensive tests if the higher frequency can really be kept for a longer time. Also it would probably be wise to set the cpu-frequency only as high as needed, not the highest possible.

I will now do some tests if performance is sufficient when speedstep ist turned off.

merlyn
Established Member
Posts: 458
Joined: Thu Oct 11, 2018 4:13 pm

Re: Worse performance when power supply plugged in!

Postby merlyn » Thu Apr 11, 2019 1:47 pm

My friend uses a laptop as his main audio system. Because he always has the power supply plugged in he took the battery out. He read somewhere that this is better for the battery. If excess heat is the problem then taking the battery out would eliminate the heat from charging the battery.

If you're not keen on the idea, I can see why. :)

Musicteacher
Established Member
Posts: 167
Joined: Mon Nov 13, 2017 5:54 am

Re: Worse performance when power supply plugged in!

Postby Musicteacher » Thu Apr 11, 2019 2:28 pm

This is not easily possible (modern notebook, battery non-detachable). However, I will try to keep the battery fully charged. This way it won't heat up while charging.


Return to “System Tuning and Configuration”

Who is online

Users browsing this forum: No registered users and 1 guest