!lymvtcwDJ7ZA9Npq:lix.systems

Lix Development

420 Members
(Technical) development of Lix, the package manager, a Nix implementation. Please be mindful of ongoing technical conversations in this channel.139 Servers

Load older messages


SenderMessageTime
22 Feb 2026
@raitobezarius:matrix.orgraitobezariusIf you ack, your reviewer is the next one who needs to act23:16:01
@raitobezarius:matrix.orgraitobezariusWhen it should be you who should act 23:16:14
@vczf:matrix.orgvczfGotcha23:18:24
23 Feb 2026
@sky1e:mildlyfunctional.gaysky1e I think besadii had a spurious failure checking https://gerrit.lix.systems/c/lix/+/5250. Can someone poke it for me? 19:32:07
@sky1e:mildlyfunctional.gaysky1ety!20:08:31
24 Feb 2026
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)Would love to hear some thoughts on https://github.com/NixOS/nix/pull/15327. I recall chatting about symbol table order shenanigans and this seems to be an ok-ish solution to the f-ed up situation. Evaluation order already changes in practice, so making it more defined wouldn't be that bad I supppose?00:44:36
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)* Would love to hear some thoughts on https://github.com/NixOS/nix/pull/15327. I recall chatting about symbol table order shenanigans and this seems to be an ok-ish solution to the f-ed up situation. Evaluation order already changes in practice (and thus symbol table), so making it more defined wouldn't be that bad I supppose?00:44:57
@tiktorchic18:matrix.orgTikTorchic18 joined the room.03:47:34
@piegames:flausch.socialpiegamesAny alternative solutions to this?07:20:52
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)The only thing that comes to mind is to keep the status quo. One way or another some canonical order would have to be used I suppose. The cost of sorting doesn’t seem to matter that much, but there could be a way to amortise the cost by memoising the sorted order for commonly used attribute set shapes09:53:07
@k900:0upti.meK900Maybe it's time to make attrsets btreemaps after all09:53:53
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)
In reply to @k900:0upti.me
Maybe it's time to make attrsets btreemaps after all
Not sure about the memory usage there… They did use to be just a std::map before 2010 (circa 0.16)
09:54:45
@k900:0upti.meK900 I mean it shouldn't be that much bigger but it will also undo the stacking trick 09:55:14
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)TVL’s fork of 2.3 did play around with that too09:55:16
@k900:0upti.meK900I wonder if there's like A Paper somewhere09:56:39
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)
In reply to @k900:0upti.me
I mean it shouldn't be that much bigger but it will also undo the stacking trick
It would add quite a bit of pointer chasing even with a high degree of internal nodes too. And memory usage would probably jump by a lot. If the order is defined in the strings then lookup then also does string comparisons
09:57:25
@k900:0upti.meK900I mean btrees shouldn't be that pointer chasey09:58:06
@k900:0upti.meK900With big enough node sizes09:58:12
@k900:0upti.meK900I think the rustc people found that it's basically even perf wise09:58:32
@k900:0upti.meK900When rustc got switched from hashmaps to btreemaps in a bunch of places09:58:41
@k900:0upti.meK900For r11y09:58:43
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)I mean, if somebody does the crazy and switches to be a better representation that’d be great. FWIW there’s an immutable CHAMP implementation in immer that connor baker tried using for attrsets10:04:28
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)But that’s not exactly the thing we want for a well-defined lexical order. For now sorting on demand doesn’t seem to cost too much to be a blocker for fixing the impurity10:06:48
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)* I mean, if somebody does the crazy and switches to a better representation that’d be great. FWIW there’s an immutable CHAMP implementation in immer that connor baker tried using for attrsets10:10:21
@piegames:flausch.socialpiegames
In reply to @piegames:flausch.social
Any alternative solutions to this?
How about always evaluating all values in comparisons, so that eval order does not matter because it's not as lazy?
10:17:35
@piegames:flausch.socialpiegamesOr how about treating values that throw as incomparable instead of propagating it up and beyond the comparison?10:18:22
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)
In reply to @piegames:flausch.social
Or how about treating values that throw as incomparable instead of propagating it up and beyond the comparison?
It’s not really only about throw expressions though. Forcing all values would be a workable, though a more radical solution
10:20:49
@piegames:flausch.socialpiegamesDo we have numbers on how many comparisons even happen in Nixpkgs? My assumption would be that it's not that common and that most instances already fast forward because of the pointer comparison10:23:30
@xokdvium:matrix.orgSergei Zimmerman (xokdvium)Something like ~1M that doesn't shortcircuit and falls through to per-attr equality11:19:04
@xokdvium:matrix.orgSergei Zimmerman (xokdvium) For all drv-paths via -qaP --drv-path for x86_64-linux 11:19:44

Show newer messages


Back to Room ListRoom Version: 10