Generational memory allocator

Add new style of memory allocator, known as Generational
appropriate for use in cases where memory is allocated
and then freed in roughly oldest first order (FIFO).

Use new allocator for logical decoding’s reorderbuffer
to significantly reduce memory usage and improve performance.

Author: Tomas Vondra
Reviewed-by: Simon Riggs

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/a4ccc1cef5a04cc054af83bc4582a045d5232cb3

Modified Files
--------------
src/backend/replication/logical/reorderbuffer.c |  80 +--
src/backend/utils/mmgr/Makefile                 |   2 +-
src/backend/utils/mmgr/README                   |  23 +
src/backend/utils/mmgr/generation.c             | 768 ++++++++++++++++++++++++
src/include/nodes/memnodes.h                    |   4 +-
src/include/nodes/nodes.h                       |   1 +
src/include/replication/reorderbuffer.h         |  15 +-
src/include/utils/memutils.h                    |   5 +
8 files changed, 819 insertions(+), 79 deletions(-)

Reply via email to