pgsql: Make fallback implementation of pg_memory_barrier() work.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: Make fallback implementation of pg_memory_barrier() work.
Дата
Msg-id E1Wln76-0002tH-2X@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Make fallback implementation of pg_memory_barrier() work.

The fallback implementation involves acquiring and releasing a spinlock
variable that is otherwise unreferenced --- not even to the extent of
initializing it.  This accidentally fails to fail on platforms where
spinlocks should be initialized to zeroes, but elsewhere it results in
a "stuck spinlock" failure during startup.

I griped about this last July, and put in a hack that worked for gcc
on HPPA, but didn't get around to fixing the general case.  Per the
discussion back then, the best thing to do seems to be to initialize
dummy_spinlock in main.c.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/44cd47c1d49655c5dd9648bde8e267617c3735b4

Modified Files
--------------
src/backend/main/main.c |    8 ++++++++
1 file changed, 8 insertions(+)


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: pgsql: Fix a bunch of functions that were declared static then defined
Следующее
От: Tom Lane
Дата:
Сообщение: pgsql: Fix two ancient memory-leak bugs in relcache.c.