Re: COPY locking

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: COPY locking
Дата
Msg-id 17919.989508663@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: COPY locking  (John Coers <coers@intrinsity.com>)
Список pgsql-general
John Coers <coers@intrinsity.com> writes:
> Ah so!  So after each tuple is written to shared memory there is a giant
> scramble for the lock.  Explains all the semops and timer sets and sleeps
> in the truss output that I've been seeing.

Hmm ... semops?  What platform are you on, anyway, and which PG version?
It sounds like you might be running with the fallback SysV-semaphore-
based implementation of spinlocks, which is orders of magnitude more
horrid than even the normal test-and-set-based implementation.  If there
is TAS support for your machine then I'd only expect to see select(2)
calls during spinlock operations.  Does your version of src/include/os.h
define HAS_TEST_AND_SET?

            regards, tom lane

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Norm SQL?
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Oracle to Pg tool