Re: pgsql: Do execGrouping.c via expression eval machinery.

2018-02-15 Thread Andres Freund
On 2018-02-15 22:14:30 -0800, Andres Freund wrote: > On 2018-02-16 05:58:09 +, Andres Freund wrote: > > Do execGrouping.c via expression eval machinery. > > > > This has a performance benefit on own, although not hugely so. The > > primary benefit is that it will allow for to JIT tuple deformi

pgsql: Revert "Do execGrouping.c via expression eval machinery."

2018-02-15 Thread Andres Freund
Revert "Do execGrouping.c via expression eval machinery." This reverts commit 773aec7aa98abd38d6d9435913bb8e14e392c274. There's an unresolved issue in the reverted commit: It only creates one comparator function, but in for the nodeSubplan.c case we need more (c.f. FindTupleHashEntry vs LookupTup

Re: pgsql: Do execGrouping.c via expression eval machinery.

2018-02-15 Thread Andres Freund
On 2018-02-16 05:58:09 +, Andres Freund wrote: > Do execGrouping.c via expression eval machinery. > > This has a performance benefit on own, although not hugely so. The > primary benefit is that it will allow for to JIT tuple deforming and > comparator invocations. > > Author: Andres Freund >

pgsql: Do execGrouping.c via expression eval machinery.

2018-02-15 Thread Andres Freund
Do execGrouping.c via expression eval machinery. This has a performance benefit on own, although not hugely so. The primary benefit is that it will allow for to JIT tuple deforming and comparator invocations. Author: Andres Freund Discussion: https://postgr.es/m/20171129080934.amqqkke2zjtek...@a

Re: pgsql: Use new overflow aware integer operations.

2018-02-15 Thread Andres Freund
Hi, On 2018-02-14 17:36:38 -0500, Tom Lane wrote: > Andres Freund writes: > > I can't convince any of my compilers to actual emit warnings in this > > case, so we'll have to see whether prairiedog like this... > > Per my results yesterday, locust and coypu were also complaining; > one of them mi

pgsql: Fix plpgsql to enforce domain checks when returning a NULL domai

2018-02-15 Thread Tom Lane
Fix plpgsql to enforce domain checks when returning a NULL domain value. If a plpgsql function is declared to return a domain type, and the domain's constraints forbid a null value, it was nonetheless possible to return NULL, because we didn't bother to check the constraints for a null result. I'd

pgsql: Doc: fix minor bug in CREATE TABLE example.

2018-02-15 Thread Tom Lane
Doc: fix minor bug in CREATE TABLE example. One example in create_table.sgml claimed to be showing table constraint syntax, but it was really column constraint syntax due to the omission of a comma. This is both wrong and confusing, so fix it in all supported branches. Per report from n...@postg

pgsql: Doc: fix minor bug in CREATE TABLE example.

2018-02-15 Thread Tom Lane
Doc: fix minor bug in CREATE TABLE example. One example in create_table.sgml claimed to be showing table constraint syntax, but it was really column constraint syntax due to the omission of a comma. This is both wrong and confusing, so fix it in all supported branches. Per report from n...@postg

pgsql: Doc: fix minor bug in CREATE TABLE example.

2018-02-15 Thread Tom Lane
Doc: fix minor bug in CREATE TABLE example. One example in create_table.sgml claimed to be showing table constraint syntax, but it was really column constraint syntax due to the omission of a comma. This is both wrong and confusing, so fix it in all supported branches. Per report from n...@postg

pgsql: Doc: fix minor bug in CREATE TABLE example.

2018-02-15 Thread Tom Lane
Doc: fix minor bug in CREATE TABLE example. One example in create_table.sgml claimed to be showing table constraint syntax, but it was really column constraint syntax due to the omission of a comma. This is both wrong and confusing, so fix it in all supported branches. Per report from n...@postg

pgsql: Doc: fix minor bug in CREATE TABLE example.

2018-02-15 Thread Tom Lane
Doc: fix minor bug in CREATE TABLE example. One example in create_table.sgml claimed to be showing table constraint syntax, but it was really column constraint syntax due to the omission of a comma. This is both wrong and confusing, so fix it in all supported branches. Per report from n...@postg

pgsql: Doc: fix minor bug in CREATE TABLE example.

2018-02-15 Thread Tom Lane
Doc: fix minor bug in CREATE TABLE example. One example in create_table.sgml claimed to be showing table constraint syntax, but it was really column constraint syntax due to the omission of a comma. This is both wrong and confusing, so fix it in all supported branches. Per report from n...@postg

pgsql: Cast to void in StaticAssertExpr, not its callers.

2018-02-15 Thread Tom Lane
Cast to void in StaticAssertExpr, not its callers. Seems a bit silly that many (in fact all, as of today) uses of StaticAssertExpr would need to cast it to void to avoid warnings from pickier compilers. Let's just do the cast right in the macro, instead. In passing, change StaticAssertExpr to St