Re: sb_alloc: a new memory allocator for PostgreSQL - Mailing list pgsql-hackers

From Greg Stark
Subject Re: sb_alloc: a new memory allocator for PostgreSQL
Date
Msg-id CAM-w4HPBgoLcaT-xqEXzVg9ONVSn1AB_Z7qbSxN_iN1JccmJJw@mail.gmail.com
Whole thread Raw
In response to sb_alloc: a new memory allocator for PostgreSQL  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: sb_alloc: a new memory allocator for PostgreSQL  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
On Tue, May 6, 2014 at 2:04 PM, Robert Haas <robertmhaas@gmail.com> wrote:
>  I also didn't find anything that looked like our
> memory context paradigm, and in particular the ability to cheaply
> reset a context, in any other allocator.


You probably knew this but just in case the term for this strategy is
called a "ripcord allocator". I believe GCC had one, not sure if it
still uses it. I doubt any existing ones are especially helpful though
compared to looking at regular allocators and seeing how to integrate
them.

I assume you're also aware of lock-free data structures and the like.
A memory allocator seems like something that needs to be super aware
of causing concurrency bottlenecks since it has no idea where it'll be
used.

-- 
greg



pgsql-hackers by date:

Previous
From: Noah Misch
Date:
Subject: Re: [PATCH] `pg_dump -Fd` doesn't check write return status...
Next
From: Heikki Linnakangas
Date:
Subject: Re: sb_alloc: a new memory allocator for PostgreSQL