Re:Speeding up ELF relocations for store-based systems
by setheron on Monday May 06, 2024 @10:26PM
(#40281693)
my thinking:
40ms might matter if you consider the number of times a process might restart, the number of instances you run and on how many hosts. That could be considerable wasted cycles in aggregate. (i.e. cloud provider)
Also it's not only a function of how many shared libraries but how many symbols they each individually have as well -- also their symbol length as well.
Would it be nice to shave 60 ms off of every ffmpeg/mpv invocation? In isolation, sure, but considering the maintenance burden and potential inconsistencies I don't think it's worth it. Nix is supposed to ensure that the dependencies are always the same, but currently if something breaks somehow, the wrong version will be loaded or an error will be emitted, whereas with this optimization, it will crash or silently invoke the wrong functions which seems extremely difficult to debug.