Micro-kernel architecture based operating system for desktop users? - operating-system

Can we have Operating system with micro-kernel architecture targeted on desktop users? I have read here on this website that older micro-kernel can be 50% slower than Monolithic kernel, while later version like L4 were only 2% or 4% slower than the Monolithic kernel. L4 kernel is very famous for its performance.
Why don't we have an operating system based on micro-kernel architecture targeted on desktop users? Can we have such operating systems in future?

Existing OSes like Windows, Linux have a huge ecosystem thus most resources go into them. However, there are projects to micro kernel base system and there's a huge use in special use cases. It takes time and work to create a general purpose OS - and the practical benefit is quite low for most user, as then wont ever notice what OS core they are actually using.
You may give this a try: https://genode.org
Or watch this: https://de.wikipedia.org/wiki/Google_Fuchsia

Related

What kernel type does the RTOS eCos use?

From my research I cannot find what kernel type is being used in eCos, such as monolithic or micro-kernel. All I could find from my research is that the kernel is a real-time one or websites just describe it as the eCos kernel, does this mean it is a custom made kernel?
What I know about eCos is that it is a hard RTOS although is somewhat vulnerable in terms of security, uses priority, queue based scheduling.
A micro-kernel is:
... the near-minimum amount of software that can provide the mechanisms
needed to implement an operating system (OS). These mechanisms include
low-level address space management, thread management, and
inter-process communication (IPC).
(Wikipedia 11 Dec 2018)
The eCos kernel is described in its Reference Manual thus:
It provides the core functionality needed for developing
multi-threaded applications:
The ability to create new threads in the system, either during startup
or when the system is already running.
Control over the various threads in the system, for example
manipulating their priorities.
A choice of schedulers, determining which thread should currently be
running.
A range of synchronization primitives, allowing threads to interact
and share data safely.
Integration with the system's support for interrupts and exceptions.
It is quite clearly by comparison of these descriptions a micro-kernel. Other services provided by eCos such as file-systems, networking and device drivers are external and separable from the kernel. That is to say, you can deploy the kernel alone without such services and it remains viable.
In a monolithic kernel, these services are difficult or impossible to separate as they are an intrinsic part of the whole. Unlike eCos mand most other RTOS they do not scale well to small hardware platforms common in embedded systems. Monolithic kernels are suited to desktop and general purpose computing platforms, because the platforms themselves are monolithinc - a PC without a filesystem, display, keyboard etc, is not really viable, whereas in an embedded system that is not the case.
While Linux, and even Windows are used in embedded systems, a micro-kernel is deployable on platforms with a few tens of kilo-bytes of memory, whereas a minimal embedded Linux for example requires several mega-bytes and will include a great deal of code that your application may never use.
Ultimately the distinction is perhaps irrelevant, as is the terminology. It is what it is. You do not choose your kernel or OS on this criteria, but rather whether it provides the services you require, runs on your target, and fits in the available resource.
I think it is a monolithic kernel. If you review this page: http://ecos.sourceware.org/getstart.html
It is used instead of linux kernel and linux kernel support monolithic kernels. In addition, if it was a micro kernel , they would highlight the kernel type like QNX Kernel type which is micro kernel

Does an operating system design for specific processors or all types of processors?

