Re: Obsolete use of volatile in walsender.c, walreceiver.c, walreceiverfuncs.c?

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: Obsolete use of volatile in walsender.c, walreceiver.c, walreceiverfuncs.c?
Дата
Msg-id 20150921201903.GA295765@alvherre.pgsql
обсуждение исходный текст
Ответ на Obsolete use of volatile in walsender.c, walreceiver.c, walreceiverfuncs.c?  (Thomas Munro <thomas.munro@enterprisedb.com>)
Ответы Re: Obsolete use of volatile in walsender.c, walreceiver.c, walreceiverfuncs.c?  (Thomas Munro <thomas.munro@enterprisedb.com>)
Список pgsql-hackers
Thomas Munro wrote:

> In walsender.c, walreceiver.c, walreceiverfuncs.c there are several
> places where volatile qualifiers are used apparently only to prevent
> reordering around spinlock operations.

In replication/slot.c there are a number of places (12, I think) that
introduce a block specifically to contain a volatile cast on a variable
for spinlock-protected access.  We could remove the whole thing and save
at least 3 lines and one indentation level for each of them.

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: COPY planning
Следующее
От: Dmitry Vasilyev
Дата:
Сообщение: Re: Streaming Replication clusters and load balancing