Re: [PATCH] Incremental sort (was: PoC: Partial sort)

From: Andres Freund <andres(at)anarazel(dot)de>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: James Coleman <jtc331(at)gmail(dot)com>, Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>, Michael Paquier <michael(at)paquier(dot)xyz>, Rafia Sabih <rafia(dot)pghackers(at)gmail(dot)com>, Peter Geoghegan <pg(at)bowt(dot)ie>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Shaun Thomas <shaun(dot)thomas(at)2ndquadrant(dot)com>, Dmitry Dolgov <9erthalion6(at)gmail(dot)com>, Alexander Korotkov <a(dot)korotkov(at)postgrespro(dot)ru>, PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Subject: Re: [PATCH] Incremental sort (was: PoC: Partial sort)
Date: 2020-03-13 17:43:56
Message-ID: 20200313174356.mmzjwfpjanwacf6x@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On 2020-03-13 13:36:44 -0400, Tom Lane wrote:
> James Coleman <jtc331(at)gmail(dot)com> writes:
> > On Tue, Mar 10, 2020 at 10:44 PM Tomas Vondra
> > <tomas(dot)vondra(at)2ndquadrant(dot)com> wrote:
> >> 1) I see a bunch of failures in the regression test, due to minor
> >> differences in the explain output. All the differences are about minor
> >> changes in memory usage, like this:
> >>
> >> - "Sort Space Used": 30, +
> >> + "Sort Space Used": 29, +
> >>
> >> I'm not sure if it happens on my machine only, but maybe the test is not
> >> entirely stable.
>
> > make check passes on multiple machines for me; what arch/distro are you using?
>
> I think there's exactly zero chance of such output being stable across
> different platforms, particularly 32-vs-64-bit. You'll need to either
> drop that test or find some way to mask the variability.

+1

> > Is there a better way to test these? I would prefer these code paths
> > have test coverage, but the standard SQL tests don't leave a good way
> > to handle stuff like this.
>
> In some places we use plpgsql code to filter the EXPLAIN output.

I still think we should just go for a REPRODUCIBLE, TESTING, REGRESS or
similar EXPLAIN option, instead of playing whack-a-mole. Due to the
amount of discussion, the reduced test coverage, the increased test
complexity, the reduced quality of explain for humans we are well beyond
the point of making the cost of such an option worth it.

Greetings,

Andres Freund

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message James Coleman 2020-03-13 17:50:25 Re: [PATCH] Incremental sort (was: PoC: Partial sort)
Previous Message Tom Lane 2020-03-13 17:36:44 Re: [PATCH] Incremental sort (was: PoC: Partial sort)