








Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!









“Distributed Systems”, Ch. 6, section 6.
-^
a read returns the most recently written value(changes are instantaneous)
-^
not well-defined unless the execution ofcommands is serialized centrally
-^
otherwise the effects of a slow write may have notpropagated to the site of the read
-^
this is what uniprocessors
support:
a = 1; a = 2; print(a);
always produces “2”
to exercise our notation:^ P1: W(x)1^ P2:
R(x)
R(x)
is this strictly consistent?
P1:
W(x) P2:
R(x)
R(x)
P1:
W(x) P2:
R(x)
W(x)
P3:
R(x)
R(x)
P4:
R(x)
R(x)
Processor consistency
: PRAM consistency plus writes to
the same memory location are viewed everywhere in thesame order
Weak consistency uses synchronization variables topropagate writes to and from a machine at appropriatepoints:^ –
accesses to synchronization variables are sequentiallyconsistent – no access to a synchronization variable is allowed until allprevious writes have completed in all processors – no data access is allowed until all previous accesses tosynchronization variables (by the same processor) havebeen performed
-^
That is:^ –
accessing a synchronization variable “flushes thepipeline” – at a synchronization point, all processors have consistentversions of data
(“acquire/release”
are the conventional names)
doing a “lock”
means that writes on other processors
to protected variables will be known
-^
doing an “unlock”
means that writes to protected
variables are exported
-^
and will be seen by other machines when they do a“lock”
(lazy release consistency) or immediately
(eager release consistency)
P1: L W(x)1 W(x)2 U P2:
L R(x)
R(x)