Re: Correct the documentation for work_mem

From: "Imseih (AWS), Sami" <simseih(at)amazon(dot)com>
To: Gurjeet Singh <gurjeet(at)singh(dot)im>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Correct the documentation for work_mem
Date: 2023-04-22 03:36:15
Message-ID: 8A8E60F6-D4A7-499D-8E4A-3D5C0F1743E1@amazon.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> > especially since the next sentence uses "concurrently" to describe the
> > other case. I think we need a more thorough rewording, perhaps like
> >
> > - Note that for a complex query, several sort or hash operations might be
> > - running in parallel; each operation will generally be allowed
> > + Note that a complex query may include several sort or hash
> > + operations; each such operation will generally be allowed

> This wording doesn't seem to bring out the fact that there could be
> more than one work_mem consumer running (in-progress) at the same
> time.

Do you mean, more than one work_mem consumer running at the same
time for a given query? If so, that is precisely the point we need to convey
in the docs.

i.e. if I have 2 sorts in a query that can use up to 4MB each, at some point
in the query execution, I can have 8MB of memory allocated.

Regards,

Sami Imseih
Amazon Web Services (AWS)

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Nathan Bossart 2023-04-22 04:44:51 Re: Move un-parenthesized syntax docs to "compatibility" for few SQL commands
Previous Message Robert Haas 2023-04-22 00:12:59 Re: Order changes in PG16 since ICU introduction