pgsql: Fix unstable regression test added by commits 59b71c6fe et al.

2017-11-23 Thread Tom Lane
Fix unstable regression test added by commits 59b71c6fe et al. The query didn't really have a preferred index, leading to platform- specific choices of which one to use. Adjust it to make sure tenk1_hundred is always chosen. Per buildfarm. Branch -- REL9_6_STABLE Details --- https://gi

pgsql: Fix unstable regression test added by commits 59b71c6fe et al.

2017-11-23 Thread Tom Lane
Fix unstable regression test added by commits 59b71c6fe et al. The query didn't really have a preferred index, leading to platform- specific choices of which one to use. Adjust it to make sure tenk1_hundred is always chosen. Per buildfarm. Branch -- REL_10_STABLE Details --- https://gi

pgsql: Fix unstable regression test added by commits 59b71c6fe et al.

2017-11-23 Thread Tom Lane
Fix unstable regression test added by commits 59b71c6fe et al. The query didn't really have a preferred index, leading to platform- specific choices of which one to use. Adjust it to make sure tenk1_hundred is always chosen. Per buildfarm. Branch -- master Details --- https://git.postg

pgsql: Support linking with MinGW-built Perl.

2017-11-23 Thread Noah Misch
Support linking with MinGW-built Perl. This is necessary for ActivePerl 5.18 onwards and for Strawberry Perl. It is not sufficient for 32-bit builds with newer Visual Studio; these fail with error LINK2026. Back-patch to 9.3 (all supported versions). Reported by Victor Wagner. Discussion: https

pgsql: Support linking with MinGW-built Perl.

2017-11-23 Thread Noah Misch
Support linking with MinGW-built Perl. This is necessary for ActivePerl 5.18 onwards and for Strawberry Perl. It is not sufficient for 32-bit builds with newer Visual Studio; these fail with error LINK2026. Back-patch to 9.3 (all supported versions). Reported by Victor Wagner. Discussion: https

pgsql: Support linking with MinGW-built Perl.

2017-11-23 Thread Noah Misch
Support linking with MinGW-built Perl. This is necessary for ActivePerl 5.18 onwards and for Strawberry Perl. It is not sufficient for 32-bit builds with newer Visual Studio; these fail with error LINK2026. Back-patch to 9.3 (all supported versions). Reported by Victor Wagner. Discussion: https

pgsql: Support linking with MinGW-built Perl.

2017-11-23 Thread Noah Misch
Support linking with MinGW-built Perl. This is necessary for ActivePerl 5.18 onwards and for Strawberry Perl. It is not sufficient for 32-bit builds with newer Visual Studio; these fail with error LINK2026. Back-patch to 9.3 (all supported versions). Reported by Victor Wagner. Discussion: https

pgsql: Support linking with MinGW-built Perl.

2017-11-23 Thread Noah Misch
Support linking with MinGW-built Perl. This is necessary for ActivePerl 5.18 onwards and for Strawberry Perl. It is not sufficient for 32-bit builds with newer Visual Studio; these fail with error LINK2026. Back-patch to 9.3 (all supported versions). Reported by Victor Wagner. Discussion: https

pgsql: Support linking with MinGW-built Perl.

2017-11-23 Thread Noah Misch
Support linking with MinGW-built Perl. This is necessary for ActivePerl 5.18 onwards and for Strawberry Perl. It is not sufficient for 32-bit builds with newer Visual Studio; these fail with error LINK2026. Back-patch to 9.3 (all supported versions). Reported by Victor Wagner. Discussion: https

Re: pgsql: Generational memory allocator

