Re: [PATCH] Incremental sort (was: PoC: Partial sort) - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PATCH] Incremental sort (was: PoC: Partial sort)
Date
Msg-id 32110.1584121004@sss.pgh.pa.us
Whole thread Raw
In response to Re: [PATCH] Incremental sort (was: PoC: Partial sort)  (James Coleman <jtc331@gmail.com>)
Responses Re: [PATCH] Incremental sort (was: PoC: Partial sort)  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers
James Coleman <jtc331@gmail.com> writes:
> On Tue, Mar 10, 2020 at 10:44 PM Tomas Vondra
> <tomas.vondra@2ndquadrant.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.

> 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.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: explain HashAggregate to report bucket and memory stats
Next
From: Andres Freund
Date:
Subject: Re: [PATCH] Incremental sort (was: PoC: Partial sort)