<s>
In	O
computer	B-General_Concept
science	I-General_Concept
,	O
a	O
lock	B-Operating_System
convoy	I-Operating_System
is	O
a	O
performance	O
problem	O
that	O
can	O
occur	O
when	O
using	O
locks	B-Operating_System
for	O
concurrency	B-Operating_System
control	I-Operating_System
in	O
a	O
multithreaded	B-Operating_System
application	O
.	O
</s>
<s>
A	O
lock	B-Operating_System
convoy	I-Operating_System
occurs	O
when	O
multiple	O
threads	B-Operating_System
of	O
equal	O
priority	O
contend	O
repeatedly	O
for	O
the	O
same	O
lock	O
.	O
</s>
<s>
Unlike	O
deadlock	B-Operating_System
and	O
livelock	O
situations	O
,	O
the	O
threads	B-Operating_System
in	O
a	O
lock	B-Operating_System
convoy	I-Operating_System
do	O
progress	O
;	O
however	O
,	O
each	O
time	O
a	O
thread	B-Operating_System
attempts	O
to	O
acquire	O
the	O
lock	O
and	O
fails	O
,	O
it	O
relinquishes	O
the	O
remainder	O
of	O
its	O
scheduling	O
quantum	O
and	O
forces	O
a	O
context	O
switch	O
.	O
</s>
<s>
Lock	B-Operating_System
convoys	I-Operating_System
often	O
occur	O
when	O
concurrency	B-Operating_System
control	I-Operating_System
primitives	O
such	O
as	O
locks	B-Operating_System
serialize	O
access	O
to	O
a	O
commonly	O
used	O
resource	O
,	O
such	O
as	O
a	O
memory	B-General_Concept
heap	I-General_Concept
or	O
a	O
thread	B-Operating_System
pool	I-Operating_System
.	O
</s>
<s>
They	O
can	O
sometimes	O
be	O
addressed	O
by	O
using	O
non-locking	O
alternatives	O
such	O
as	O
lock-free	B-Operating_System
algorithms	I-Operating_System
or	O
by	O
altering	O
the	O
relative	O
priorities	O
of	O
the	O
contending	O
threads	B-Operating_System
.	O
</s>
