Hybrid (micro)kernels

By: pgerassi (gerassimoff.delete@this.sbcglobal.net), August 16, 2007 7:41 pm
Room: Moderated Discussions
philt (ptay1685@bigpond.net.au) on 5/16/06 wrote:
>Linus Torvalds (torvalds@osdl.org) on 5/15/06 wrote:
>>philt (ptay1685@bigpond.net.au) on 5/14/06 wrote:
>From working over 30 years in IT as a software developer, one thing I have learnt
>is that, all things being equal, techniques that make it easy and quick to write
>code usually rebound on you later on. Such code is much harder to maintain, and
>with every succesive modification the system gets more and more difficult to handle
>- eventually you have to do a complete rewrite.
This is a false assumption. Well documented code is easier to maintain and if maintained with the same adherence to documentation, can be kept through major changes without a complete rewrite. The trouble comes from defining "well documented". Lots of experience helps make that definition.

>Modularising code becomes essential with anything other than small systems, and
>modularisation incurs overheads and is always harder to write - often much harder
>- but the rewards over the long term more than justify this more "proper" approach.
Modularization is one common way of accomplishing this, but it isn't the only way. That it frequently works though helps. It also is frequently taken too far in practice.

>Object oriented techniques of programming involve many of the same tradeoffs as
>the microkernel approach, which in essence is simlar to what happens in a microkernel.
>The object interfaces become a kind of bottleneck which can be difficult to handle
>and incur performance penalties. But once code becomes sufficiently complex, these
>kinds of techniques are neccesary in order to bring order to what is potentially
>a chaotic system. This explains why object oriented programming has come into being.
>The compexity of modern software demands this kind of structuring in order to make
>software that has high reliability and maintainability.
Sorry, this is also a false assumption. Object oriented programming is just one method of reducing complexity. It depends on the problem or area being addressed. There are other methods equally as valid in other cases. Functional decomposition is another. Reusable code is a third.

I know of one long running easy to maintain complex program using well documented reusable spaghetti code. It was extremely reliable and was changed with more reusable spaghetti calling older reusable spaghetti. It consistently beat out modular OO code from other designers for performance and reliability. The spaghetti made it fast. The reusability made it reliable. And the design and documentation made it easy to maintain.

>Your arguments seem to be mainly pragmatic and your viewpoint is perhaps primarily
>that of the coder. A coder seeks ways to reduce complexity in order to make writing
>the code more manageable. However what favours the individual coder may not favour
>the system they are writing. Many other people may pay the price in terms of testing and bug fixing.
If the coder also does the testing and bug fixing, it gets taken into consideration as well. And if the designer also had to use the program, many poor design decisions get revoked.

>I have to say that the existence of Minix-3 and other micokernel systems tends
>to suggest that such techniques can actually work. In particular Minix-3 seems to
>have been arrived at with comparitively little effort (notwithstanding its lack of certain features).
It also could mean that the target was too narrowly defined.

>I personally much prefer reliability to raw performance, and the perfromance penalties
>of microkernel systems seem rather insiginificant in the face of 4Ghz multi-cored
>cpu's with 4 megs of level2 cache on board.
I have seen too many poor designs depend on such assumptions. Too many "reliable" systems turned out to have easy to find vunerabilities. And rock solid systems that worked with 1 to N users and blew up when user N+1 was added.

I too like reliability, but I won't pay for it by getting a little more reliability with 1/10th the performance. At that point, I can run it three times, take the result that matches at least twice and still get more reliability than the first solution with more overall performance.

>I guess also as a person who is an end user of an operating system and not a developer
>of one, I dont much care if the developers have had to put in more effort to achieve
>the results (selfish I know). Of course if developing a microkernel is so difficult
>that no developers will go near one then I will care about that, but fortunately
>that does not seem to be the case (Hurd, Mini-3, Coyotos etc).
Each may be usable in a limited scope.

>I agree that the microkernel idea is very appealing and elegant, and I know that
>there is a large gulf between theory and practice, but I strongly feel so far that
>the microkernel approach has something to offer in the area of reliability and I
>do not see any insurmountable negatives that negate that advantage. A bit of performance
>loss, so what. Just get a faster cpu and more memory. Not a problem.
This is another false assumption. The microkernel approach may not be scalable. The design has many inherent bottlenecks. Most microkernels have a problem with Amdahl's Law. They work well with a single fast CPU core, but bog down when faced with many "slow" CPU cores.

