Re: [sqlsmith] Failed to generate plan on lateral subqueries

From: Andreas Seltenreich <seltenreich(at)gmx(dot)de>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Merlin Moncure <mmoncure(at)gmail(dot)com>, David Fetter <david(at)fetter(dot)org>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [sqlsmith] Failed to generate plan on lateral subqueries
Date: 2015-12-10 10:55:15
Message-ID: 87fuzaefos.fsf@elite.ansel.ydns.eu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane writes:

> Merlin Moncure <mmoncure(at)gmail(dot)com> writes:
>> Aside from the functional issues, could your changes result in
>> performance regressions?
[...]
> It's a little bit harder to gauge the impact on planner speed. The
> transitive closure calculation could be expensive in a query with many
> lateral references, but that doesn't seem likely to be common; and anyway
> we'll buy back some of that cost due to simpler tests later. I'm
> optimistic that we'll come out ahead in HEAD/9.5 after the removal
> of LateralJoinInfo setup. It might be roughly a wash in the back
> branches.

On the empirical side: I see a speedup of 0.4% in testing speed with the
patch applied. It could very well be me venting the room one additional
time during the second session, resulting in the CPUs spending more time
in their opportunistic frequency range or something.

regards,
Andreas

smith=# select extract('day' from t),
avg(generated/extract(epoch from updated - t)) as tps
from instance natural join stat
where generated > 1000000
and hostname not in('dwagon','slugbug')
-- these do stuff beside sqlsmith
and t > now() - interval '3 days' group by 1 order by 1;
date_part | tps
-----------+------------------
8 | 55.494181110456
9 | 55.6902316869404

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2015-12-10 11:29:41 Re: Error with index on unlogged table
Previous Message Amit Langote 2015-12-10 10:23:05 Re: [PROPOSAL] VACUUM Progress Checker.