Comment 69 for bug 1926938

Revision history for this message
DanglingPointer (ferncasado) wrote :

Good stuff @Jens Glathe!

I recommend everyone stuck to just build it and they'll see it work perhaps even better than before, especially if you start natively optimising the build against your hardware. Your OS kernel will make your system feel and run snappier!

This is my build command post configuration (GCC)...
$ time KCFLAGS="-march=native -msse2avx -pipe -O3" KCPPFLAGS="-march=native -msse2avx -pipe -O3" make -j$(( $(nproc) + 1 )) deb-pkg LOCALVERSION=-danglingpointer-zen3-optimised

This is my build command post CLANG configuration with LTO...
time KCFLAGS="-march=native -pipe -O3" KCPPFLAGS="-march=native -pipe -O3" make -j$(( $(nproc) + 1 )) LLVM=1 LLVM_IAS=1 deb-pkg LOCALVERSION=-danglingpointer-zen3-clang-ltothin

For Clang LTO=thin you will need to configure for it.
1) prep the config using the config from Ubuntu Mainline. Basically just copy it and then $ make olddefconfig
2) scripts/config -e LTO_CLANG_THIN
3) run the clang make command above with KCFLAGS.

Check phoronix for GCC(all versions) vs CLANG-12

Only problem I have with CLANG is that it can bugger up any DKMS programs you may have. Virtualbox is an example which is geared towards GCC. I have CLANG built linux kernels running everywhere except wherever I have Virtualbox. There I use GCC-11.