Re:Supporting Linux kernel development in Rust
by robocat on Monday August 31, 2020 @07:45PM
(#24337057)
Article discussing LTO (Link Time Optimizations, used by Google Pixel) and PGO (Profile Guided Optimizations): https://www.phoronix.com/scan.php?page=news_item&px=Microsof...
Re:Supporting Linux kernel development in Rust
by jcranmer on Monday August 31, 2020 @05:01PM
(#24335905)
> unless you want to use cross-language LTO (which we'll eventually want to do, but it won't be a hard requirement for a working kernel).
Does Linux even work with LTO right now? It seems to do a lot of weird-linking-magic things that I wouldn't expect to work well with LTO.
Re:Supporting Linux kernel development in Rust
by geofft on Monday August 31, 2020 @09:22PM
(#24337595)
There was a talk right after ours about LTO! I only half paid attention to it because I was catching up on the chat, but it sounds like Google is doing kernel LTO in prod for their internal systems (and maybe also for Android and CrOS?):
https://linuxplumbersconf.org/event/7/contributions/798/ (slide link at the bottom)
Re:Supporting Linux kernel development in Rust
by JoshTriplett on Monday August 31, 2020 @05:05PM
(#24335959)
At the moment, I believe the Linux kernel can do LTO with some additional patches, but there are still regular issues. It isn't nearly as well supported as Clang or LLD yet.
Re:Supporting Linux kernel development in Rust
by danudey on Wednesday September 02, 2020 @02:51PM
(#24356460)
ICYMI, Microsoft is putting a lot of eggs into the LTO/PGO basket to try to improve Linux performance: https://www.phoronix.com/scan.php?page=news_item&px=Microsof...
So, we're currently expecting that supporting Rust will not place any requirements on the C compiler you use, unless you want to use cross-language LTO (which we'll eventually want to do, but it won't be a hard requirement for a working kernel).