Sujet : Re: signalling a condvar from inside vs. signalling a condvar von outside
De : Bonita.Montero (at) *nospam* gmail.com (Bonita Montero)
Groupes : comp.lang.c++Date : 19. Apr 2025, 16:24:26
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <vu0f66$1nm7v$1@raubtier-asyl.eternal-september.org>
References : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
User-Agent : Mozilla Thunderbird
Am 19.04.2025 um 16:34 schrieb Chris M. Thomasson:
Depends on the nature of the queue, and the nature of the wakes.
A broadcast should be only when you _really_ need it!
You've got a problem with hasty conclusions.
If you awake all awaking threads at once this is more efficient
than awaking them individually. Any even if you have a single
waiting thrad a notify_all() is more efficient with Linux and
Windows.