1. 11
  1.  

  2. 4

    It warms the heart to know that some people push back against adding syscalls just to be convenient for one set of programs. Progress needs to have reasons and be reasoned about.

    Are minimal syscall OSes akin to RISC?

    1. 5

      Are minimal syscall OSes akin to RISC?

      Microkernels have minimal functionality and thus also very few system calls. In fact, some microkernels only have a single system call for inter-process communication.

      I’m not sure whether it’s useful to reduce the number of system calls in a big monolithic kernel. I think it might lead to a complex system call interface with system calls that perform multiple (possibly unrelated) functions. This is already reality, for example with the ioctl system call in Linux that is used for lots of very different tasks.

      1. 3

        RISC no longer has anything to do with a reduced instruction count, but instead reduced instruction complexity.

        1. 1

          Somewhat relevant to the orthogonality of instruction count/complexity: https://alastairreid.github.io/papers/sve-ieee-micro-2017.pdf

      2. 1

        KSM is an opt-in feature that is requested with madvise(); if the process in question doesn’t happen to make that call, there is no easy way to cause it to happen externally.

        If only there were some way to modify a program to call the right function. Someone should tell the linux folk about the wonders of open source.

        1. 3

          I can see the use for this. If you patch programs then there’s two problems: a) you’re now maintaining a fork of that program, which doesn’t scale well the more programs you need to patch, and b) you can’t centralize KSM policy in one point in the system. If you had a daemon doing remote madvise() then you could decide which processes get KSM in one configuration file. I do see your point though! I think it’s a tradeoff, like anything else.

        2. 1

          So this is essentially a lower-level, finer-grained way one would otherwise mmap two processes to the same shared file in memory?