pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@postgresql.org
Subject: pgsql: Reduce the number of pallocs() in BRIN
Date: Fri, 07 Apr 2017 22:09:12 +0000
Message-ID: <E1cwc48-0004mI-Nj@gemulon.postgresql.org> (raw)
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

Reduce the number of pallocs() in BRIN

Instead of allocating memory in brin_deform_tuple and brin_copy_tuple
over and over during a scan, allow reuse of previously allocated memory.
This is said to make for a measurable performance improvement.

Author: Jinyu Zhang, Álvaro Herrera
Reviewed by: Tomas Vondra
Discussion: https://postgr.es/m/495deb78.4186.1500dacaa63.Coremail.beijing_pg@163.com

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/8bf74967dab1b368f4e217c960ede1516c42a989

Modified Files
--------------
contrib/pageinspect/brinfuncs.c        |  3 +-
src/backend/access/brin/brin.c         | 24 +++++++----
src/backend/access/brin/brin_pageops.c |  4 +-
src/backend/access/brin/brin_tuple.c   | 77 +++++++++++++++++++++-------------
src/include/access/brin_tuple.h        | 12 ++++--
5 files changed, 78 insertions(+), 42 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


Message-ID: <E1cwc48-0004mI-Nj@gemulon.postgresql.org>
Permalink:  ../E1cwc48-0004mI-Nj@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1cwc48-0004mI-Nj@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: alvherre@alvh.no-ip.org
  Subject: Re: pgsql: Reduce the number of pallocs() in BRIN
  In-Reply-To: <E1cwc48-0004mI-Nj@gemulon.postgresql.org>
  References: <E1cwc48-0004mI-Nj@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox