diff options
author | Michael Paquier <michael@paquier.xyz> | 2025-03-27 10:20:51 +0900 |
---|---|---|
committer | Michael Paquier <michael@paquier.xyz> | 2025-03-27 10:20:51 +0900 |
commit | e5cf186277f917c3743f34931b151c22555456d9 (patch) | |
tree | 4483cc7559846bae8af1d375e008bf4f1b32244d | |
parent | 0f60e1fba13748811f266c0564e1b3fe834299c0 (diff) |
doc: Correct description of values used in FSM for indexes
The implementation of FSM for indexes is simpler than heap, where 0 is
used to track if a page is in-use and (BLCKSZ - 1) if a page is free.
One comment in indexfsm.c and one description in the documentation of
pg_freespacemap were incorrect about that.
Author: Alex Friedman <alexf01@gmail.com>
Discussion: https://postgr.es/m/71eef655-c192-453f-ac45-2772fec2cb04@gmail.com
Backpatch-through: 13
-rw-r--r-- | doc/src/sgml/pgfreespacemap.sgml | 2 | ||||
-rw-r--r-- | src/backend/storage/freespace/indexfsm.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/doc/src/sgml/pgfreespacemap.sgml b/doc/src/sgml/pgfreespacemap.sgml index 0122d278e39..7647e6512ea 100644 --- a/doc/src/sgml/pgfreespacemap.sgml +++ b/doc/src/sgml/pgfreespacemap.sgml @@ -66,7 +66,7 @@ <para> For indexes, what is tracked is entirely-unused pages, rather than free space within pages. Therefore, the values are not meaningful, just - whether a page is full or empty. + whether a page is in-use or empty. </para> <note> diff --git a/src/backend/storage/freespace/indexfsm.c b/src/backend/storage/freespace/indexfsm.c index d975c3364b4..4788e7e7183 100644 --- a/src/backend/storage/freespace/indexfsm.c +++ b/src/backend/storage/freespace/indexfsm.c @@ -16,7 +16,7 @@ * This is similar to the FSM used for heap, in freespace.c, but instead * of tracking the amount of free space on pages, we only track whether * pages are completely free or in-use. We use the same FSM implementation - * as for heaps, using BLCKSZ - 1 to denote used pages, and 0 for unused. + * as for heaps, using 0 to denote used pages, and (BLCKSZ - 1) for unused. * *------------------------------------------------------------------------- */ |