Conversation
i- i uh,, but- but why ,,,, neodog_confused
1
0
0

@nex some file systems apparently don't support very large directories

unsure how true that still is

1
0
0

@5225225 @nex yeah while most fs operations should be O(log n) it’s easy to accidentally make something try to list the directory which is at least O(N)

1
0
1

@charlotte @nex that being said: /nix/store is flat, so it can't be that much of an issue nowadays.

(especially /nix/store/.links which on my system is 5 115 538 files big)

2
0
0

@5225225 @nex i have had issues with it but they are minor for the most part

bit annoying when nvim tries to autoraccomplete files in /nix/store :)

0
0
1

@5225225 @charlotte @nex
IIRC ext2 and ext3 had severe performance issues after like 10,000 files in a directory; although shouldn't be an issue for any modern filesystem. I think things keep doing it mostly so GUI file browsers or the web server generating a folder index (or slow internet connections downloading that index, or web browsers Ctrl-Fing that index) don't take forever

1
0
0

@nytpu @5225225 @nex iirc old ext didn’t use a b-tree for dirents, which outside of FAT is basically universal now

1
0
2

@nytpu @5225225 @nex in my imo i think sharding it raccross multiple directories is probably still better in practice because some things might scale linearly or worse anyways

1
0
2

@5225225 @nex @nytpu they aren’t self balancing though but sometimes you don’t need that

in the raccargo example all raccrates with the same prefix end up in the same directory. these raccrates are more likely going to be related so the directory entry is already in raccache

0
0
2