>Also it is interesting to note that virtually all modern operating systems run
>applications in separate memory spaces. I do not see any reason why the reason for
>doing this is any different from that which suggests it would also be best to run
>different op sys services also in separate memory spaces.
Copying large data sets between the memory spaces comes immediately to mind. All you have to do is look at the typical GPU to see why that is bad. A GFX8800 would run worse than a GF6200.

>If the only reason not to do so is that it adds complexity to the code, then this
>does not sound like a very good reason for not doing it. If the designers of CPU's
>shunned complexity we would still be running 100 Mhz 8086's rather than the current CPU behemoths.
That isn't even the best reason. A modern OO superscalar CPU doesn't use object oriented designs to do its job. Its more like a cooperative set of functional units sharing data to get the most done reliably in the shortest amount of time. To do that, it breaks most of your rules for complex programming.

The 8086 breaks fewer of your rules. It has much lower performance as well.

< Previous Post in ThreadNext Post in Thread >
TopicPosted ByDate
Hybrid (micro)kernelsTzvetan Mikov2006/05/08 04:41 PM
  Hybrid (micro)kernelsS. Rao2006/05/08 06:14 PM
  Hybrid (micro)kernelsBill Todd2006/05/08 06:16 PM
    Hybrid (micro)kernelsTzvetan Mikov2006/05/08 07:21 PM
      Hybrid (micro)kernelsnick2006/05/08 07:50 PM
      Hybrid (micro)kernelsBill Todd2006/05/09 01:26 AM
        There aren't enough words...Rob Thorpe2006/05/09 02:39 AM
          There aren't enough words...Tzvetan Mikov2006/05/09 03:10 PM
            There aren't enough words...Rob Thorpe2006/05/15 12:25 AM
        Hybrid (micro)kernelsTzvetan Mikov2006/05/09 11:17 AM
          Hybrid (micro)kernelsBill Todd2006/05/09 04:05 PM
  Hybrid (micro)kernelsrwessel2006/05/08 11:23 PM
    Hybrid kernel, not NTRichard Urich2006/05/09 06:03 AM
      Hybrid kernel, not NT_Arthur2006/05/09 07:06 AM
        Hybrid kernel, not NTRob Thorpe2006/05/09 07:40 AM
          Hybrid kernel, not NT_Arthur2006/05/09 08:30 AM
            Hybrid kernel, not NTRob Thorpe2006/05/09 09:07 AM
              Hybrid kernel, not NT_Arthur2006/05/09 09:36 AM
                Linux vs MacOSX peformance, debunked_Arthur2006/05/18 07:30 AM
                  Linux vs MacOSX peformance, debunkedRob Thorpe2006/05/18 08:19 AM
                    Linux vs MacOSX peformance, debunkedAnonymous2006/05/18 12:31 PM
        Hybrid kernel, not NTLinus Torvalds2006/05/09 08:16 AM
          Hybrid kernel, not NTAndi Kleen2006/05/09 02:32 PM
            Hybrid kernel, not NTmyself2006/05/09 03:24 PM
              Hybrid kernel, not NTmyself2006/05/09 03:41 PM
              Hybrid kernel, not NTBrendan2006/05/09 05:26 PM
                Hybrid kernel, not NTLinus Torvalds2006/05/09 08:06 PM
                  Hybrid kernel, not NTBrendan2006/05/13 01:35 AM
                    Hybrid kernel, not NTnick2006/05/13 04:40 AM
                      Hybrid kernel, not NTBrendan2006/05/13 09:48 AM
                        Hybrid kernel, not NTnick2006/05/13 07:41 PM
                          Hybrid kernel, not NTBrendan2006/05/13 09:51 PM
                            Hybrid kernel, not NTnick2006/05/14 05:57 PM
                              Hybrid kernel, not NTBrendan2006/05/14 10:40 PM
                                Hybrid kernel, not NTnick2006/05/14 11:46 PM
                                  Hybrid kernel, not NTBrendan2006/05/15 04:00 AM
                                    Hybrid kernel, not NTrwessel2006/05/15 07:21 AM
                                      Hybrid kernel, not NTBrendan2006/05/15 08:55 AM
                                        Hybrid kernel, not NTLinus Torvalds2006/05/15 09:49 AM
                                          Hybrid kernel, not NTnick2006/05/15 04:41 PM
                                          Hybrid kernel, not NTtony roth2008/01/31 02:20 PM
                                    Hybrid kernel, not NTnick2006/05/15 06:33 PM
                                      Hybrid kernel, not NTBrendan2006/05/16 01:39 AM
                                        Hybrid kernel, not NTnick2006/05/16 02:53 AM
                                          Hybrid kernel, not NTBrendan2006/05/16 05:37 AM
                  Hybrid kernel, not NTAnonymous2008/05/01 10:31 PM
                    Following the structure of the treeMichael S2008/05/02 04:19 AM
                      Following the structure of the treeDean Kent2008/05/02 05:31 AM
                        Following the structure of the treeMichael S2008/05/02 06:02 AM
                        Following the structure of the treeDavid W. Hess2008/05/02 06:48 AM
                          Following the structure of the treeDean Kent2008/05/02 09:14 AM
                            Following the structure of the treeDavid W. Hess2008/05/02 10:05 AM
                              LOL!Dean Kent2008/05/02 10:33 AM
                              Following the structure of the treeanonymous2008/05/02 03:04 PM
                                Following the structure of the treeDean Kent2008/05/02 07:52 PM
                                Following the structure of the treeFoo_2008/05/03 02:01 AM
                                  Following the structure of the treeDavid W. Hess2008/05/03 06:54 AM
                                    Following the structure of the treeDean Kent2008/05/03 10:06 AM
                                      Following the structure of the treeFoo_2008/05/04 01:06 AM
                                        Following the structure of the treeMichael S2008/05/04 01:22 AM
            Hybrid kernel, not NTLinus Torvalds2006/05/09 05:19 PM
              Microkernel Vs Monolithic KernelKernel_Protector2006/05/09 09:41 PM
                Microkernel Vs Monolithic KernelDavid Kanter2006/05/09 10:30 PM
                  Sigh, Stand back, its slashdotting time. (NT)Anonymous2006/05/09 10:44 PM
                  Microkernel Vs Monolithic Kernelblah2006/05/12 08:58 PM
                  Microkernel Vs Monolithic KernelRob Thorpe2006/05/15 01:41 AM
          Hybrid kernel, not NTAnalGuy2006/05/16 03:10 AM
            Theory versus practiceDavid Kanter2006/05/16 12:55 PM
              Distributed algorithmsRob Thorpe2006/05/17 12:53 AM
              Theory versus practiceHoward Chu2006/05/17 02:54 AM
                Theory versus practiceJS2006/05/17 04:29 AM
          Play online poker, blackjack !!! Gamezonex2007/08/16 01:49 PM
  Hybrid (micro)kernelsphilt2006/05/14 09:15 PM
    Hybrid (micro)kernelsLinus Torvalds2006/05/15 08:20 AM
      Hybrid (micro)kernelsLinus Torvalds2006/05/15 11:56 AM
        Hybrid (micro)kernelsRob Thorpe2006/05/16 01:22 AM
          Hybrid (micro)kernelsrwessel2006/05/16 11:23 AM
            Hybrid (micro)kernelsRob Thorpe2006/05/17 12:43 AM
              Hybrid (micro)kernelsrwessel2006/05/17 01:33 AM
                Hybrid (micro)kernelsRob Thorpe2006/05/19 07:51 AM
                  Hybrid (micro)kernelsrwessel2006/05/19 12:27 PM
      Hybrid (micro)kernelstechIperson2006/05/15 01:25 PM
      Hybrid (micro)kernelsmas2006/05/15 05:17 PM
        Hybrid (micro)kernelsLinus Torvalds2006/05/15 05:39 PM
          Hybrid (micro)kernelsColonel Kernel2006/05/15 09:17 PM
            Hybrid (micro)kernelsWink Saville2006/05/15 10:31 PM
              Hybrid (micro)kernelsLinus Torvalds2006/05/16 10:08 AM
                Hybrid (micro)kernelsWink Saville2006/05/16 09:55 PM
          Hybrid (micro)kernelsrwessel2006/05/16 11:31 AM
            Hybrid (micro)kernelsLinus Torvalds2006/05/16 12:00 PM
        Hybrid (micro)kernelsBrendan2006/05/16 01:36 AM
        Hybrid (micro)kernelsPaul Elliott2006/09/03 08:44 AM
          Hybrid (micro)kernelsRob Thorpe2006/09/04 09:25 AM
      Hybrid (micro)kernelsphilt2006/05/16 12:55 AM
        Hybrid (micro)kernelspgerassi2007/08/16 07:41 PM
  Another questionable entry on Wikipedia?Chung Leong2006/05/18 10:33 AM
  Hybrid (micro)kernelsisrael2006/05/20 04:25 AM
    Hybrid (micro)kernelsRob Thorpe2006/05/22 08:35 AM
Reply to this Topic
Body: No Text
How do you spell purple?