Re: [HACKERS] Adding support for Default partition in partitioning

2017-06-07 Thread amul sul
On Wed, Jun 7, 2017 at 10:30 AM, Jeevan Ladhe wrote: > > >> IIUC, default partition constraints is simply NOT IN (> other sibling partitions>). >> If constraint on the default partition refutes the new partition's >> constraints that means we have overlapping

Re: [HACKERS] [POC] hash partitioning

2017-06-06 Thread amul sul
Hi Dilip, Thanks for review. On Sat, Jun 3, 2017 at 6:54 PM, Dilip Kumar <dilipbal...@gmail.com> wrote: > On Thu, May 25, 2017 at 9:59 AM, amul sul <sula...@gmail.com> wrote: >> On Mon, May 22, 2017 at 2:23 PM, amul sul <sula...@gmail.com> wrote: >>> >

Re: [HACKERS] remove unnecessary flag has_null from PartitionBoundInfoData

2017-06-12 Thread amul sul
On Wed, May 17, 2017 at 10:22 PM, Robert Haas wrote: [...] > I committed this with fixes for those issues, plus I renamed the macro > to partition_bound_accepts_nulls, which I think is more clear. > partition_bound_accepts_nulls() will alway yield true for a range

Re: [HACKERS] Adding support for Default partition in partitioning

2017-05-04 Thread amul sul
On Tue, May 2, 2017 at 9:33 PM, Rahila Syed wrote: > Please find attached updated patch with review comments by Robert and Jeevan > implemented. > Patch v8 got clean apply on latest head but server got crash at data insert in the following test: -- Create test table

Re: [HACKERS] [POC] hash partitioning

2017-09-14 Thread amul sul
On Wed, Sep 13, 2017 at 7:43 PM, Jesper Pedersen <jesper.peder...@redhat.com > wrote: > Hi Amul, > > On 09/08/2017 08:40 AM, amul sul wrote: > >> Rebased 0002 against this commit & renamed to 0001, PFA. >> >> > This patch needs a rebase. > > Thanks

Re: [HACKERS] [POC] hash partitioning

2017-09-15 Thread amul sul
On Fri, Sep 15, 2017 at 4:30 AM, Thom Brown <t...@linux.com> wrote: > On 14 September 2017 at 09:58, amul sul <sula...@gmail.com> wrote: > > On Wed, Sep 13, 2017 at 7:43 PM, Jesper Pedersen > > <jesper.peder...@redhat.com> wrote: > >> > >> Hi Amu

Re: [HACKERS] UPDATE of partition key

