XLogFlush invoked about twice as many times after 9.2 group commit enhancement

Поиск
Список
Период
Сортировка
От Amit Langote
Тема XLogFlush invoked about twice as many times after 9.2 group commit enhancement
Дата
Msg-id CA+HiwqF1JRhWsXc4i_+tFH2i=1MLjQeFE5w4=oGMDXNR3x8NVw@mail.gmail.com
обсуждение исходный текст
Ответы Re: XLogFlush invoked about twice as many times after 9.2 group commit enhancement
Список pgsql-hackers
Hello,

I have been trying to understand how group commit implementation works
the way it does after 9.2 group commit enhancement patch
(9b38d46d9f5517dab67dda1dd0459683fc9cda9f on REL9_2_STABLE). I have
observed some behavior in this regard that I could not understand.

Profiling results show that XLogFlush() is called about twice as many
times after this patch while for XLogWrite() count remains about same
as before. This patch modifies XLogFlush() such that it  offers the
said performance gain by alleviating the lock contention on
WALWriteLock using the new LWLockAcquireOrWait(). I do not however
understand why XLogFlush is invoked twice as many times (as seen from
the profiling results) as an effect of this patch. Why should this
patch make XLogFlush() being invoked twice as many times?

I used "pgbench -c 32 -t 1000 pgbench" in both cases with TPS result
after applying the patch not being significantly different (as in not
twice as much on my system).

I used:
pgbench scale=10

shared_buffers=256MB
max_connections=1000
checkpoint_segments=15
synchronous_commit=on

Comments?

--

Amit Langote


--

Amit Langote



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

Предыдущее
От: Stephen Frost
Дата:
Сообщение: Re: pg_dump --snapshot
Следующее
От: Greg Stark
Дата:
Сообщение: Re: pg_dump --snapshot