pgsql: Reduce idle power consumption of stats collector process. - Mailing list pgsql-committers

From Tom Lane
Subject pgsql: Reduce idle power consumption of stats collector process.
Date
Msg-id E1SRvgD-0002ll-TE@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Reduce idle power consumption of stats collector process.

Latch-ify the stats collector, so that it does not need an arbitrary wakeup
cycle to check for postmaster death.  The incremental savings in idle power
is pretty marginal, since we only had it waking every two seconds; but I
believe that this patch may also improve the collector's performance under
load, by reducing the number of kernel calls made per message when messages
are arriving constantly (we now avoid a select/poll call except when we
need to sleep).  The change also reduces the time needed for a normal
database shutdown on platforms where signals don't interrupt select().

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/49340037ee3ab46cb24144a86705e35f272c24d5

Modified Files
--------------
src/backend/postmaster/pgstat.c |  181 ++++++++++++++-------------------------
1 files changed, 65 insertions(+), 116 deletions(-)


pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: pgsql: Reduce idle power consumption of walwriter and checkpointer proc
Next
From: Bruce Momjian
Date:
Subject: pgsql: Document how to find non-ASCII characters in the release notes.