wisemonkeys logo
FeedNotificationProfileManage Forms
FeedNotificationSearchSign in
wisemonkeys logo

Blogs

Synchronization

profile
23 B Titiksha Shah
Aug 16, 2024
0 Likes
0 Discussions
116 Reads

Synchronization

The communication of a message between two processes implies some level of synchronization

between the two: The receiver cannot receive a message until it has

been sent by another process. In addition, we need to specify what happens to a

process after it issues a send or receive primitive.

Consider the send primitive first. When a send primitive is executed in a

process, there are two possibilities: Either the sending process is blocked until the

message is received, or it is not. Similarly, when a process issues a receive primitive,

there are two possibilities:

1. If a message has previously been sent, the message is received and execution

continues.

2. If there is no waiting message, then either (a) the process is blocked until

a message arrives, or (b) the process continues to execute, abandoning the

attempt to receive.

Thus, both the sender and receiver can be blocking or nonblocking. Three

combinations are common, although any particular system will usually have only

one or two combinations implemented:

• Blocking send, blocking receive: Both the sender and receiver are blocked until

the message is delivered; this is sometimes referred to as a rendezvous . This

combination allows for tight synchronization between processes.

• Nonblocking send, blocking receive: Although the sender may continue on,

the receiver is blocked until the requested message arrives. This is probably

the most useful combination. It allows a process to send one or more messages

to a variety of destinations as quickly as possible. A process that must receive

a message before it can do useful work needs to be blocked until such a message

arrives. An example is a server process that exists to provide a service or

resource to other processes.

• Nonblocking send, nonblocking receive: Neither party is required to wait.

The nonblocking send is more natural for many concurrent programming

tasks. For example, if it is used to request an output operation, such as printing, it

allows the requesting process to issue the request in the form of a message and then

carry on. One potential danger of the nonblocking send is that an error could lead

to a situation in which a process repeatedly generates messages. Because there is no

blocking to discipline the process, these messages could consume system resources,

including processor time and buffer space, to the detriment of other processes and

the OS. Also, the nonblocking send places the burden on the programmer to determine

that a message has been received


Comments ()


Sign in

Read Next

A Weekend at Oak Tree Hotel: The Best Hotel Experience in Arcadia, Florida

Blog banner

Artificial Intelligence and I

Blog banner

Expressing and Measuring Risk (Risk Management)

Blog banner

Direct Memory Access

Blog banner

Understanding Endometriosis and Its Psychological Impact on Quality of Life

Blog banner

Booting Process In Operating System

Blog banner

Life of a 2020-2021 student

Blog banner

How To Implement Search Engine Marketing (Sem) Strategy Effectively

Blog banner

What is Virtual Memory

Blog banner

How to kiss

Blog banner

Improving the Accuracy of GPS and GNSS

Blog banner

Article on team management software

Blog banner

Gis in agriculture and farming

Blog banner

Cyber Attacks -- Trends Patterns and Security Countermeasures

Blog banner

Sage

Blog banner

Never give up

Blog banner

Cache Memory

Blog banner

Next time you click on "Remind me later", think twice!

Blog banner

Coping with Diagnosis Shock

Blog banner

Developments in Modern Operating Systems

Blog banner

c

Blog banner

Virtual Memory - Explaination, Working, Steps

Blog banner

The Rise of Polo Tourism in the USA: How Travellers Are Blending Luxury Stays with Elite Sports

Blog banner

Types of Viruses

Blog banner

Mumbai

Blog banner

MEMORY FORENSIC ACQUISITION AND ANALYSISOF MEMORY AND ITS TOOLS COMPARISON

Blog banner

**THE MUJAWARR: Transforming the Logistics Industry**

Blog banner

Device driver

Blog banner

What is Segmentation?

Blog banner

Multicore and multithreading 171

Blog banner

Brilliant WhatsApp Features Upcoming in 2023

Blog banner

GIS info about Bermuda Triangle

Blog banner

TECHNOLOGY : BOON OR CURSE ?

Blog banner

Efficiency of SQL Injection Method in Preventing E-Mail Hacking

Blog banner

Optimization of operating system design

Blog banner

Memory Management in Operating System

Blog banner

ART AND CULTURE OF VRINDAVAN

Blog banner

Virtual Machine

Blog banner

"Audit" In Data Science

Blog banner

Title: Network Sniffing Techniques: Uncovering the Secrets of Data Transfer

Blog banner

Should you be using a mouthwash? Know from the experts

Blog banner

How Preschool Annual Day Shapes Confidence, Emotions, and Growth

Blog banner