Re: Handing off SLRU fsyncs to the checkpointer
Jakub Wartak <jakub.wartak@tomtom.com>
From: Jakub Wartak <Jakub.Wartak@tomtom.com>
To: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Thomas Munro <thomas.munro@gmail.com>, Robert Haas <robertmhaas@gmail.com>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2020-08-27T10:13:46Z
Lists: pgsql-hackers
Hi Alvaro, Thomas, hackers >> 14.69% postgres postgres [.] hash_search_with_hash_value >> ---hash_search_with_hash_value >> |--9.80%--BufTableLookup [..] >> --4.90%--smgropen >> |--2.86%--ReadBufferWithoutRelcache > Looking at an earlier report of this problem I was thinking whether it'd > make sense to replace SMgrRelationHash with a simplehash table; I have a > half-written patch for that, but I haven't completed that work. > However, in the older profile things were looking different, as > hash_search_with_hash_value was taking 35.25%, and smgropen was 33.74% > of it. BufTableLookup was also there but only 1.51%. So I'm not so > sure now that that'll pay off as clearly as I had hoped. Yes, quite frankly my expectation was to see hash_search_with_hash_value()<-smgropen() outcome as 1st one, but in simplified redo-bench script it's not the case. The original scenario was much more complex with plenty of differences (in no particular order: TB-sized DB VS ~500GB RAM -> thousands of forks, multiple tables, huge btrees, multiple INSERTs wih plenty of data in VALUES() thrown as one commit, real primary->hot-standby replication [not closed DB in recovery], sorted not random UUIDs) - I'm going to try nail down these differences and maybe I manage to produce more realistic "pgbench reproducer" (this may take some time though). -Jakub Wartak.
Commits
-
Remove unused function prototypes.
- 87c23d36a3bc 14.0 landed
-
Defer flushing of SLRU files.
- dee663f78439 14.0 landed
-
Improve the vacuum error context phase information.
- a3c66de6c5e1 14.0 cited
-
Cache smgrnblocks() results in recovery.
- c5315f4f4484 14.0 cited
-
Refactor the fsync queue for wider use.
- 3eb77eba5a51 12.0 cited
-
Increase maximum number of clog buffers.
- 5364b357fb11 9.6.0 cited
-
Make the number of CLOG buffers adaptive, based on shared_buffers.
- 33aaa139e630 9.2.0 cited
-
Replace implementation of pg_log as a relation accessed through the
- 2589735da08c 7.2.1 cited