2017-09-21 Thread amul sul
On Wed, Sep 20, 2017 at 9:27 PM, Amit Khandekar wrote: > On 20 September 2017 at 00:06, Robert Haas wrote: > > On Fri, Sep 15, 2017 at 7:25 AM, Amit Khandekar > wrote: > >> [ new patch ] > 86 - (event ==

Re: [HACKERS] Improve catcache/syscache performance.

2017-09-20 Thread amul sul
Patch 0007: 1: 400 + /* 401 +* XXX: might be worthwhile to only handle oid sysattr, to reduce 402 +* overhead - it's the most common key. 403 +*/ IMHO, let fix that as well. I tested this by fixing (see the attach patch) but does not found much gain on my local

Re: [HACKERS] [POC] hash partitioning

2017-10-10 Thread amul sul
On Tue, Oct 10, 2017 at 3:32 PM, amul sul <sula...@gmail.com> wrote: > On Mon, Oct 9, 2017 at 5:51 PM, Ashutosh Bapat > <ashutosh.ba...@enterprisedb.com> wrote: >> On Mon, Oct 9, 2017 at 4:44 PM, amul sul <sula...@gmail.com> wrote: >> > > Thanks Ashuto

Re: [HACKERS] [POC] hash partitioning

2017-10-10 Thread amul sul
On Mon, Oct 9, 2017 at 5:51 PM, Ashutosh Bapat <ashutosh.ba...@enterprisedb.com> wrote: > On Mon, Oct 9, 2017 at 4:44 PM, amul sul <sula...@gmail.com> wrote: > Thanks Ashutosh for your review, please find my comment inline. > >> 0002 few changes in partition-wise j

Re: [HACKERS] [POC] hash partitioning

2017-10-10 Thread amul sul
On Tue, Oct 10, 2017 at 3:42 PM, Ashutosh Bapat <ashutosh.ba...@enterprisedb.com> wrote: > On Tue, Oct 10, 2017 at 3:32 PM, amul sul <sula...@gmail.com> wrote: > >>> +hash_part? true : key->parttypbyval[j], >>> +

Re: [HACKERS] [POC] hash partitioning

2017-10-12 Thread amul sul
On Thu, Oct 12, 2017 at 6:31 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Tue, Oct 10, 2017 at 7:07 AM, amul sul <sula...@gmail.com> wrote: >> How about the attached patch(0003)? >> Also, the dim variable is renamed to natts. > > I'

Re: [HACKERS] [POC] hash partitioning

2017-09-08 Thread amul sul
On Fri, Sep 8, 2017 at 6:45 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Mon, Sep 4, 2017 at 6:38 AM, amul sul <sula...@gmail.com> wrote: > > I've updated patch to use an extended hash function (Commit # > > 81c5e46c490e2426db243eada186995da5bb0ba7) for the parti

Re: [HACKERS] UPDATE of partition key

2017-09-08 Thread amul sul
On Thu, May 18, 2017 at 9:13 AM, Amit Kapila wrote: > On Wed, May 17, 2017 at 5:17 PM, Robert Haas > wrote: > > On Wed, May 17, 2017 at 6:29 AM, Amit Kapila > wrote: > >> I think we can do this even without using an

Re: [HACKERS] Hash Functions

2017-09-08 Thread amul sul
On Fri, Sep 1, 2017 at 8:01 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Aug 31, 2017 at 8:40 AM, amul sul <sula...@gmail.com> wrote: > > Fixed in the attached version. > > I fixed these up a bit and committed them. Thanks. > > I think t

Re: [HACKERS] [POC] hash partitioning

2017-09-11 Thread amul sul
On Mon, Sep 11, 2017 at 5:30 PM, Alvaro Herrera wrote: > Robert Haas wrote: > > On Mon, Sep 11, 2017 at 4:17 AM, Ashutosh Bapat > > wrote: > > >> Rebased 0002 against this commit & renamed to 0001, PFA. > > > > > > Given that we have

Re: [HACKERS] UPDATE of partition key

2017-09-13 Thread amul sul
On Sun, Sep 10, 2017 at 8:47 AM, Amit Kapila <amit.kapil...@gmail.com> wrote: > On Fri, Sep 8, 2017 at 4:51 PM, amul sul <sula...@gmail.com> wrote: > > On Thu, May 18, 2017 at 9:13 AM, Amit Kapila <amit.kapil...@gmail.com> > > wrote: > >> > >

Re: [HACKERS] UPDATE of partition key

2017-09-29 Thread amul sul
On Wed, Sep 13, 2017 at 4:24 PM, amul sul <sula...@gmail.com> wrote: > > > On Sun, Sep 10, 2017 at 8:47 AM, Amit Kapila <amit.kapil...@gmail.com> > wrote: >> >> On Fri, Sep 8, 2017 at 4:51 PM, amul sul <sula...@gmail.com> wrote: >> > On Th

Re: [HACKERS] [POC] hash partitioning

2017-09-28 Thread amul sul
On Thu, Sep 28, 2017 at 11:24 AM, Amit Langote <langote_amit...@lab.ntt.co.jp> wrote: > On 2017/09/27 22:41, Jesper Pedersen wrote: >> On 09/27/2017 03:05 AM, amul sul wrote: >>>>> Attached rebased patch, thanks. >>>>> >>>>> >>>&

Re: [HACKERS] Improve catcache/syscache performance.

2017-09-26 Thread amul sul
On Fri, Sep 22, 2017 at 11:47 AM, Andres Freund <and...@anarazel.de> wrote: > Hi, > > On 2017-09-20 18:26:50 +0530, amul sul wrote: > > Patch 0007: > > Other than these concern, patch looks pretty reasonable to me. > > I'd appreciate if you could have a look a

Re: [HACKERS] Hash Functions

2017-08-22 Thread amul sul
On Fri, Aug 18, 2017 at 11:01 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Fri, Aug 18, 2017 at 1:12 PM, amul sul <sula...@gmail.com> wrote: > > I have a small query, what if I want a cache entry with extended hash > > function instead standard one, I migh

Re: [HACKERS] Hash Functions

2017-08-29 Thread amul sul
On Tue, Aug 22, 2017 at 5:44 PM, amul sul <sula...@gmail.com> wrote: > On Fri, Aug 18, 2017 at 11:01 PM, Robert Haas <robertmh...@gmail.com> > wrote: > >> On Fri, Aug 18, 2017 at 1:12 PM, amul sul <sula...@gmail.com> wrote: >> > I have a small query,

Re: [HACKERS] Hash Functions

2017-08-31 Thread amul sul
On Wed, Aug 30, 2017 at 9:05 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Wed, Aug 30, 2017 at 10:43 AM, amul sul <sula...@gmail.com> wrote: > > Thanks for the suggestion, I have updated 0002-patch accordingly. > > Using this I found some strange behaviours as

Re: [HACKERS] [POC] hash partitioning

2017-09-04 Thread amul sul
I've updated patch to use an extended hash function (​Commit # 81c5e46c490e2426db243eada186995da5bb0ba7) for the partitioning. Regards, Amul On Thu, Jul 27, 2017 at 5:11 PM, amul sul <sula...@gmail.com> wrote: > Attaching newer patches rebased against the latest master hea

Re: [HACKERS] Hash Functions

2017-08-30 Thread amul sul
On Tue, Aug 29, 2017 at 11:48 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Tue, Aug 22, 2017 at 8:14 AM, amul sul <sula...@gmail.com> wrote: > > Attaching patch 0002 for the reviewer's testing. > > I think that this 0002 is not something we can think of c

Re: [HACKERS] [POC] hash partitioning

2017-10-07 Thread amul sul
On Fri, Oct 6, 2017 at 5:35 PM, Jesper Pedersen wrote: > Hi Amul, > > Could you rebase on latest master ? > Sure will post that soon, but before that, I need to test hash partitioning with recent partition-wise join commit (f49842d1ee), thanks. Regards, Amul --

Re: [HACKERS] path toward faster partition pruning

2017-09-27 Thread amul sul
On Wed, Sep 27, 2017 at 6:09 AM, Amit Langote wrote: > On 2017/09/27 1:51, Robert Haas wrote: > > On Tue, Sep 26, 2017 at 10:57 AM, Jesper Pedersen > > wrote: > >> One could advocate (*cough*) that the hash partition patch [1] should

Re: [HACKERS] [POC] hash partitioning

2017-09-27 Thread amul sul
On Mon, Sep 18, 2017 at 8:55 PM, Jesper Pedersen <jesper.peder...@redhat.com > wrote: > On 09/15/2017 02:30 AM, amul sul wrote: > >> Attached rebased patch, thanks. >> >> > While reading through the patch I thought it would be better to keep > MODULUS an

[HACKERS] Restrict concurrent update/delete with UPDATE of partition key

2017-09-27 Thread amul sul
Hi All, Attaching POC patch that throws an error in the case of a concurrent update to an already deleted tuple due to UPDATE of partition key[1]. In a normal update new tuple is linked to the old one via ctid forming a chain of tuple versions but UPDATE of partition key[1] move tuple from one

Re: [HACKERS] [POC] hash partitioning

2017-10-09 Thread amul sul
On Sat, Oct 7, 2017 at 5:22 PM, amul sul <sula...@gmail.com> wrote: > On Fri, Oct 6, 2017 at 5:35 PM, Jesper Pedersen > <jesper.peder...@redhat.com> wrote: >> Hi Amul, >> >> Could you rebase on latest master ? >> > > Sure will post that soon, b

Re: [HACKERS] [POC] hash partitioning

2017-10-24 Thread amul sul
On Fri, Oct 13, 2017 at 3:00 AM, Andres Freund wrote: > On 2017-10-12 17:27:52 -0400, Robert Haas wrote: >> On Thu, Oct 12, 2017 at 4:20 PM, Andres Freund wrote: >> >> In other words, it's not utterly fixed in stone --- we invented >> >>

Re: [HACKERS] [POC] hash partitioning

2017-10-24 Thread amul sul
On Tue, Oct 24, 2017 at 5:00 PM, Andres Freund <and...@anarazel.de> wrote: > On 2017-10-24 12:43:12 +0530, amul sul wrote: >> I tried to get suggested SMHasher[1] test result for the hash_combine >> for 32-bit and 64-bit version. >> >> SMHasher works on hash ke

Re: [HACKERS] Runtime Partition Pruning

2017-11-10 Thread amul sul
On Thu, Nov 9, 2017 at 4:48 PM, Beena Emerson wrote: > Hello all, > > Here is the updated patch which is rebased over v10 of Amit Langote's > path towards faster pruning patch [1]. It modifies the PartScanKeyInfo > struct to hold expressions which is then evaluated by the

Re: [HACKERS] [POC] hash partitioning

2017-11-02 Thread amul sul
On Thu, Nov 2, 2017 at 1:35 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Wed, Nov 1, 2017 at 3:46 PM, amul sul <sula...@gmail.com> wrote: >> Although partition constraints become more simple, there isn't any >> performance >> gain with 0005 patch. Als

Re: [HACKERS] path toward faster partition pruning

2017-11-09 Thread amul sul
On Mon, Nov 6, 2017 at 3:31 PM, Amit Langote wrote: > On 2017/11/06 14:32, David Rowley wrote: >> On 6 November 2017 at 17:30, Amit Langote wrote: >>> On 2017/11/03 13:32, David Rowley wrote: On 31 October 2017 at 21:43, Amit Langote wrote: [] > > Attached

Re: [HACKERS] Proposal: Improve bitmap costing for lossy pages

2017-11-09 Thread amul sul
Hi Dilip, v6 patch: 42 + /* 43 +* Estimate number of hashtable entries we can have within maxbytes. This 44 +* estimates the hash cost as sizeof(PagetableEntry). 45 +*/ 46 + nbuckets = maxbytes / 47 + (sizeof(PagetableEntry) + sizeof(Pointer) + sizeof(Pointer)); It

Re: [HACKERS] [POC] hash partitioning

2017-11-09 Thread amul sul
On Fri, Nov 10, 2017 at 4:41 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Wed, Nov 1, 2017 at 6:16 AM, amul sul <sula...@gmail.com> wrote: >> Fixed in the 0003 patch. > > I have committed this patch set with the attached adjustments. > Thanks a lot for your su

Re: [HACKERS] [POC] hash partitioning

2017-10-30 Thread amul sul
On Tue, Oct 31, 2017 at 9:54 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Mon, Oct 30, 2017 at 5:52 PM, amul sul <sula...@gmail.com> wrote: >> Actually, int4[] is also inappropriate type as we have started using a 64bit >> hash function. We need something int8[]

<    1   2