Re[14]: volatile bool vs std::atomic_flag vs std::atomic<boo
От: uzhas Ниоткуда  
Дата: 03.09.15 07:12
Оценка:
Здравствуйте, B0FEE664, Вы писали:

BFE>Ниже он пишет:

BFE>

BFE>The only way to guarantee you have the "latest" value is to use a read-modify-write operation such as exchange(), compare_exchange_strong() or fetch_add(). Read-modify-write operations have an additional constraint that they always operate on the "latest" value, so a sequence of ai.fetch_add(1) operations by a series of threads will return a sequence of values with no duplicates or gaps. In the absence of additional constraints, there's still no guarantee which threads will see which values though.


все правильно он пишет, тебя что-то здесь смущает?
Отредактировано 03.09.2015 9:12 uzhas . Предыдущая версия .
 
Подождите ...
Wait...
Пока на собственное сообщение не было ответов, его можно удалить.