3 ms·
> OS X and Windows always had a hybrid architecture since the beginning "Hybrid architecture" is a PR exercise. These are monolithic designs with a better mark
by tialaramex 4y ago
> OS X and Windows always had a hybrid architecture since the beginning
"Hybrid architecture" is a PR exercise. These are monolithic designs with a better marketing team.
Imagine if somebody tells you their new programming language has a "hybrid" numeric type. It has all the advantages of floating point numbers, yet none of the disadvantages of the integer types. Wow!
Wait, hang on, let's look a bit more closely, those are floats. They've just described floats, but used some semantic sleight of hand to claim they're a "hybrid" numeric type.
- pjmlp 4y agoSome like to call it a PR exercise. Others enjoy that there is some effort in place to have RPC comunnication between kernel modules instead of direct function calls, a hard push for third party drivers only to exist in userspace and a standard ABI for extensions. I rather see the progress side, even if partial, than hold to legacy designs. See I could also call a PR exercise to safe languages that depend on using unsafe everywhere on their lower layers, maybe they aren't safe after all. And yet we know that isn't the case.
- tialaramex 4y ago> See I could also call a PR exercise to safe languages that depend on using unsafe everywhere on their lower layers, maybe they aren't safe after all. Although it's easier to look at what's technically different in a language like Rust, probably more important is a philosophical difference and the resulting community. Let's use an example I gave recently to my line manager (who is technical but not an excellent programmer): Sort stability. C++ says, here's sort function, and in the documentation by the way this is unstable, if you need a stable sort that's named stable_sort(); Rust says, here's a sort function, if you know enough to know you don't need a stable sort, there's an unstable_sort() function which is faster [and exists in tiny embedded systems since it doesn't need an allocator]. Unstable sort isn't unsafe (well, it is in C++ but that's C++ for you, it's not a fact about unstable sorting) but philosophically it violates the principle of least surprise as your default sort() function, and that would be a foot gun. Go has an "unsafe" library with the dangerous stuff in it. But unlike Rust it doesn't have the safe philosophy and so e.g. as we saw recently Go doesn't feel the need to even warn you that things aren't thread safe and some Go proponents think you're crazy if you expected anything to exhibit thread safety. If I saw a clear RPC philosophy in an OS like Windows I'd mostly go along with what you're saying. If when I looked at Windows I saw a bunch of loosely coupled systems communicating using a well defined protocol, I'm on board that's really not just a monolithic kernel. But what I see instead is mostly layers smeared on top of a monolithic kernel, some of which pretend to be RPC but are really just doing a syscall to some kernel code where the work happens. The language of RPC is used in some places, but the philosophy is largely absent.
- pjmlp 4y agoUnless you have mastered all editions of Windows Internals, MAC OS X Internals: A Systems Approach, MacOS and iOS Internals, Mac OS X and iOS Internals: To the Apple's Core books. Or having been a former Microsoft or Apple employee working on kernel stuff, then I could eventually value the opinion how fake they happen to be. Yet somehow I get the feeling, from both of us, only I have delved into such internals.
- Pasta123 4y agoSeems to me that the notion suppose to be "Hybrid is basically an inferior monolithic", after all, if most functions (even without drivers) were still in the kernel, wouldn't it be just another monolithic?
- tialaramex 4y agoAh, I knew I would get one of them wrong, and then didn't go back to check, so C++ indeed has std::ranges::sort() and std::ranges::stable_sort() However Rust's [T].sort() is paralleled by [T].sort_unstable() That is, I just got the Rust names in the wrong order. The orthography is different because how these work under the hood is very different, but that's not important here.
- Koshkin 4y ago> using unsafe everywhere But this is OK, as long as Unsafe is a monad!
- marcodiego 4y ago> "Hybrid architecture" is a PR exercise. These are monolithic designs with a better marketing team. This is similar to what I heard from other people about NT. IIUC, NT was called hybrid because it allowed something similar to loadable modules.
- pjmlp 4y agoNope, NT is hybrid, because many drivers exist in userspace, and at kernel level RPC are used to call across kernel modules, instead of direct calls. https://en.m.wikipedia.org/wiki/Local_Inter-Process_Communication https://en.m.wikipedia.org/wiki/Local_Inter-Process_Communic... Additionally, since Window 10, all critical modules are sandboxed, and running under hypervisor control when hardware support is present. https://www.microsoft.com/security/blog/2020/07/08/introducing-kernel-data-protection-a-new-platform-security-technology-for-preventing-data-corruption/ https://www.microsoft.com/security/blog/2020/07/08/introduci... This is something that Windows 11 requires, secure kernel hardware requirements aren't optional. Calling it a marketing exercise only reveals a lack of understanding about the subject, and possibly some bias as well.
- marcodiego 4y ago> Calling it a marketing exercise only reveals a lack of understanding about the subject, and possibly some bias as well. Definitely my case.