Re: [HACKERS] pg_shmem_allocations view

2020-01-09 Thread Andres Freund
Hi, On 2020-01-09 11:13:46 -0500, Robert Haas wrote: > On Wed, Jan 8, 2020 at 2:30 AM Kyotaro Horiguchi > wrote: > > I agree to the patch as-is. Thanks for the explanatin. > > OK. Thanks for the review, and for your thoughtful consideration of my > comments. > > I went ahead and committed this

Re: [HACKERS] pg_shmem_allocations view

2020-01-09 Thread Robert Haas
On Wed, Jan 8, 2020 at 2:30 AM Kyotaro Horiguchi wrote: > I agree to the patch as-is. Thanks for the explanatin. OK. Thanks for the review, and for your thoughtful consideration of my comments. I went ahead and committed this. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterp

Re: [HACKERS] pg_shmem_allocations view

2020-01-07 Thread Kyotaro Horiguchi
At Mon, 30 Dec 2019 13:52:50 -0500, Robert Haas wrote in > On Wed, Dec 18, 2019 at 9:53 PM Kyotaro Horiguchi > wrote: > > The doc is saying that "size" is "Size of the allocation" and > > "allocated_size" is "size including padding". It seems somewhat > > confusing to me. I'm not sure what word

Re: [HACKERS] pg_shmem_allocations view

2019-12-30 Thread Robert Haas
On Wed, Dec 18, 2019 at 9:53 PM Kyotaro Horiguchi wrote: > The doc is saying that "size" is "Size of the allocation" and > "allocated_size" is "size including padding". It seems somewhat > confusing to me. I'm not sure what wording is best but I think people > use net/gross wordings to describe li

Re: [HACKERS] pg_shmem_allocations view

2019-12-18 Thread Kyotaro Horiguchi
At Wed, 18 Dec 2019 12:30:51 -0500, Robert Haas wrote in > On Wed, Dec 18, 2019 at 12:06 PM Tom Lane wrote: > > It seems like it'd be worth subdividing "" into the actual > > anonymous allocations and the allocator overhead (which is both > > padding and whatever the shmem allocator itself eats

Re: [HACKERS] pg_shmem_allocations view

2019-12-18 Thread Robert Haas
On Wed, Dec 18, 2019 at 12:06 PM Tom Lane wrote: > It seems like it'd be worth subdividing "" into the actual > anonymous allocations and the allocator overhead (which is both > padding and whatever the shmem allocator itself eats). Maybe call > the latter "". After which, I'd be tempted to call

Re: [HACKERS] pg_shmem_allocations view

2019-12-18 Thread Tom Lane
Robert Haas writes: > On Wed, Dec 18, 2019 at 10:59 AM Alvaro Herrera > wrote: >> Can we please stop splitting this error message in two? >> >> +errmsg("materialize mode required, but it is not " \ >> + "allowed in this context"))); >> >> (What's with the n

Re: [HACKERS] pg_shmem_allocations view

2019-12-18 Thread Robert Haas
On Wed, Dec 18, 2019 at 10:59 AM Alvaro Herrera wrote: > On 2019-Dec-18, Robert Haas wrote: > > - code: Declare values/nulls arrays only once at function scope > > instead of 3x, and tighten up code, per Andres and self-review. > > Really small nit: I'd rather have the "nulls" assignment in all ca

Re: [HACKERS] pg_shmem_allocations view

2019-12-18 Thread Alvaro Herrera
On 2019-Dec-18, Robert Haas wrote: > - code: Declare values/nulls arrays only once at function scope > instead of 3x, and tighten up code, per Andres and self-review. Really small nit: I'd rather have the "nulls" assignment in all cases even when the previous value is still valid. This tight cod

Re: [HACKERS] pg_shmem_allocations view

2019-12-18 Thread Robert Haas
On Fri, Nov 15, 2019 at 2:59 PM Tom Lane wrote: > I didn't really read the patch in any detail, but those things > hopped out at me. Thanks for the reviews. Here is a new version. Changes: - doc: Add an entry to the table of system views, per Tom. - doc: Wrap reference to "" in tags, per self-r

Re: [HACKERS] pg_shmem_allocations view

2019-11-18 Thread Andres Freund
Hi, On 2019-11-18 21:49:55 +0900, Michael Paquier wrote: > +/* SQL SRF showing allocated shared memory */ > +Datum > +pg_get_shmem_allocations(PG_FUNCTION_ARGS) > This could be more talkative. I don't really see what it'd say, except restate the function name as a sentence? I think that kind of c

Re: [HACKERS] pg_shmem_allocations view

2019-11-18 Thread Michael Paquier
On Fri, Nov 15, 2019 at 11:59:34AM -0800, Andres Freund wrote: > On 2019-11-15 14:43:09 -0500, Robert Haas wrote: >> This never got applied, and that annoyed me again today, so here's a >> new version that I've whacked around somewhat and propose to commit. I >> ripped out the stuff pertaining to d

Re: [HACKERS] pg_shmem_allocations view

2019-11-15 Thread Andres Freund
Hi, On 2019-11-15 14:43:09 -0500, Robert Haas wrote: > On Thu, May 5, 2016 at 7:01 PM Andres Freund wrote: > > Here's a rebased version. I remember why I didn't call the column > > "offset" (as Michael complained about upthread), it's a keyword... > > This never got applied, and that annoyed me

Re: [HACKERS] pg_shmem_allocations view

2019-11-15 Thread Tom Lane
Robert Haas writes: > This never got applied, and that annoyed me again today, so here's a > new version that I've whacked around somewhat and propose to commit. > ... > Other things I changed: > - Doc edits. > - Added REVOKE statements as proposed by Michael (and I agree). > - Can't patch pg_proc

Re: [HACKERS] pg_shmem_allocations view

2019-11-15 Thread Robert Haas
On Thu, May 5, 2016 at 7:01 PM Andres Freund wrote: > Here's a rebased version. I remember why I didn't call the column > "offset" (as Michael complained about upthread), it's a keyword... This never got applied, and that annoyed me again today, so here's a new version that I've whacked around s