Re: Small improvement to compactify_tuples

Peter Geoghegan <pg@bowt.ie>

From: Peter Geoghegan <pg@bowt.ie>
To: Юрий Соколов <funny.falcon@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Sokolov Yura <funny.falcon@postgrespro.ru>, Claudio Freire <klaussfreire@gmail.com>, Alvaro Herrera <alvherre@2ndquadrant.com>, Heikki Linnakangas <hlinnaka@iki.fi>, PostgreSQL-Dev <pgsql-hackers@postgresql.org>
Date: 2017-11-04T23:35:59Z
Lists: pgsql-hackers
Юрий Соколов <funny.falcon@gmail.com> wrote:
>tps is also reflects changes:
>~17ktps with qsort
>~19ktps with bucket sort
>
>Also vacuum of benchmark's table is also improved:
>~3s with qsort,
>~2.4s with bucket sort

One thing that you have to be careful with when it comes to our qsort
with partially presored inputs is what I like to call "banana skin
effects":

https://postgr.es/m/CAH2-WzkU2xK2dpZ7N8-A1MvuUTTUvhqkfnA+eUtwNwCtgyCJgw@mail.gmail.com

This may have nothing at all to do with your results; I'm just pointing
it out as a possibility.

-- 
Peter Geoghegan


Commits

  1. Avoid looping through line pointers twice in PageRepairFragmentation().

  2. Reduce pinning and buffer content locking for btree scans.

  3. Speed up in-memory tuplesorting.