Re: array_agg() on a set larger than some arbitrary(?) limit causes runaway memory usage and eventually memory exhaustion

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Frank van Vugt <ftm(dot)van(dot)vugt(at)foxi(dot)nl>
Cc: Tomas Vondra <tv(at)fuzzy(dot)cz>, pgsql-bugs(at)postgresql(dot)org, Valentine Gogichashvili <valgog(at)gmail(dot)com>
Subject: Re: array_agg() on a set larger than some arbitrary(?) limit causes runaway memory usage and eventually memory exhaustion
Date: 2013-10-31 14:05:16
Message-ID: 22340.1383228316@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Frank van Vugt <ftm(dot)van(dot)vugt(at)foxi(dot)nl> writes:
> Op zondag 20 oktober 2013 12:57:43 schreef Tomas Vondra:
>> Attached is a quick patch removing the local memory context and using
>> aggcontext instead.

> It looks like this didn't go into git yet. Will it be in v9.2.6/v9.3.1?

Certainly not. We can consider it for 9.4, if Tomas submits it to the
commitfest process, but it needs review and testing. In particular
I'm skeptical that it probably outright breaks some cases (look at
makeMdArrayResult) and results in substantial added bloat, not savings,
in others.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2013-10-31 15:09:10 Re: BUG #8571: Planner miss-estimates '<null_column> is not true' as not matching any rows
Previous Message przemek 2013-10-31 13:03:49 BUG #8572: Combination of SET TIME ZONEs and CAST gives wrong results