Re: Patch: Write Amplification Reduction Method (WARM)
Peter Geoghegan <pg@bowt.ie>
From: Peter Geoghegan <pg@bowt.ie>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Pavan Deolasee <pavan.deolasee@gmail.com>,
Andres Freund <andres@anarazel.de>, Amit Kapila <amit.kapila16@gmail.com>,
Alvaro Herrera <alvherre@2ndquadrant.com>, Bruce Momjian <bruce@momjian.us>,
Jaime Casanova <jaime.casanova@2ndquadrant.com>, Haribabu Kommi <kommi.haribabu@gmail.com>,
Tomas Vondra <tomas.vondra@2ndquadrant.com>, pgsql-hackers <pgsql-hackers@postgresql.org>, klaussfreire@gmail.com
Date: 2017-04-12T20:34:59Z
Lists: pgsql-hackers
On Wed, Apr 12, 2017 at 10:12 AM, Robert Haas <robertmhaas@gmail.com> wrote: >> I may have missed something, but there is no intention to ignore known >> regressions/reviews. Of course, I don't think that every regression will be >> solvable, like if you run a CPU-bound workload, setting it up in a way such >> that you repeatedly exercise the area where WARM is doing additional work, >> without providing any benefit, may be you can still find regression. I am >> willing to fix them as long as they are fixable and we are comfortable with >> the additional code complexity. IMHO certain trade-offs are good, but I >> understand that not everybody will agree with my views and that's ok. > > The point here is that we can't make intelligent decisions about > whether to commit this feature unless we know which situations get > better and which get worse and by how much. I don't accept as a > general principle the idea that CPU-bound workloads don't matter. > Obviously, I/O-bound workloads matter too, but we can't throw > CPU-bound workloads under the bus. Now, avoiding index bloat does > also save CPU, so it is easy to imagine that WARM could come out ahead > even if each update consumes slightly more CPU when actually updating, > so we might not actually regress. If we do, I guess I'd want to know > why. I myself wonder if this CPU overhead is at all related to LP_DEAD recycling during page splits. I have my suspicions that the recyling has some relationship to locality, which leads me to want to investigate how Claudio Freire's patch to consistently treat heap TID as part of the B-Tree sort order could help, both in general, and for WARM. Bear in mind that the recycling has to happen with an exclusive buffer lock held on a leaf page, which could hold up rather a lot of scans that need to visit the same value even if it's on some other, relatively removed leaf page. This is just a theory. -- Peter Geoghegan VMware vCenter Server https://www.vmware.com/
Commits
-
Implement SortSupport for macaddr data type
- f90d23d0c518 10.0 cited
-
Simplify check of modified attributes in heap_update
- 2fd8685e7fd9 10.0 landed
-
Remove direct uses of ItemPointer.{ip_blkid,ip_posid}
- ce96ce60ca22 10.0 landed
-
Fix CatalogTupleInsert/Update abstraction for case of shared indstate.
- aedd554f84bb 10.0 landed
-
Provide CatalogTupleDelete() as a wrapper around simple_heap_delete().
- ab02896510e2 10.0 landed
-
Band-aid fix for incorrect use of view options as StdRdOptions.
- e3e66d8a9813 10.0 cited
-
Update visibility map in the second phase of vacuum.
- fdf9e21196a6 9.3.0 cited
-
Avoid having two copies of the HOT-chain search logic.
- 4da99ea4231e 9.2.0 cited
-
Postgres95 1.01 Distribution - Virgin Sources
- d31084e9d111 7.1.1 cited