4 ms·
Does OpenBSD still have a giant lock? Genuinely curious, and it’s been years since I’ve looked at it.
by alberth 2y ago
Does OpenBSD still have a giant lock?
Genuinely curious, and it’s been years since I’ve looked at it.
- saagarjha 2y agoI still see spl references so I think so?
- daneel_w 2y agoMost of that is gone and the performance upswing is very noticable. A little bit of work remains.
- alberth 2y ago> It turns out that all the OpenBSD locks boiled down to a global netlock rw lock for the entire IPv4/IPv6 stack. I guess addressing the network stack is work that still remains? https://news.ycombinator.com/item?id=40076376 https://news.ycombinator.com/item?id=40076376
- daneel_w 2y agoA lot of the network stack has been unlocked (and parallelized) already. There are probably a few bits left to untangle in there. In my own experience, depending on what driver/MAC is used, the network performance has on average doubled in the last two years.
- IcePic 2y agoIt has, and it is used less and less. Not sure if any OS never does it anywhere, but the important part is to remove it from all "hot paths", not to remove it where its not relevant. Can't say if they still do, but FreeBSD for the longest time used to list the floppy driver being one of the modules using GiantLock and that was a problem for what I guess was about zero people. But if one asks fbsd devs if they still have it, they would have to answer yes, even if the rest of the OS runs super great without locks anywhere else, so the binary question of "is there somewhere something that for some time could possibly call the giant lock" isn't very interesting, but rather "will it do it for the tasks I imagine I will run on my machine?" and that would have to be a more fine-grained question with some research, just like the locks in the kernels are getting more and more fine-grained.