| 30 Jul 2022 |
Alyssa Ross | (especially statically linked, or rpath-optimised lns) | 09:44:55 |
DavHau | In reply to @qyliss:fairydust.space so (just as an example) I'd expect you could run many lns before Python has started up Good point. Having proper data on this might be interesting. I might do some benchmarks if I find time. | 10:03:31 |
DavHau | On the other hand. Performance is only then a concern when we talk about large numbers of of operations. And anything that doesn't launch processes will always be significantly faster in that scenario. | 10:19:08 |
Alyssa Ross | Those large numbers of operations tend to be contained in configure scripts / makefiles anyway | 10:20:16 |
Alyssa Ross | tbh I think optimising stdenv for speed is not going to be worth it | 10:20:43 |
Alyssa Ross | because I highly doubt anybody is bottlenecked on stdenv as opposed to the builds themselves | 10:21:02 |
Alyssa Ross | When I'm waiting hours for a build, it's not because stdenv is slow. | 10:21:18 |
DavHau | I agree. No need for optimization, but also no need to be worried about overhead in launching phases with proper interfaces. | 10:50:51 |
| Sandro 🐧 changed their display name from Sandro to Sandro 🐧. | 13:17:13 |
| 1 Aug 2022 |
| better_sleeping joined the room. | 09:11:58 |
| better_sleeping left the room. | 09:12:24 |
John Ericson | https://github.com/NixOS/nixpkgs/pull/183967 FYI here is example of some small low hanging cleanups, from the impromptu bootstrapping call | 14:50:48 |
John Ericson | not saying we can end up anywhere interesting with such baby steps alone, but it can be nice to go spelunking / do the archeology | 14:51:10 |
Wanja Hentze | In reply to @qyliss:fairydust.space fork+exec overhead is trivial compared to e.g. interpreter startup time for most languages side note: nix should probably not use fork+exec to spawn children, as it has a time overhead proportional to the amount of memory mapped by the parent process (which can be quite large in the case of Nix) you probably know this already, and maybe nix does it anyway. I just take any opportunity I can to shill posix_spawn - which does not have this problem. | 17:43:13 |
Wanja Hentze | In reply to @qyliss:fairydust.space fork+exec overhead is trivial compared to e.g. interpreter startup time for most languages * side note: nix should probably not use fork+exec to spawn children, as it has a time overhead proportional to the amount of memory mapped by the parent process (which can be quite large in the case of Nix) you probably know this already, and maybe nix does not even do this anyway. I just take any opportunity I can to shill posix_spawn - which does not have this problem. | 17:43:27 |
Wanja Hentze | shells like bash mostly still due it this way for cursed backcompat reasons but you can really do better | 17:45:20 |
Wanja Hentze | * shells like bash mostly still do it this way for cursed backcompat reasons but you can really do better | 17:45:27 |
Wanja Hentze |  Download Screenshot from 2022-08-01 19-45-36.png | 17:46:29 |
Wanja Hentze | old-ish graph from https://www.microsoft.com/en-us/research/uploads/prod/2019/04/fork-hotos19.pdf | 17:46:50 |
Alyssa Ross | Nix spawns a negligible number of processes — almost all processes in a build will come from a shell or build system. | 17:47:07 |
Alyssa Ross | the only thing Nix itself spawns is the shell that runs the builder | 17:47:22 |
Alyssa Ross | (and stuff like git in fetchers, of course) | 17:47:29 |
Alyssa Ross | but yes, posix_spawn is the way to go when you have to spawn a process | 17:47:48 |
Wanja Hentze | right, but I thought the discussion was about changing this, maybe? | 17:47:57 |
Wanja Hentze | by ripping out the shell or something? | 17:48:04 |
Wanja Hentze | I must admit I didn't read all of it | 17:48:11 |
Robert Hensing (roberth) | nix doesn't know about the build script. Only about the builder (an executable) and its args | 17:56:22 |
Robert Hensing (roberth) | In reply to @qyliss:fairydust.space tbh I think optimising stdenv for speed is not going to be worth it NixOS produces many small derivations. It may be felt when the software has been built but the configuration changes. | 18:00:59 |
Robert Hensing (roberth) | unlike a mass rebuild, changing configuration is expected to be somewhat instant, involving multiple "stdenv" executions | 18:02:03 |
Robert Hensing (roberth) | In reply to @profpatsch:augsburg.one (isomorphic in the sense of isomorphic javascript) you'll still need some interface between the two evaluators. Serializing functions is a thorny problem. Without functions, the interface is already effectively JSON. | 18:03:50 |