pgsql: bufmgr: use I/O stats arguments in FlushUnlockedBuffer()

From: Melanie Plageman <melanieplageman(at)gmail(dot)com>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: bufmgr: use I/O stats arguments in FlushUnlockedBuffer()
Date: 2026-04-21 21:51:11
Message-ID: E1wFIzu-0023vr-1H@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

bufmgr: use I/O stats arguments in FlushUnlockedBuffer()

FlushUnlockedBuffer() accepted io_object and io_context arguments but
hardcoded IOOBJECT_RELATION and IOCONTEXT_NORMAL when calling
FlushBuffer(). Pass them through instead. Also fix FlushBuffer() to use
its io_object parameter for I/O timing stats rather than hardcoding
IOOBJECT_RELATION.

Not actively broken since all current callers pass IOOBJECT_RELATION and
IOCONTEXT_NORMAL, so not backpatched.

Author: Chao Li <lic(at)highgo(dot)com>
Reviewed-by: Melanie Plageman <melanieplageman(at)gmail(dot)com>
Discussion: https://postgr.es/m/BC97546F-5C15-42F2-AD57-CFACDB9657D0@gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/31b0544b32bc9e08c8c6775aed7ca2b808390f80

Modified Files
--------------
src/backend/storage/buffer/bufmgr.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2026-04-21 22:29:45 pgsql: Fix not-quite-right Makefile for src/test/modules/test_checksums
Previous Message Melanie Plageman 2026-04-21 21:34:39 pgsql: Stabilize btree_gist test against on-access VM setting