On Fri, Jan 29, 2016 at 9:24 AM, Robert Haas <robertmh...@gmail.com> wrote:
> I feel like this could be data driven. I mean, the cost model is
> based mainly on the tuple width and the size of the SortTuple array.
> So, it should be possible to tests of both algorithms on 32, 64, 96,
> 128, ... byte tuples with a SortTuple array that is 256MB, 512MB,
> 768MB, 1GB, ... Then we can judge how closely the cost model comes to
> mimicking the actual behavior.
You would also need to represent how much of the input actually ended
up being sorted with the heap in each case. Maybe that could be tested
at 50% (bad for "quicksort with spillover"), 25% (better), and 5%
An alternative approach that might be acceptable is to add a generic,
conservative 90% threshold (so 10% of tuples sorted by heap).
Sent via pgsql-hackers mailing list (email@example.com)
To make changes to your subscription: