pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: David Rowley <dgrowleyml@gmail.com>
Cc: Tomas Vondra <tomas.vondra@enterprisedb.com>
Cc: Amit Kapila <amit.kapila16@gmail.com>
Cc: Andres Freund <andres@anarazel.de>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Yura Sokolov <y.sokolov@postgrespro.ru>
Cc: PostgreSQL Developers <pgsql-hackers@lists.postgresql.org>
Subject: Re: Reducing the chunk header sizes on all memory context types
Date: Mon, 29 Aug 2022 11:25:57 -0400
Message-ID: <3207033.1661786757@sss.pgh.pa.us> (raw)
In-Reply-To: <3205803.1661786437@sss.pgh.pa.us>
References: <CAApHDvpjauCRXcgcaL6+e3eqecEHoeRm9D-kcbuvBitgPnW=vw@mail.gmail.com>
	<CAApHDvo+R56uR7Hd9d7f6+EKEeXs8azsshrAgL9HOsnj7K4-YA@mail.gmail.com>
	<CAApHDvrrYfcCXfuc_bZ0xsqBP8U62Y0i27agr9Qt-2geE_rv0Q@mail.gmail.com>
	<CA+TgmoZcHxSZRN1HhHKT-g=FBk2THH60zy1sK3YwB6cB4EQqtQ@mail.gmail.com>
	<20220809184410.g6yzu6pvttuphag5@awork3.anarazel.de>
	<CAApHDvq8Mn8EiK_giG3TQ_=bgzSBvsWTi0KkY0Zv4RrA1kjRQQ@mail.gmail.com>
	<CAApHDvrVppH=3NKzhD0v1XkHyWiT+DkdfOdnQPo=BgauVcL7fw@mail.gmail.com>
	<CAApHDvpuhcPWCzkXZuQQgB8YjPNQSvnncbzZ6pwpHFr2QMMD2w@mail.gmail.com>
	<CAApHDvrCkmvdcnyGBtxq6D8FfM50UiunN3qJquTBwOdUqoKYvg@mail.gmail.com>
	<CAApHDvo3ZaWQNO2AKYiH8y3oGKxWfa2EAkZz9peGBnXvZe2hvA@mail.gmail.com>
	<CAApHDvrbd3y4QxRANd7oFZBXVJ7ZmwUjxSYDLFEMOZY8uyQzRg@mail.gmail.com>
	<CAApHDvrvWMqB6kR-=6qz7n+Jb4Et8VkfnOufwKKLDz5kOm=AEA@mail.gmail.com>
	<CAApHDvociYOk=OTxw0XmO9BR38Covk13M_wg8nt8N7aySWKbLw@mail.gmail.com>
	<3137572.1661780863@sss.pgh.pa.us>
	<CAA4eK1LGx6WW4UPn5-h4KhRCP_NLbNih+si1vpA6KU8TvHgung@mail.gma! il.com>
	<f1d04651-caf9-5c6d-1bf0-c9feac16df10@enterprisedb.com>
	<3205803.1661786437@sss.pgh.pa.us>

I wrote:
> So the bug is in fact in David's changes, and it consists in palloc
> sometimes handing back non-maxaligned pointers.  I find it mildly
> astonishing that we managed to get through core regression tests
> without such a fault surfacing, but there you have it.

Oh!  I just noticed that the troublesome context (rb->change_context)
is a SlabContext, so it may be that this only happens in non-aset
contexts.  It's a lot easier to believe that the core tests never
exercise the case of pfree'ing a slab chunk.

			regards, tom lane





view thread (152+ messages)  latest in thread

Message-ID: <3207033.1661786757@sss.pgh.pa.us>
Permalink:  ../3207033.1661786757@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/3207033.1661786757@sss.pgh.pa.us

 · 

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-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, dgrowleyml@gmail.com, tomas.vondra@enterprisedb.com, amit.kapila16@gmail.com, andres@anarazel.de, robertmhaas@gmail.com, y.sokolov@postgrespro.ru
  Subject: Re: Reducing the chunk header sizes on all memory context types
  In-Reply-To: <3207033.1661786757@sss.pgh.pa.us>
  References: <CAApHDvpjauCRXcgcaL6+e3eqecEHoeRm9D-kcbuvBitgPnW=vw@mail.gmail.com> <CAApHDvrrYfcCXfuc_bZ0xsqBP8U62Y0i27agr9Qt-2geE_rv0Q@mail.gmail.com> <CA+TgmoZcHxSZRN1HhHKT-g=FBk2THH60zy1sK3YwB6cB4EQqtQ@mail.gmail.com> <20220809184410.g6yzu6pvttuphag5@awork3.anarazel.de> <CAApHDvq8Mn8EiK_giG3TQ_=bgzSBvsWTi0KkY0Zv4RrA1kjRQQ@mail.gmail.com> <CAApHDvrVppH=3NKzhD0v1XkHyWiT+DkdfOdnQPo=BgauVcL7fw@mail.gmail.com> <CAApHDvpuhcPWCzkXZuQQgB8YjPNQSvnncbzZ6pwpHFr2QMMD2w@mail.gmail.com> <CAApHDvrCkmvdcnyGBtxq6D8FfM50UiunN3qJquTBwOdUqoKYvg@mail.gmail.com> <CAApHDvo3ZaWQNO2AKYiH8y3oGKxWfa2EAkZz9peGBnXvZe2hvA@mail.gmail.com> <CAApHDvrbd3y4QxRANd7oFZBXVJ7ZmwUjxSYDLFEMOZY8uyQzRg@mail.gmail.com> <CAApHDvrvWMqB6kR-=6qz7n+Jb4Et8VkfnOufwKKLDz5kOm=AEA@mail.gmail.com> <CAApHDvociYOk=OTxw0XmO9BR38Covk13M_wg8nt8N7aySWKbLw@mail.gmail.com> <3137572.1661780863@sss.pgh.pa.us> <f1d04651-caf9-5c6d-1bf0-c9feac16df10@enterprisedb.com> <3205803.1661786437@sss.pgh.pa.us> <3207033.1661786757@sss.pgh.pa.us>

* 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