zev
honked back 16 Nov 2024 16:10 -0800
in reply to: https://mastodon.social/users/regehr/statuses/113494669892003815
@regehr @pervognsen @zwarich Hah, another thing I hacked on in grad school! It would do online perf profiling to discover hot paths in the kernel (geared towards servers running relatively steady, homogeneous workloads), and then recompile a specialized kernel module containing all the code for the path(s) it decided to target with LTO doing hyper-aggressive inlining (including across speculatively devirtualized indirect calls between modules) to provide a single contiguous code path all the way from the syscall entry point down to all the relevant device drivers and then spliced it into the running system as a livepatch.
Had it been a few years or so later it might have seen better results due to the Spectre mitigations that later became necessary slowing down the "before" case more...