4 ms·
Yeah, totally fair. I mean it's relatively hard for me to conclude otherwise, but stuff is super complex, you never know. If not anything else, after all you ca
by anyfoo 4y ago
Yeah, totally fair. I mean it's relatively hard for me to conclude otherwise, but stuff is super complex, you never know. If not anything else, after all you can do link time optimization on the actual whole program, including its libraries. But whether that offsets it...
I thought about whether there was some quick evidence already, but nothing comes to mind (maybe someone's less blind to it than me now).
Maybe you could take some self-building Linux distribution like Gentoo, and hack it such that it links everything statically? Compare that against an equivalent unhacked Gentoo-installation by doing a few tasks, measuring wall clock for a good first estimate?
No idea how hard that would be in practice, especially with people mentioning that glibc does not really support that. So maybe it's actually easier with one of the BSDs, e.g. OpenBSD, which is also feasible to build completely from source because it is very self-contained, depending on how that stomachs static linking for everything.
I'd also not do it in a VM. While that's not necessarily completely invalid, it does seem to skew things pretty significantly, what with at least one whole other OS running as the hypervisor and all that.