Skip to content

Commit 610df96

Browse files
committed
Proofread introduction to the ABA problem
Presents them as statements rather than questions.
1 parent ee7a4a9 commit 610df96

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

concurrency-primer.tex

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -884,10 +884,10 @@ \subsection{Conclusion about lock-free}
884884
a domain fraught with challenges.
885885

886886
\subsection{ABA problem}
887-
We have introduced CAS as one of the read-modify-write operations.
888-
However, does the target object not changing really mean that no other threads modified it halfway through?
889-
If the target object is changed to something by other thread and changed back, the result of comparison is still equal.
890-
Although the target object has indeed been changed, causing the operation not remaining atomic.
887+
CAS has been introduced as one of the read-modify-write operations.
888+
However, the target object not changing does not necessarily mean that no other threads modified it halfway through.
889+
If the target object is changed by another thread and then changed back, the result of comparison would still be equal.
890+
In this case, the target object has indeed been modified, yet the operation appears unchanged, compromising its atomicity.
891891
We call this \introduce{ABA problem}.
892892
Consider the following scenario,
893893

0 commit comments

Comments
 (0)