Re: Top-N sorts verses parallelism - Mailing list pgsql-hackers

From Jeff Janes
Subject Re: Top-N sorts verses parallelism
Date
Msg-id CAMkU=1w6BJ5RJs0HxXi6K_jqVcUPYp0qz_8izeEF9AsGkAQSmg@mail.gmail.com
Whole thread Raw
In response to Top-N sorts verses parallelism  (Thomas Munro <thomas.munro@enterprisedb.com>)
List pgsql-hackers
On Tue, Dec 12, 2017 at 10:46 PM, Thomas Munro <thomas.munro@enterprisedb.com> wrote:
Hi hackers,

The start-up cost of bounded (top-N) sorts is sensitive at the small
end of N, and the
comparison_cost * tuples * LOG2(2.0 * output_tuples) curve doesn't
seem to correspond to reality.


Do we want the cost-estimate to be accurate for the worst case (which is not terribly unlikely to happen, input order is opposite of desired output order), or for the average case?

Cheers,

Jeff

pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Top-N sorts verses parallelism
Next
From: Andres Freund
Date:
Subject: Re: [HACKERS] Parallel Hash take II