2017-11-23 Thread Tom Lane
Tomas Vondra writes: > On 11/23/2017 11:04 PM, Tom Lane wrote: >> I pushed a patch that computes how much padding to add and adds it. >> (It might not really work if size_t and void * are different sizes, >> because then there could be additional padding in the struct; but >> that seems very unlik

pgsql: Fix handling of NULLs returned by aggregate combine functions.

2017-11-23 Thread Andres Freund
Fix handling of NULLs returned by aggregate combine functions. When strict aggregate combine functions, used in multi-stage/parallel aggregation, returned NULL, we didn't check for that, invoking the combine function with NULL the next round, despite it being strict. The equivalent code invoking

pgsql: Fix handling of NULLs returned by aggregate combine functions.

2017-11-23 Thread Andres Freund
Fix handling of NULLs returned by aggregate combine functions. When strict aggregate combine functions, used in multi-stage/parallel aggregation, returned NULL, we didn't check for that, invoking the combine function with NULL the next round, despite it being strict. The equivalent code invoking

pgsql: Fix handling of NULLs returned by aggregate combine functions.

2017-11-23 Thread Andres Freund
Fix handling of NULLs returned by aggregate combine functions. When strict aggregate combine functions, used in multi-stage/parallel aggregation, returned NULL, we didn't check for that, invoking the combine function with NULL the next round, despite it being strict. The equivalent code invoking

Re: pgsql: Generational memory allocator

2017-11-23 Thread Tomas Vondra
On 11/23/2017 11:04 PM, Tom Lane wrote: Andres Freund writes: On 2017-11-23 22:34:57 +0100, Tomas Vondra wrote: Hmmm, I see. Presumably adding this to GenerationChunk (similarly to what we do in AllocChunkData) would address the issue: #if MAXIMUM_ALIGNOF > 4 && SIZEOF_VOID_P == 4 Size

Re: pgsql: Generational memory allocator

2017-11-23 Thread Tom Lane
Andres Freund writes: > On 2017-11-23 22:34:57 +0100, Tomas Vondra wrote: >> Hmmm, I see. Presumably adding this to GenerationChunk (similarly to what we >> do in AllocChunkData) would address the issue: >> >> #if MAXIMUM_ALIGNOF > 4 && SIZEOF_VOID_P == 4 >> Size padding; >> #endif >> >>

pgsql: Ensure sizeof(GenerationChunk) is maxaligned.

2017-11-23 Thread Tom Lane
Ensure sizeof(GenerationChunk) is maxaligned. Per buildfarm. Also improve some comments. Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/07bd77b95a7846de2b193d1574951436d5783800 Modified Files -- src/backend/utils/mmgr/generation.c | 41 +++

Re: pgsql: Generational memory allocator

2017-11-23 Thread Simon Riggs
On 24 November 2017 at 06:39, Andres Freund wrote: > On 2017-11-23 20:57:10 +1100, Simon Riggs wrote: >> On 23 November 2017 at 11:16, Andres Freund wrote: >> > Hi, >> > >> > On 2017-11-22 18:48:19 +, Simon Riggs wrote: >> >> Generational memory allocator >> >> >> >> Add new style of memory a

Re: pgsql: Generational memory allocator

2017-11-23 Thread Andres Freund
On 2017-11-23 22:34:57 +0100, Tomas Vondra wrote: > > I think it's a legitimate complaint that postmaster.log wasn't captured > > in this failure, but that's a buildfarm script oversight and hardly > > Andres' fault. > > > > Are the valgrind errors really written to postmaster log? I'm assuming i

Re: pgsql: Generational memory allocator

2017-11-23 Thread Simon Riggs
On 24 November 2017 at 07:06, Tom Lane wrote: > Meanwhile, over on > https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=snapper&dt=2017-11-23%2013%3A56%3A17 > > we have > > ccache gcc-4.7 -Wall -Wmissing-prototypes -Wpointer-arith > -Wdeclaration-after-statement -Wendif-labels -Wmissing-for

Re: pgsql: Generational memory allocator

2017-11-23 Thread Tomas Vondra
On 11/23/2017 09:06 PM, Tom Lane wrote: Andres Freund writes: On 2017-11-23 20:57:10 +1100, Simon Riggs wrote: On 23 November 2017 at 11:16, Andres Freund wrote: Looks like it's not quite valgrind clean: https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=skink&dt=2017-11-22%2022%3A30%

Re: pgsql: Generational memory allocator

2017-11-23 Thread Tom Lane
Andres Freund writes: > On 2017-11-23 20:57:10 +1100, Simon Riggs wrote: >> On 23 November 2017 at 11:16, Andres Freund wrote: >>> Looks like it's not quite valgrind clean: >>> https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=skink&dt=2017-11-22%2022%3A30%3A01 >> It doesn't report anythin

Re: pgsql: Generational memory allocator

2017-11-23 Thread Andres Freund
On 2017-11-23 20:57:10 +1100, Simon Riggs wrote: > On 23 November 2017 at 11:16, Andres Freund wrote: > > Hi, > > > > On 2017-11-22 18:48:19 +, Simon Riggs wrote: > >> Generational memory allocator > >> > >> Add new style of memory allocator, known as Generational > >> appropriate for use in c

Re: pgsql: Generational memory allocator

2017-11-23 Thread Simon Riggs
On 24 November 2017 at 02:16, Tomas Vondra wrote: > > > On 11/23/2017 10:57 AM, Simon Riggs wrote: >> >> On 23 November 2017 at 11:16, Andres Freund wrote: >>> >>> Hi, >>> >>> On 2017-11-22 18:48:19 +, Simon Riggs wrote: Generational memory allocator Add new style of memor

Re: pgsql: Generational memory allocator

2017-11-23 Thread Tomas Vondra
On 11/23/2017 10:57 AM, Simon Riggs wrote: On 23 November 2017 at 11:16, Andres Freund wrote: Hi, On 2017-11-22 18:48:19 +, Simon Riggs wrote: Generational memory allocator Add new style of memory allocator, known as Generational appropriate for use in cases where memory is allocated a

pgsql: Convert documentation to DocBook XML

2017-11-23 Thread Peter Eisentraut
Convert documentation to DocBook XML Since some preparation work had already been done, the only source changes left were changing empty-element tags like to , and changing the DOCTYPE. The source files are still named *.sgml, but they are actually XML files now. Renaming could be considered la

Re: pgsql: Generational memory allocator

2017-11-23 Thread Simon Riggs
On 23 November 2017 at 11:16, Andres Freund wrote: > Hi, > > On 2017-11-22 18:48:19 +, Simon Riggs wrote: >> Generational memory allocator >> >> Add new style of memory allocator, known as Generational >> appropriate for use in cases where memory is allocated >> and then freed in roughly oldes