Re: Fwd: GSOC 2018 Project - A New Sorting Routine - Mailing list pgsql-hackers

From Peter Geoghegan
Subject Re: Fwd: GSOC 2018 Project - A New Sorting Routine
Date
Msg-id CAH2-Wz=UG59y7aCpmskGfNadjNs5ku6e2_gVWcPk4si9r9whfw@mail.gmail.com
Whole thread Raw
In response to Re: Fwd: GSOC 2018 Project - A New Sorting Routine  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
List pgsql-hackers
On Fri, Jul 13, 2018 at 6:03 PM, Tomas Vondra
<tomas.vondra@2ndquadrant.com> wrote:
> Unlikely. The pivot randomization is merely a way to defeat an adversary
> attempting to perform DoS by triggering sorts on a killer sequence.
> Randomization makes it much harder/impossible, because the killer
> sequence changes over time. It's not a regular performance optimization.

+1. The importance of the quadratic worst case for an industrial
strength quicksort seems to often be overstated.

Robert Sedgewick's Algorithms book has *excellent* analysis of
quicksort's worst case, which might be worth a read.

-- 
Peter Geoghegan


pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: Fwd: GSOC 2018 Project - A New Sorting Routine
Next
From: Justin T Pryzby
Date:
Subject: Re: Finding database for pg_upgrade missing library