Re: ResourceOwner refactoring
Heikki Linnakangas <hlinnaka@iki.fi>
From: Heikki Linnakangas <hlinnaka@iki.fi>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>,
"kuroda.hayato@fujitsu.com" <kuroda.hayato@fujitsu.com>,
"pgsql-hackers@postgresql.org" <pgsql-hackers@postgresql.org>
Date: 2021-01-19T09:09:16Z
Lists: pgsql-hackers
On 18/01/2021 18:11, Robert Haas wrote: > On Mon, Jan 18, 2021 at 11:11 AM Robert Haas <robertmhaas@gmail.com> wrote: >> On Mon, Jan 18, 2021 at 10:19 AM Heikki Linnakangas <hlinnaka@iki.fi> wrote: >>> On 18/01/2021 16:34, Alvaro Herrera wrote: >>>> So according to your performance benchmark, we're willing to accept a >>>> 30% performance loss on an allegedly common operation -- numkeep=0 >>>> numsnaps=10 becomes 49.8ns from 37.6ns. That seems a bit shocking. >>>> Maybe you can claim that these operations aren't exactly hot spots, and >>>> so the fact that we remain in the same power-of-ten is sufficient. Is >>>> that the argument? >>> >>> That's right. The fast path is fast, and that's important. The slow path >>> becomes 30% slower, but that's acceptable. > > I don't know whether a 30% slowdown will hurt anybody, but it seems > like kind of a lot, and I'm not sure I understand what corresponding > benefit we're getting. The benefit is to make it easy for extensions to use resource owners to track whatever resources they need to track. And arguably, the new mechanism is nicer for built-in code, too. I'll see if I can optimize the slow paths, to make it more palatable. - Heikki
Commits
-
Make RelationFlushRelation() work without ResourceOwner during abort
- e6cd85772647 17.0 landed
-
Fix bug in bulk extending temp relation after failure
- d212957254de 17.0 landed
-
Add missing PGDLLIMPORT markings
- c6b86eaa55ff 17.0 landed
-
Add test_dsa module.
- 325f54033e59 17.0 landed
-
Clear CurrentResourceOwner earlier in CommitTransaction.
- c21e6e2fd48c 17.0 landed
-
Fix dsa.c with different resource owners.
- a8b330ffb6f7 17.0 landed
-
Fix bug in the new ResourceOwner implementation.
- 8f4a1ab471e6 17.0 landed
-
Change pgcrypto to use the new ResourceOwner mechanism.
- cd694f60dc97 17.0 landed
-
Use a faster hash function in resource owners.
- 954e43564d99 17.0 landed
-
Make ResourceOwners more easily extensible.
- b8bff07daa85 17.0 landed
-
Move a few ResourceOwnerEnlarge() calls for safety and clarity.
- b70c2143bbbe 17.0 landed