Re: Relation extension scalability - Mailing list pgsql-hackers

From Amit Kapila
Subject Re: Relation extension scalability
Date
Msg-id CAA4eK1Jzg5FN_B0AzW-_uBqmzLH68aB29uqME+vs1ZDqEkFxtQ@mail.gmail.com
Whole thread Raw
In response to Re: Relation extension scalability  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: Relation extension scalability  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers
On Thu, Jan 7, 2016 at 1:36 AM, Robert Haas <robertmhaas@gmail.com> wrote:
On Thu, Dec 31, 2015 at 6:22 AM, Dilip Kumar <dilipbalaut@gmail.com> wrote:

Performanec Data:
--------------------------
There are Three code base for performance
1. Base Code

3. Multi extend patch attached in the mail.
#extend_num_pages : This this new config parameter to tell how many extra page extend in case of normal extend..
may be it will give more control to user if we make it relation property.

I will work on the patch for this CF, so adding it to CF.


Shared Buffer 48 GB


ClientsBase (TPS)Lock Free Patch
Multi-extend extend_num_pages=5
1142138148
2251253280
4237416464
8168491575
16141448404
32122337332




Shared Buffer 64 MB


ClientsBase (TPS)Multi-extend extend_num_pages=5
1140148
2252266
4229437
8153475
16132364


I'm not really sure what this email is trying to say.


What I could understand from above e-mail is that Dilip has tried to
extend relation multiple-pages-at-a-time and observed that it gives
comparable or better performance as compare to Andres's idea of
lock-free extension and it doesn't regress the low-thread count case.

Now, I think here point to discuss is that there could be multiple-ways
for extending a relation multiple-pages-at-a-time like:

a. Extend the relation page by page and add it to FSM without initializing
it.  I think this is what the current patch of Dilip seems to be doing. If we
want to go via this route, then we need to ensure that whenever we get
the page from FSM, if it is empty and not initialised, then initialise it.
b. Extend the relation page by page, initialize it and add it to FSM.
c. Extend the relation *n* pages at a time (in mdextend, have a provision
to do FILEWRITE for multiples of BLCKSZ).  Here again, we need to
evaluate what is better way to add it to FSM (after Page initialization or
before page initialization).
d. Use some form of Group Extension, which means only one backend
will extend the relation and others will piggyback there request of
extension to that backend and wait for extension.


With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com

pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: checkpointer continuous flushing
Next
From: Andres Freund
Date:
Subject: Re: Relation extension scalability