View previous topic :: View next topic |
Author |
Message |
audiodef Watchman
Joined: 06 Jul 2005 Posts: 6656 Location: The soundosphere
|
|
Back to top |
|
|
Roman_Gruber Advocate
Joined: 03 Oct 2006 Posts: 3846 Location: Austro Bavaria
|
Posted: Mon Feb 01, 2016 7:02 am Post subject: |
|
|
experimental use flag allows march settings, e.g. ivybride march for my q3610qm cpu.
manual build kernel with experimntal useflag + march ivybridge had some impact, comparing libreoffice built times before and after the change.
I repeated that to verify it and it was everytime faster as before. I also checked different packages |
|
Back to top |
|
|
TigerJr Guru
Joined: 19 Jun 2007 Posts: 540
|
Posted: Mon Feb 01, 2016 11:44 am Post subject: Re: Genkernel vs. manual kernel config |
|
|
audiodef wrote: | Has anyone benchmarked genkernel vs. manual kernel config? Is one faster, more memory efficient, etc., than the other?
(I'm ignoring kernel size on disk or length of time it takes to compile.) |
It depend on what you do with this kernel, if you experienced with manual configuration you can make many needed function faster and turn off unneeded function and drivers (kernel size is easy to analyze i.e. fast boot, and all function and drivers need size and time to load, big sized and heavy function with many operation and cpu instruction works slower), if you not experienced with manual configuration, than you can't turn off unneeded function and even have faced with kernel panics or your kernel would slower or unbootable, that pushes you to use genkernel or already compiled kernel. _________________ Do not use gentoo, it die |
|
Back to top |
|
|
szatox Advocate
Joined: 27 Aug 2013 Posts: 3487
|
Posted: Mon Feb 01, 2016 5:17 pm Post subject: |
|
|
Quote: | Has anyone benchmarked genkernel vs. manual kernel config? Is one faster, more memory efficient, etc., than the other?
(I'm ignoring kernel size on disk or length of time it takes to compile.) | You ignore the build-time stuff... So, you can launch make manually or have genkernel launch it for you.
In both cases you use gcc and kernel's .config. If your configs (and low-level compiler flags) match, you should get the same result. So... What do you want to benchmark against what, and what is the point? |
|
Back to top |
|
|
Tony0945 Watchman
Joined: 25 Jul 2006 Posts: 5127 Location: Illinois, USA
|
Posted: Mon Feb 01, 2016 5:38 pm Post subject: |
|
|
Are you comparing apples and apples? Manual configuration versus genkernel with the same kernel configuration?
It sounds like you are asking about manual configuration versus stock configuration. Genkernel is just a script to do the steps without manually typing them in. The only real difference is that genkernel doesn't forget to copy the kernel to /boot or to update the boot menu. The one weakness is that it requires an intitramfs. If you are using one anyway, there is no reason not to use genkernel.
I stopped using genkernel but only because I've ditched the initramfs.
It would be interesting to bench mark a hand kernel against the same config as built with an initramfs by genkernel.
To do it you would build the hand kernel, save the config to <my saved config> then run "genkernel --config=<my saved config> all". You can't leave it in /usr/src/linux/.config because genkernel overwrites it.
Easy enough to do, but the benchmarking procedure needs more thought. |
|
Back to top |
|
|
audiodef Watchman
Joined: 06 Jul 2005 Posts: 6656 Location: The soundosphere
|
Posted: Mon Feb 01, 2016 7:26 pm Post subject: |
|
|
I'm interested in how efficiently a genkernel kernel, created with "genkernal all" and no specific options, runs (don't care about compile times for anything) compared to the same kernel sources carefully compiled manually for the same system, with anything not needed by the system removed. Is there a real difference?
But I've decided to perform a comparison myself on the particular system I have in mind. That seems the best way to decide if I want to recommend genkernel as an option for Gentoo Studio. _________________ decibel Linux: https://decibellinux.org
Github: https://github.com/Gentoo-Music-and-Audio-Technology
Facebook: https://www.facebook.com/decibellinux
Discord: https://discord.gg/73XV24dNPN |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54794 Location: 56N 3W
|
Posted: Mon Feb 01, 2016 7:33 pm Post subject: |
|
|
audiodef,
Other than building and loading modules you don't need, there should be no execution time differences.
Its the same code in both cases. The difference is in the unneeded baggage.
I'll be interested in your results though. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
Roman_Gruber Advocate
Joined: 03 Oct 2006 Posts: 3846 Location: Austro Bavaria
|
Posted: Tue Feb 02, 2016 11:40 am Post subject: |
|
|
regarding build times.
i used for years
make && make modules_install
because it was in the guides and i never cared, or read the man-page
last year i read the manpage and there is the --jobs option. was kinda annoyed to see it taking a very long time. checked i7z tool and saw only one core in use.
you need to look it up yourself but it is something like, for 3610qm (when you want full hyperthreading in use), load should be around 8 or 9 than. my personal opinion is to keep the load between 8 and 9. because it is a quadcore cpu with hyperthreading. ... i7z tells a bit on how the cores are utilized.
make --jobs 10 && make --jobs 10 modules_install
as said check the manpage, how the syntxx for the job option is
when you build a kernel, you need to consider for a desctop box you want a responsive box. I had a few kernels built which were slight faster, but when the box was unresponsive to the user, it is kinda worthless.
except the experimental useflag and ivybridge option, i hardly got any tweaks which showed some impacts. |
|
Back to top |
|
|
bstaletic Guru
Joined: 05 Apr 2014 Posts: 462
|
Posted: Tue Feb 02, 2016 2:39 pm Post subject: |
|
|
Regarding performance, I see no difference. Regarding battery life, it's more than noticeable. |
|
Back to top |
|
|
Tony0945 Watchman
Joined: 25 Jul 2006 Posts: 5127 Location: Illinois, USA
|
Posted: Tue Feb 02, 2016 5:06 pm Post subject: |
|
|
tw04l124 wrote: | i used for years
make && make modules_install |
My build script Code: | X3 ~ # cat `which buildmykernel`
#!
cd /usr/src/linux
zcat /proc/config.gz >.config
# At this point we should compare kernel versions and make oldconfig if the base version has updated
make menuconfig && make -j7 && make -j7 modules_install && make -j7 install && echo "Don't forget to update boot loader menu"
| The && parts aren't working quite right. I can have build errors and the next stage continues anyway. I copied this from a six core box, I should change it to j4 on the box I ran from because it's a three core. Builds run fast anyway. |
|
Back to top |
|
|
Syl20 l33t
Joined: 04 Aug 2005 Posts: 621 Location: France
|
Posted: Tue Feb 02, 2016 5:54 pm Post subject: |
|
|
Tony0945 wrote: | The && parts aren't working quite right. I can have build errors and the next stage continues anyway. |
Code: | make -jx && make -jx modules_install install | works well for me. I see warnings, but no errors.
As "make install" updates the symlinks, I don't need to update the boot menu (but I don't use the awful grub-fat-menu-makin' scripts at all). But I should add a "emerge @module-rebuild" warning, it's a task I often forget. |
|
Back to top |
|
|
The Main Man Veteran
Joined: 27 Nov 2014 Posts: 1172 Location: /run/user/1000
|
Posted: Sun Feb 07, 2016 7:37 pm Post subject: |
|
|
Tony0945 wrote: | The one weakness is that it requires an intitramfs.
I stopped using genkernel but only because I've ditched the initramfs.
|
And that is weakness why exactly ?
Boot time speed or something else ? |
|
Back to top |
|
|
szatox Advocate
Joined: 27 Aug 2013 Posts: 3487
|
Posted: Sun Feb 07, 2016 7:45 pm Post subject: |
|
|
Oh, genkernel does not enforce using initramfs. It builds one, but adding the path to kernel's command line is up to you.
You can ignore it, unless you particular setup requires it. (like root on LVM) |
|
Back to top |
|
|
Tony0945 Watchman
Joined: 25 Jul 2006 Posts: 5127 Location: Illinois, USA
|
Posted: Sun Feb 07, 2016 8:17 pm Post subject: |
|
|
szatox wrote: | Oh, genkernel does not enforce using initramfs. It builds one, but adding the path to kernel's command line is up to you.
You can ignore it, unless you particular setup requires it. (like root on LVM) |
I didn't realize that. Genkernel adds the line and I assumed it needed it.
So they only reason not to use genkernel is "real men type everything by hand". |
|
Back to top |
|
|
Tony0945 Watchman
Joined: 25 Jul 2006 Posts: 5127 Location: Illinois, USA
|
Posted: Sun Feb 07, 2016 8:21 pm Post subject: |
|
|
CneGroumF wrote: | Tony0945 wrote: | The && parts aren't working quite right. I can have build errors and the next stage continues anyway. |
Code: | make -jx && make -jx modules_install install | works well for me. I see warnings, but no errors.
As "make install" updates the symlinks, I don't need to update the boot menu (but I don't use the awful grub-fat-menu-makin' scripts at all). But I should add a "emerge @module-rebuild" warning, it's a task I often forget. |
Works well for me too, but sometimes it fails to make bzimage but goes merrily on without returning non-zero so at the end the script ran but there is no vmlinuz in /boot.
It's not the fault of the script that the build fails, but it should stop, but doesn't. If you scroll through the messages you see the compilation failure. The script should stop. |
|
Back to top |
|
|
Roman_Gruber Advocate
Joined: 03 Oct 2006 Posts: 3846 Location: Austro Bavaria
|
Posted: Sun Feb 07, 2016 9:34 pm Post subject: |
|
|
the issue is, there is hardly no benefit in the way how you do it.
and as you mentioned you hardly get a feedback.
I am not sure if this is a bash feature, quoting from my i3.config
Code: | scrot '%d-%m-%Y_%H:%M:%S_screenshot.png' -e 'mv $f ~/Screenshots/' |
AFAIk those % ... makes it easy to give a date stamp to your file-name. you may use that too.
and serious, you ask for issues when you do not type those make commands yourself and change the kernel yourself. and even do not rename the kernel yourself.
When you have not a proper kernel, your box will not boot or has other issues. it is a critical component, and that's why id o it by hand.
linux mint, the idiots of scripting, destroyed several of my boxes with their automated grub sripts ... only because someone coded something, does not mean it is foolproof or was written with every possible case in mind. or does even consider a valid grub entry to keep it.
portage is the best example to show how limited scripting is. (endless topics on how to improve portage or the flaws of it)
..
i always wanted to learn or improve my bash coding.
you may check for a return value of your function. it may exists. and than you can evaluate that return value before continuing. |
|
Back to top |
|
|
audiodef Watchman
Joined: 06 Jul 2005 Posts: 6656 Location: The soundosphere
|
Posted: Fri Feb 12, 2016 2:21 am Post subject: |
|
|
NeddySeagoon wrote: | audiodef,
Other than building and loading modules you don't need, there should be no execution time differences.
Its the same code in both cases. The difference is in the unneeded baggage.
I'll be interested in your results though. |
Yeah, it does seem like there should be no performance difference. Genkernel might actually be good for Gentoo Studio, as it seems it would give the user a higher chance of all necessary modules for supported audio hardware being loaded than if the user does it manually and overlooks something. _________________ decibel Linux: https://decibellinux.org
Github: https://github.com/Gentoo-Music-and-Audio-Technology
Facebook: https://www.facebook.com/decibellinux
Discord: https://discord.gg/73XV24dNPN |
|
Back to top |
|
|
|