Re: memory leak in e94568ecc10 (pre-reading in external sort)

From: Peter Geoghegan <pg(at)heroku(dot)com>
To: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Cc: Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: memory leak in e94568ecc10 (pre-reading in external sort)
Date: 2016-10-06 16:03:25
Message-ID: CAM3SWZTGkT_2B_3uG0n3XtDjTEY10QLrgkqUf8x4Vms3pODkxw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Oct 6, 2016 at 8:44 AM, Peter Geoghegan <pg(at)heroku(dot)com> wrote:
> Besides, what I propose to do is really exactly the same as what you
> also want to do, except it avoids actually changing state->maxTapes.
> We'd just pass down what you propose to assign to state->maxTapes
> directly, which differs (and not just in the common case where there
> are inactive tapes -- it's always at least off-by-one). Right?

What I mean is that you should pass down numTapes alongside
numInputTapes. The function init_tape_buffers() could either have an
additional argument (numTapes), or derive numTapes itself.

--
Peter Geoghegan

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Serge Rielau 2016-10-06 16:12:23 Re: Fast AT ADD COLUMN with DEFAULTs
Previous Message Tom Lane 2016-10-06 16:01:12 Re: Fast AT ADD COLUMN with DEFAULTs