Clang PGO Shot Down For Now From The Linux Kernel


Whereas Clang PGO increase used to be despatched in for Linux 5.14 as a part of Clang compiler dealing with updates for this next kernel version, the performance used to be for this reason fact dropped out and a novel pull put aside a matter to issued after criticism from Linus Torvalds and others.

Whereas Google and others have already been utilizing this Clang profile guided optimization increase for the Linux kernel to construct workload-optimized kernels, there had been questions and criticisms raised over it that resulted in the pull put aside a matter to being re-submitted without the PGO bits in mumble.

Linus Torvalds puzzled its profiling formulation with counting on LLVM/Clang instrumentation in mumble of specializing in being ready to assemble the profile/sampling utilizing the kernel’s gift perf subsystem. The Clang tooling though appears to be more common and in better standing at the 2d. In explicit with going the perf route, easiest with Intel CPUs are the hardware performance counters dealing with in very upright shape. With AMD Zen 3 processors the performance counters increase is in better shape, but this otherwise would pose a controversy for those on non-Intel programs looking out for to construct a PGO-optimized kernel if utilizing perf for sampling. There could be a shortage of upright perf profiling increase at the 2d on ARM.

Somehow though Linus is more in desire of utilizing the kernel’s perf infrastructure in mumble of the LLVM instrumentation after which changing that perf knowledge true into a usable layout for Clang. Considerations had been also raised by others about how unparalleled of this kernel PGO infrastructure would be portable to other compilers and the hunch of the kernel in its debug/profiling mode when gathering acknowledged profiles.

Thus as a minimal for now the Clang updates pulled into Linux 5.14 had been re-despatched and already merged without the PGO increase in mumble.

0 0 vote
Article Rating
Notify of
Inline Feedbacks
View all comments
Would love your thoughts, please comment.x