Re: Spin Lock sleep resolution

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Spin Lock sleep resolution
Дата
Msg-id 20129.1364876673@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Spin Lock sleep resolution  (Jeff Janes <jeff.janes@gmail.com>)
Ответы Re: Spin Lock sleep resolution  (Claudio Freire <klaussfreire@gmail.com>)
Re: Spin Lock sleep resolution  (Jeff Janes <jeff.janes@gmail.com>)
Список pgsql-hackers
Jeff Janes <jeff.janes@gmail.com> writes:
> The problem is that the state is maintained only to an integer number of
> milliseconds starting at 1, so it can take a number of attempts for the
> random increment to jump from 1 to 2, and then from 2 to 3.

Hm ... fair point, if you assume that the underlying OS has a sleep
resolution finer than 1ms.  Otherwise it would not matter.

> The attached patch changes the resolution of the state variable to
> microseconds, but keeps the starting value at 1msec, i.e. 1000 usec.

No patch seen here ...
        regards, tom lane



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

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: [PATCH] Exorcise "zero-dimensional" arrays (Was: Re: Should array_length() Return NULL)
Следующее
От: Atri Sharma
Дата:
Сообщение: Re: Page replacement algorithm in buffer cache