I need to know Does a operating system design for specific processors category?
and also can any operating system run on any microprocessor?
Generally speaking, an operating system is not designed for a specific processor; though some do make assumptions about the hardware and computer system over all that might not be available in all systems. That said, for an operating system to run on a partical architecture, there is usually code that performs some specific, critical functions that is implemented for a specific architecture, frequently being written in assembly (I know of no OS that doesn't do this). To enable a new architecture, this code needs to be rewritten for the new machine, so that means new assembly most of the time. As mentioned in the comments, there are operating systems that only run on a single architecture like Windows, while others have these specific components for a number of architectures and thus can run on a number of processors like Linux. Note however the same exactly binary will not run across architectures, the operating system needs to be rebuilt for each architecture and possibly even for the same architecture if the system itself is different enough (as can be the case with some small MCUs).
So to answer your two questions directly: no, an OS is not uaually designed for a specific processor, and no, any OS cannot run on any processor.
Historically, operating systems have been designed for specific hardware. In some cases, such as eunuchs, the system was reworked so that it could be ported to multiple systems.
M$ ported Windoze to the Alpha processor in order to placate Digital and avoid lawsuits.
[C]an any operating system run on any microprocessor?
No.

Real time kernel vs real time OS

When reading the documentation of BLE chip from a semiconductor manufacturer that there is a small real time kernel on board, not OS. This is probably just a stupid question, but what would be the difference between a full fledged RTOS vs a real time kernel in such a scenario.
There are a variety of opinions on that question. One, held by systems programmers and the like, is that an OS kernel is a minimal set of services to abstract the underlying computer hardware, making it easier to write an OS or even applications on the machine. OS kernels typically operate in their own space, separate from user space where the rest of the OS (or even applications) reside. There is also the concept of a microkernel (and nanokernel), which is intended specifically to serve higher level (e.g., user space) OS services--although different microkernels partition OS services differently in kernel vs. user space. Check Wikipedia as a start (although some of its related entries have some factual errors).
Sometimes the embedded computing community refers to a kernel as a minimal OS, expecting applications, not more OS functionality, to use the kernel.
This may seem like an insignificant distinction, but it does effect the design and implementation of the kernel.

What kind of kernel does MS Windows have?

I saw a question on Linux Kernel. While reading that I had this doubt.
The Windows NT branch of windows has a Hybrid Kernel. It's neither a monolithic kernel where all services run in kernel mode or a Micro kernel where everything runs in user space. This provides a balance between the protection gained from a microkernel and the performance that can be seen in a monolithis kernel (as there are fewer user/kernel mode context switches).
As an example, device drivers and the Hardware Abstraction layer run in kernel node but the Workstation service runs in user mode. The wikipedia article on Hybrid Kernels has a good overview.
The Windows Internals book gives an explanation for the hybrid approach
... The Carnegie Mellon University Mach
operating system, a contemporary
example of a microkernel architecture,
implements a minimal kernel that
comprises thread scheduling, message
passing, virtual memory, and device
drivers. Everything else, including
various APIs, file systems, and
networking, runs in user mode.
However, commercial implementations of
the Mach microkernel operating system
typically run at least all file system,
networking, and memory management
code in kernel mode. The reason is
simple: the pure microkernel design is
commercially impractical because it’s
too inefficient.
According to Wikipedia it's a Hybrid kernel. Which may or may not be just marketing speak for about the same as a monolithic one. The graphic on the latter page does make some things clearer, though.
Most importantly, almost no program on Windows uses the kernel API directly. And the complete Windows API subsystem resides in user space which is a rather large part of the OS as we see it. And in more recent versions Microsoft began to pull more and more device drivers from kernel space into user space (which is especially a good idea with certain drivers, such as for video cards which are probably as complex as an operating system on their own).
hyru hybrid kernel is the name of the Kernel that Windows systems after Windows 98, before that it was a GUI overlaid on DOS using a monolithic Kernel.

What is the difference between an OS and a Framework?

I recently posted a question about Azure... is it really an OS? I understand the technical details, and I got a lot of fuzzy answers... I really want to know... what do you think is the difference between an OS and a Framework?
Just for reference, Azure will be built on top of Hyper-V servers and the virtual machines will be running vanilla Windows Server 2008. It will run services that creates a cloud on top of the many virtual machines which is called Azure. Windows is calling Azure an OS.
I am trying to understand how to define the difference between an OS and a framework.
Operating System: The infrastructure software component of a computer system
Framework: A re-usable design for a software system (or subsystem).
By these definitions it seems to me, that an operating system can be built using a framework, and a framework can be built to interact with an operating system.
Singularity is an example of an experimental OS that is built using managed code.
Framework is a very broad term, it can be used to describe many types of subsystems. It could even describe an operating system.
Operating System is more specific, it implies facilitation of interaction with a computers or group of computers hardware layer, through the use of human user interfaces. I think Azure fits this description.
It's up to marketing - I don't think the terms have a definite meaning any more.
Is a JVM a framework?
What if it's running on a raw uC or even an FPGA - is it an OS?
An OS is the thing that directly interfaces with the machine, be it virtual or real. It has to expose syscalls that handle input devices, output devices, sound, networking, and all the other things that we take for granted these days. It also often provides some kind of UI which uses these services to make it easy to use/useful for an end-user. It needs to have device drivers to work with video cards, sound cards, etc. (Once again, these can be virtualized).
A framework is... something built on top of the OS. It, too, exposes an API, but they are often not so low-level as the one the OS exposes.
frameworks provide api contracts that oses usually don't - meaning they sit atop the os, hide and manage the differences, and consequently give you that platform independence goodness that can broaden our target audience
A framework thought to be as a development environment,a helping platform for further developments and you can work additively to create some other application using components of framework, while OS is system software is an environment to operate a system.