FS#57267 - [linux] [staging] Switch back to 300Hz timer and

Attached to Project: Arch Linux
Opened by David McAdoo (geecroof) - Monday, 29 January 2018, 11:49 GMT
Last edited by Jan Alexander Steffens (heftig) - Tuesday, 30 January 2018, 14:27 GMT
Task Type General Gripe
Category Packages: Testing
Status Closed
Assigned To Tobias Powalowski (tpowa)
Jan Alexander Steffens (heftig)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:

Linux v4.15 package currently in staging switched to 1000Hz timer:
https://git.archlinux.org/svntogit/packages.git/tree/trunk/config?h=packages/linux#n667

1000Hz timer is unwanted on server usage. Moreover it causes more battery drain and heat which is undesirable on laptops, see comments in https://bugs.archlinux.org/task/47086

It also switches to CONFIG_NO_HZ_FULL=y from CONFIG_NO_HZ_IDLE=y which is recommended against in documentation: https://www.kernel.org/doc/Documentation/timers/NO_HZ.txt unless for specific usage.

There is linux-zen package in repos which has all above configs set by default so there is no need to duplicate it in vanilla kernel as there are to many drawbacks for general usage.
This task depends upon

Closed by  Jan Alexander Steffens (heftig)
Tuesday, 30 January 2018, 14:27 GMT
Reason for closing:  Won't fix
Comment by Jan Alexander Steffens (heftig) - Tuesday, 30 January 2018, 05:42 GMT
I've copied the settings from Clear Linux. They probably have good reason to choose these settings for a general purpose kernel.
Comment by David McAdoo (geecroof) - Tuesday, 30 January 2018, 12:30 GMT
Clear Linux isn't general purpose kernel. It's designated for VMs and cloud. Moreover those settings are meaningless if you want to achieve Clear Linux performance as it needs their whole toolchain and rebuilding userspace with it.

I just checked this and only Fedora has 1000Hz while Ubuntu/Debian/OpenSuse defaults to 250Hz. Who has good reason and who hasn't? I linked discussion where people report more heating and power usage under 1000Hz which I can confirm myself. Searching web brings more of the same.

I don't like that things are copy-pasted based on pure belief of "good reason". We need testing, benchmarks and discussion instead. I remember enabling intel-iommu thing which I could instantly report that it won't work.

As I wrote we have linux-zen package which anyone concerned about those settings can use.
Comment by Jan Alexander Steffens (heftig) - Tuesday, 30 January 2018, 13:07 GMT
> Clear Linux isn't general purpose kernel. It's designated for VMs and cloud.

It's also for IoT devices (small Atoms and such), with the kernel I looked at being "optimized for bare metal usage" which makes it general-purpose enough.

> Moreover those settings are meaningless if you want to achieve Clear Linux performance as it needs their whole toolchain and rebuilding userspace with it.

This is blatant bullshit. The changes to the kernel do not require changes to userspace. Kernel changes won't get us on par with Clear Linux, but it can help.

> I linked discussion where people report more heating and power usage under 1000Hz which I can confirm myself.

If you had actually read what you linked to you would have noticed the bug is about lower power use when using 1000 Hz.

> I don't like that things are copy-pasted based on pure belief of "good reason".

Our previous settings didn't have any better reasoning than "it wasn't noticeably bad", either. However, I believe that Intel has professionals working on Clear Linux that do know what they're doing.

> We need testing, benchmarks and discussion instead.

We do. Actual benchmarks would do a much better job at convincing me.

> As I wrote we have linux-zen package which anyone concerned about those settings can use.

linux-zen is irrelevant, as its config will remain close to the normal linux package.
Comment by David McAdoo (geecroof) - Tuesday, 30 January 2018, 14:19 GMT
> This is blatant bullshit. The changes to the kernel do not require changes to userspace. Kernel changes won't get us on par with Clear Linux, but it can help.

Here's benchmark between generic Ubuntu kernel (250Hz) and lowlatency one (1000Hz):
https://www.phoronix.com/scan.php?page=article&item=linux414-lowlatency-liquorix

"The generic Linux 4.14.13 had 15 wins (35%), the Linux 4.13 generic kernel 10 wins (23%), the Liquorix kernel with 9 wins, and then the low-latency kernel with just 8 wins."

Is that what you call "blatant bullshit"? Obviously Clear Linux will win above benchmarks easily but this https://gcc.gnu.org/wiki/AutoFDO is their secret sauce not CONFIG_HZ=1000 or CONFIG_NO_HZ_FULL=y.

> If you had actually read what you linked to you would have noticed the bug is about lower power use when using 1000 Hz.

I wrote "see comments":

"300 Kernel tick rate used by Arch linux as a culprit was a red herring. The root cause issues were also present in the 250 Hz and 1000 Hz kernels" - which invalidate your answer.

"I did some tests with changing CONFIG_HZ to 250hz like Ubuntu and openSUSE Tumbleweed and I get better/lower power use than with 1000hz and noticeably lower than Arch 300 Hz." - which confirms my point.

> linux-zen is irrelevant, as its config will remain close to the normal linux package.

It's relevant because if you want to do some experiments you can do it there.

If your answers for my arguments are "beliefs" and "bullshit" then I don't care anymore about convincing you and I'm done. Feel free to close this.

Loading...