Skip to content

Commit

Permalink
Merge pull request #196 from hanxu12/fix-typo
Browse files Browse the repository at this point in the history
Fix synchronization.tex typo
  • Loading branch information
angrave authored Dec 18, 2023
2 parents eb67c59 + 33d09a6 commit f9043da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion synchronization/synchronization.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1461,7 +1461,7 @@ \section{Barriers}
Let's use a condition variable and then we will use a broadcast/signal functions to wake up the sleeping threads.

A reminder, a condition variable is similar to a house! Threads go there to sleep (\keyword{pthread\_cond\_wait}).
A threa can choose to wake up one thread (\keyword{pthread\_cond\_signal}) or all of them (\keyword{pthread\_cond\_broadcast}).
A thread can choose to wake up one thread (\keyword{pthread\_cond\_signal}) or all of them (\keyword{pthread\_cond\_broadcast}).
If there are no threads currently waiting then these two calls have no effect.

A condition variable version is usually similar to a busy loop incorrect solution - as we will show next.
Expand Down

0 comments on commit f9043da

Please sign in to comment.