postgresql/contrib/pg_buffercache
Michael Paquier 580b5c2f39 pg_buffercache: Fix memory allocation formula
The code over-allocated the memory required for os_page_status, relying
on uint64 for its element size instead of an int, hence doubling what
was required.  This could mean quite a lot of memory if dealing with a
lot of NUMA pages.

Oversight in ba2a3c2302.

Author: David Geier <geidav.pg@gmail.com>
Discussion: https://postgr.es/m/ad0748d4-3080-436e-b0bc-ac8f86a3466a@gmail.com
Backpatch-through: 18
2025-12-11 14:11:25 +09:00
..
expected Add pg_buffercache_evict_{relation,all} functions 2025-04-08 02:19:32 -04:00
sql Add pg_buffercache_evict_{relation,all} functions 2025-04-08 02:19:32 -04:00
.gitignore Add regression test coverage for contrib/pg_buffercache. 2022-07-30 15:33:44 -04:00
Makefile Add pg_buffercache_numa view with NUMA node info 2025-04-07 23:08:17 +02:00
meson.build Add pg_buffercache_numa view with NUMA node info 2025-04-07 23:08:17 +02:00
pg_buffercache--1.0--1.1.sql Add pinning_backends column to the pg_buffercache extension. 2014-08-22 00:28:37 +02:00
pg_buffercache--1.1--1.2.sql Update pg_buffercache extension for parallel query. 2016-06-09 17:18:12 -04:00
pg_buffercache--1.2--1.3.sql Default monitoring roles 2017-03-30 14:18:53 -04:00
pg_buffercache--1.2.sql Update pg_buffercache extension for parallel query. 2016-06-09 17:18:12 -04:00
pg_buffercache--1.3--1.4.sql Add pg_buffercache_usage_counts() to contrib/pg_buffercache. 2023-04-07 14:25:53 -04:00
pg_buffercache--1.4--1.5.sql Add pg_buffercache_evict() function for testing. 2024-04-08 16:23:40 +12:00
pg_buffercache--1.5--1.6.sql pg_buffercache: Change page_num type to bigint 2025-04-08 12:38:42 +02:00
pg_buffercache.control Add pg_buffercache_numa view with NUMA node info 2025-04-07 23:08:17 +02:00
pg_buffercache_pages.c pg_buffercache: Fix memory allocation formula 2025-12-11 14:11:25 +09:00