MCA Articles

Page 11 of 95

Lightweight process (LWP)

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 4K+ Views

Many systems implement either the many-to-many or the two-level model by placing an intermediate data structure between user and kernel threads. This data structure is typically known as a Lightweight Process (LWP) and serves as a virtual processor for scheduling user threads. How Lightweight Processes Work To the user-thread library, the LWP appears to be a virtual processor on which the application can schedule a user thread to run. Each LWP is attached to a kernel thread, and it is the kernel threads that the operating system schedules to run on physical processors. ...

Read More

Data structures of a Windows thread

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 840 Views

Windows implements the Windows API, which is the primary API for the family of Microsoft operating systems (Windows 98, NT, 2000, XP, and Windows 7). A Windows application runs as a separate process, and each process may contain one or more threads. Additionally, Windows uses the one-to-one mapping, where each user-level thread maps to an associated kernel thread. Components of a Windows Thread The general components of a thread include − A thread ID uniquely identifying the thread A set of registers representing the status of the processor A user stack, employed when the thread is ...

Read More

Hardware Synchronization

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 18K+ Views

Hardware Synchronization provides solutions to the critical-section problem using atomic hardware instructions. These hardware-based techniques form the foundation for more sophisticated synchronization mechanisms and offer better performance than pure software solutions. Hardware synchronization relies on the premise of locking using atomic operations that cannot be interrupted. These instructions allow us to test and modify memory locations or swap values as one uninterruptible unit, making them ideal for implementing mutual exclusion in multiprocessor environments. Why Hardware Support is Needed In uniprocessor systems, disabling interrupts can solve the critical-section problem by preventing preemption. However, this approach fails in multiprocessor ...

Read More

Peterson's Problem

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 19K+ Views

Peterson's solution provides a good algorithmic description of solving the critical-section problem and illustrates some of the complexities involved in designing software that addresses the requirements of mutual exclusion, progress, and bounded waiting. Peterson's Algorithm Peterson's solution is restricted to two processes that alternate execution between their critical sections and remainder sections. The processes are numbered P0 and P1. We use Pj to denote the other process when Pi is present; that is, j = 1 - i. Shared Data Variables Peterson's solution requires the two processes to share two data items: int turn; ...

Read More

Resuming Process Monitoring for a Process Instance

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 847 Views

When multiple processes are suspended on a condition variable x and an x.signal() operation is executed, we must determine which suspended process should be resumed next. A simple solution uses first-come, first-served (FCFS) ordering, where the longest-waiting process is resumed first. However, this approach is often inadequate for complex scheduling requirements. Conditional-Wait Construct The conditional-wait construct provides a more sophisticated scheduling mechanism with the form: x.wait(c); Here, c is an integer expression evaluated when the wait() operation executes. The value of c, called a priority number, is stored with the suspended process name. When ...

Read More

Program execution in CPU

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 2K+ Views

One may be amazed how the CPU is programmed. A special register is contained in CPU − the instruction register − whose bit pattern determines what the CPU will do. Once that action has been completed, the bit pattern in the instruction register can be changed, and the CPU will perform the operation specified by this next bit pattern. Most of the modern CPUs use an instruction queue. Some instructions are waiting in the queue, ready to be executed. Different electronic circuitry keeps the instruction queue full while the control unit is executing the instructions. But this is simply ...

Read More

Process Communication in Operating System

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 6K+ Views

Processes executing concurrently in an operating system can be classified as independent processes or cooperating processes. An independent process cannot affect or be affected by other processes in the system and does not share data with any other process. A cooperating process can affect or be affected by other processes and shares data with them. Why Process Cooperation is Important Operating systems provide environments that support process cooperation for several key reasons: Information sharing − Multiple users may need concurrent access to the same information, such as shared files or databases. Computation speedup − Tasks can ...

Read More

md5sum Command in Linux with Examples

Arnab Chakraborty
Arnab Chakraborty
Updated on 17-Mar-2026 644 Views

The md5sum command in Linux generates MD5 hash values (checksums) for files or text input. MD5 (Message Digest Algorithm 5) is a cryptographic hash function that produces a 128-bit hash value, typically represented as a 32-character hexadecimal string. This command is essential for verifying file integrity and detecting changes in data. The MD5 algorithm creates a unique fingerprint for data. Even a single character change results in a completely different hash value, making it useful for detecting file corruption or unauthorized modifications. Basic Syntax md5sum [OPTION] [FILE]... md5sum [OPTION] --check [FILE] Examples Generating ...

Read More

Semaphores in Operating System

David Meador
David Meador
Updated on 17-Mar-2026 222K+ Views

Semaphores are integer variables used to solve the critical section problem through two atomic operations: wait and signal. They provide a synchronization mechanism that allows processes to coordinate access to shared resources safely. How Semaphores Work Semaphores use two fundamental operations that must be executed atomically (without interruption): Wait Operation The wait operation decrements the value of its argument S if it is positive. If S is zero or negative, the process blocks until the semaphore becomes positive. wait(S) { while (S

Read More

Computer System Architecture

David Meador
David Meador
Updated on 17-Mar-2026 125K+ Views

A computer system is basically a machine that simplifies complicated tasks. It should maximize performance and reduce costs as well as power consumption. The different components in the Computer System Architecture are Input Unit, Output Unit, Storage Unit, Arithmetic Logic Unit, Control Unit etc. A diagram that shows the flow of data between these units is as follows − Computer System Architecture Control Unit Input Unit ...

Read More
Showing 101–110 of 941 articles
« Prev 1 9 10 11 12 13 95 Next »
Advertisements