From: | Alexander Korotkov <aekorotkov(at)gmail(dot)com> |
---|---|
To: | Ronan Dunklau <ronan(dot)dunklau(at)aiven(dot)io> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Michael Paquier <michael(at)paquier(dot)xyz>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: Fix gin index cost estimation |
Date: | 2022-12-02 11:33:33 |
Message-ID: | CAPpHfdtFYZjv41djYjNcJUuZhDKUu9eJSthKmmDWE-azAZjn5g@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi, Ronan!
On Fri, Dec 2, 2022 at 1:19 PM Ronan Dunklau <ronan(dot)dunklau(at)aiven(dot)io> wrote:
> Sorry for the delay, but here is an updated patch which changes the costing in
> the following way:
>
> - add a descent cost similar to the btree one is charged for the initial
> entry-tree
> - additionally, a charge is applied per page in both the entry tree and
> posting trees / lists
> - instead of charging the quals to each tuple, charge them per entry only. We
> still charge cpu_index_tuple_cost per tuple though.
>
> With those changes, no need to tweak the magic number formula estimating the
> number of pages. Maybe we can come up with something better for estimating
> those later on ?
Thank you for your patch. Couple of quick questions.
1) What magic number 50.0 stands for? I think we at least should make
it a macro.
2) "We only charge one data page for the startup cost" – should this
be dependent on number of search entries?
------
Regards,
Alexander Korotkov
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2022-12-02 11:35:59 | Re: Perform streaming logical transactions by background workers and parallel apply |
Previous Message | Ashutosh Bapat | 2022-12-02 11:28:30 | Re: Avoid streaming the transaction which are skipped (in corner cases) |