What is kernel?





Kernel:

All the operating involving processes are controlled by a part of operating system called kernel or nucleus or core. In modern operating system the kernel is small portion of operating system but plays very important role in computer system. The kernel is interactive with the user mode or user program.
The kernel resides inside primary storage or ram when the computer is opened and controls the system. Other portion of operating system may reside in secondary storage and load in primary memory when needed.
The kernel gives services to the user programs or in depth gives services to the resources.  Kernel is responsible for accepting the interrupt to perform contain task, the user or resource or I/O device gives interrupt signal to kernel and kernel can process the interrupt. In multiuser system, the interrupt is directed to the processor by different user and processor gives service or controls all users, this environment is created by kernel. Here, processes are responsible for rapid response to resource as well as user. The main function of kernel is:-
a. Interrupt handling
b. Process creation and destruction.
c. In multiprocessing system, the control should transfer from one process to another that process is called switching of process.
d. It support file system
e. It support procedure call and return statement.

A Kernel contains different utilities which are used to control and manage computer resources. The utilities of a kernel are:

compiler:
Compiler and interpreter are used to translate high level language to machine understandable form. The compiler translates overall code into machine code. Debugging process is also performing this phrase. In compilation overall code is translate into machine code at a time. If any bug is found in a line at last all program in any line this will show at last. Two types of compiler are used quick-and-dirty compiler and continizing compiler. First compiler is fast and inefficient and second is slow but more efficient.

linker:
In early days, each and every instruction was written to solve the particular problems. even a complex instruction is coded into each machine language program but now a days the instructions can be reuse or instructions are reside into certain location they can be used into program due to this the length of program code will reduce. Large number of sub routine libraries is supplied so that programmers may use system supplied routines to perform common operations. Input and output in particular is normally handled by routine outside the user program. Therefore, machine language programs must normally be combined with other machine language programs to form useful execution unit. The linker links the program code with predefined sub routines. The program execution may be show due to linking. In linking stage, linker combines whatever programs required that loads them directly into primary storage to create an executable file.

Loader:
Programs must be place in primary storage in order to be executed. Associating instructions and data items with particular primary storage locations is an important task of kernel or operating system. This task is performed by sometimes user sometimes by translators and sometimes on the system program called a loader and sometimes on the operating system. The association of instruction and data items with particular storage locations is called binding. In machine language programming, binding is performed at coder section. The loader leads instruction and innate data into primary memory. There are two types of loader called absolute and relocating loader.
A loader is a program that places a program’s instruction and data items into primary storage locations. An absolute loader places instruction and data into the precise locations indicated in the machine language programs. But a relocating loader may load a program at various places in primary storage, depending on the availability of space in primary storage at load time.

shell:
It is the most important system program of operating system. It is a program which accepts user’s command from command line and executes it. A shell is not only the command interpreter and a line editor but also the language with variables, array, function and control statement. It is not graphic oriented. The shell user prompt $, %, # etc. to take a command. The shell carried out the system call editor, compiler, linker, command interpreter are not part of operating system or not part of kernel mode but play very important role in computer program. The shells provide the primary interface between user and operating system. When user log in computer, the shell is started up. It starts up by typing the prompt, or nay sign like $, # etc. and waiting for accepting user command.
In case dos, if two user type date, the shell creates the child process and takes the same program as the child. After completing the child process, it gives result or o/p and wait for another command.



Related posts:

  1. Introduction to operating system Operating System: An operating system is a collection of system...
  2. Operating System Structure operating system structure: An operating system might have many structure....
  3. Types of operating systems An operating system can also be divided into many types...