refactoring allpaths.c (was Re: Suppressing unused subquery output columns) - Mailing list pgsql-hackers

From Tom Lane
Subject refactoring allpaths.c (was Re: Suppressing unused subquery output columns)
Date
Msg-id 28337.1402591068@sss.pgh.pa.us
Whole thread Raw
In response to Re: Suppressing unused subquery output columns  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: refactoring allpaths.c (was Re: Suppressing unused subquery output columns)  (Etsuro Fujita <fujita.etsuro@lab.ntt.co.jp>)
List pgsql-hackers
I wrote:
> We have a couple votes for this patch and no one has spoken against it,
> so I'll go ahead and push it into HEAD.

BTW, I forgot to mention that while working on this patch I was thinking
it's past time to separate out the subquery support in allpaths.c into
its own file.  With this patch, allpaths.c is 2363 lines, about 690 of
which are set_subquery_pathlist and subsidiary functions.  While that
might not be quite tail-wagging-dog level, I think it's enough to justify
splitting that code out into a new file, say optimizer/path/subquerypath.c.

There are also about 630 lines devoted to appendrel path generation,
which might be thought enough to deserve a separate file of its own.
I'm a bit less excited about that though, mainly because the appendrel
logic has some not-quite-arms-length interactions with set_rel_size();
but there's certainly some case to be made for doing it.

Thoughts?
        regards, tom lane



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Proposing pg_hibernate
Next
From: Claudio Freire
Date:
Subject: Re: B-Tree support function number 3 (strxfrm() optimization)