From: | Peter Geoghegan <pg(at)heroku(dot)com> |
---|---|
To: | Greg Stark <stark(at)mit(dot)edu> |
Cc: | Jeff Janes <jeff(dot)janes(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, Simon Riggs <simon(at)2ndquadrant(dot)com> |
Subject: | Re: Using quicksort for every external sort run |
Date: | 2015-12-11 22:56:56 |
Message-ID: | CAM3SWZT_oS+-oQy4tMMj9HmSWTHqG7EnUKa0hS41b29Asqa36w@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Dec 11, 2015 at 2:52 PM, Greg Stark <stark(at)mit(dot)edu> wrote:
> Heh. And if I comment out the presorted check the breakeven point is
> *exactly* where the threshold is today at 7 elements -- presumably
> because Hoare chose it on purpose.
I think it was Sedgewick, but yes. I'd be very hesitant to mess with
the number of elements that we fallback to insertion sort on. I've
heard of people removing that optimization on the theory that it no
longer applies, but I think they were wrong to.
--
Peter Geoghegan
From | Date | Subject | |
---|---|---|---|
Next Message | Caleb Welton | 2015-12-11 23:02:17 | Re: Bootstrap DATA is a pita |
Previous Message | Caleb Welton | 2015-12-11 22:54:00 | Re: Bootstrap DATA is a pita |