Re: Move PinBuffer and UnpinBuffer to atomics
От | Amit Kapila |
---|---|
Тема | Re: Move PinBuffer and UnpinBuffer to atomics |
Дата | |
Msg-id | CAA4eK1J44ucJjDR7MM=s=zvAWMcU4AUh7__sSAmtd638CKr=ZA@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Move PinBuffer and UnpinBuffer to atomics (Alexander Korotkov <a.korotkov@postgrespro.ru>) |
Ответы |
Re: Move PinBuffer and UnpinBuffer to atomics
|
Список | pgsql-hackers |
On Tue, Mar 29, 2016 at 10:52 PM, Alexander Korotkov <a.korotkov@postgrespro.ru> wrote:
Hi, Andres!Please, find next revision of patch in attachment.
Couple of minor comments:
+ * The following two macroses
is macroses right word to be used here?
+ * of this loop. It should be used as fullowing:
/fullowing/following
+ * For local buffers usage of these macros shouldn't be used.
isn't it better to write it as
For local buffers, these macros shouldn't be used.
static int ts_ckpt_progress_comparator(Datum a, Datum b, void *arg);
-
Spurious line deletion.
+ * Since buffers are pinned/unpinned very frequently, this functions tries
+ * to pin buffer as cheap as possible.
/this functions tries
which functions are you referring here? Comment seems to be slightly unclear.
! if (XLogHintBitIsNeeded() && (pg_atomic_read_u32(&bufHdr->state) & BM_PERMANENT))
Is there a reason that you have kept macro's to read refcount and usagecount, but not for flags?
Apart from this, I have verified that patch compiles on Windows and passed regressions (make check)!
Nice work!
В списке pgsql-hackers по дате отправления: