
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 2003 Articles for Operating System

21K+ Views
Multithreading allows the execution of multiple parts of a program at the same time. These parts are known as threads and are lightweight processes available within the process. Therefore, multithreading leads to maximum utilization of the CPU by multitasking.The main models for multithreading are one to one model, many to one model and many to many model. Details about these are given as follows −One to One ModelThe one to one model maps each of the user threads to a kernel thread. This means that many threads can run in parallel on multiprocessors and other threads can run when one ... Read More

29K+ Views
Mutex and Semaphore both provide synchronization services but they are not the same. Details about both Mutex and Semaphore are given below −MutexMutex is a mutual exclusion object that synchronizes access to a resource. It is created with a unique name at the start of a program. The Mutex is a locking mechanism that makes sure only one thread can acquire the Mutex at a time and enter the critical section. This thread only releases the Mutex when it exits the critical section.This is shown with the help of the following example −wait (mutex); ….. Critical Section ….. signal (mutex);A ... Read More

214K+ Views
Semaphores are integer variables that are used to solve the critical section problem by using two atomic operations, wait and signal that are used for process synchronization.The definitions of wait and signal are as follows −WaitThe wait operation decrements the value of its argument S, if it is positive. If S is negative or zero, then no operation is performed.wait(S) { while (S

13K+ Views
Process communication is the mechanism provided by the operating system that allows processes to communicate with each other. This communication could involve a process letting another process know that some event has occurred or transferring of data from one process to another. One of the models of process communication is the message passing model.Message passing model allows multiple processes to read and write data to the message queue without being connected to each other. Messages are stored on the queue until their recipient retrieves them. Message queues are quite useful for interprocess communication and are used by most operating systems.A ... Read More

5K+ Views
Process communication is the mechanism provided by the operating system that allows processes to communicate with each other. This communication could involve a process letting another process know that some event has occurred or transferring of data from one process to another. One of the models of process communication is the shared memory model.The shared memory in the shared memory model is the memory that can be simultaneously accessed by multiple processes. This is done so that the processes can communicate with each other. All POSIX systems, as well as Windows operating systems use shared memory.A diagram that illustrates the ... Read More

651 Views
A process is an active program. It can also be said as a program that is under execution. It is more than the program code as it includes the program counter, process stack, registers, program code etc.A process passes through different states as it executes. A diagram that illustrates all these states is as follows −Details about the running, waiting and terminated process are given as follows −Running ProcessThe process is said to be in running state when the process instructions are being executed by the processor. This is done once the process is assigned to the processor using the ... Read More

7K+ Views
Process Scheduling handles the selection of a process for the processor on the basis of a scheduling algorithm and also the removal of a process from the processor. It is an important part of multiprogramming in operating system.Process scheduling involves short-term scheduling, medium-term scheduling and long-term scheduling. Details about these are given as follows −Long-Term SchedulingLong-term scheduling involves selecting the processes from the storage pool in the secondary memory and loading them into the ready queue in the main memory for execution. This is handled by the long-term scheduler or job scheduler.The long-term scheduler controls the degree of multiprogramming. It ... Read More

9K+ Views
Multithreading allows the execution of multiple parts of a program at the same time. These parts are known as threads and are lightweight processes available within the process. So multithreading leads to maximum utilization of the CPU by multitasking.Some of the benefits of multithreaded programming are given as follows −Resource SharingAll the threads of a process share its resources such as memory, data, files etc. A single application can have different threads within the same address space using resource sharing.ResponsivenessProgram responsiveness allows a program to run even if part of it is blocked using multithreading. This can also be done ... Read More

30K+ Views
A thread is a lightweight process that can be managed independently by a scheduler. It improves the application performance using parallelism.A thread shares information like data segment, code segment files etc. with its peer threads while it contains its own registers, stack, counter etc.The two main types of threads are user-level threads and kernel-level threads. A diagram that demonstrates these is as follows −User - Level ThreadsThe user-level threads are implemented by users and the kernel is not aware of the existence of these threads. It handles them as if they were single-threaded processes. User-level threads are small and much ... Read More

98K+ Views
The critical section is a code segment where the shared variables can be accessed. An atomic action is required in a critical section i.e. only one process can execute in its critical section at a time. All the other processes have to wait to execute in their critical sections.A diagram that demonstrates the critical section is as follows −In the above diagram, the entry section handles the entry into the critical section. It acquires the resources needed for execution by the process. The exit section handles the exit from the critical section. It releases the resources and also informs the ... Read More