=== Applying patches on top of PostgreSQL commit ID 87b05fdc73e84d6b0bf0e03efad95c99c203cd1f === /etc/rc.d/jail: WARNING: Per-jail configuration via jail_* variables is obsolete. Please consider migrating to /etc/jail.conf. Mon Jul 7 20:43:20 UTC 2025 On branch cf/5575 nothing to commit, working tree clean === using 'git am' to apply patch ./v7-0001-Elimination-of-the-repetitive-code-at-the-SLRU-bo.patch === Applying: Elimination of the repetitive code at the SLRU bootstrapping and nullifying functions. Using index info to reconstruct a base tree... M src/backend/access/transam/clog.c M src/backend/access/transam/commit_ts.c M src/backend/access/transam/multixact.c M src/backend/access/transam/slru.c M src/backend/access/transam/subtrans.c M src/backend/access/transam/xloginsert.c M src/include/access/slru.h M src/include/access/xloginsert.h Falling back to patching base and 3-way merge... Auto-merging src/include/access/xloginsert.h Auto-merging src/include/access/slru.h Auto-merging src/backend/access/transam/xloginsert.c Auto-merging src/backend/access/transam/subtrans.c CONFLICT (content): Merge conflict in src/backend/access/transam/subtrans.c Auto-merging src/backend/access/transam/slru.c Auto-merging src/backend/access/transam/multixact.c CONFLICT (content): Merge conflict in src/backend/access/transam/multixact.c Auto-merging src/backend/access/transam/commit_ts.c CONFLICT (content): Merge conflict in src/backend/access/transam/commit_ts.c Auto-merging src/backend/access/transam/clog.c CONFLICT (content): Merge conflict in src/backend/access/transam/clog.c error: Failed to merge in the changes. hint: Use 'git am --show-current-patch=diff' to see the failed patch Patch failed at 0001 Elimination of the repetitive code at the SLRU bootstrapping and nullifying functions. When you have resolved this problem, run "git am --continue". If you prefer to skip this patch, run "git am --skip" instead. To restore the original branch and stop patching, run "git am --abort". Unstaged changes after reset: M src/backend/access/transam/clog.c M src/backend/access/transam/commit_ts.c M src/backend/access/transam/multixact.c M src/backend/access/transam/slru.c M src/backend/access/transam/subtrans.c M src/backend/access/transam/xloginsert.c M src/include/access/slru.h M src/include/access/xloginsert.h === using patch(1) to apply patch ./v7-0001-Elimination-of-the-repetitive-code-at-the-SLRU-bo.patch === patching file src/backend/access/transam/clog.c Hunk #1 FAILED at 110. Hunk #2 FAILED at 832. Hunk #3 FAILED at 975. Hunk #4 FAILED at 1067. Hunk #5 FAILED at 1114. 5 out of 5 hunks FAILED -- saving rejects to file src/backend/access/transam/clog.c.rej patching file src/backend/access/transam/commit_ts.c Hunk #1 FAILED at 114. Hunk #2 FAILED at 602. Hunk #3 FAILED at 747. Hunk #4 FAILED at 868. Hunk #5 FAILED at 982. Hunk #6 FAILED at 1023. 6 out of 6 hunks FAILED -- saving rejects to file src/backend/access/transam/commit_ts.c.rej patching file src/backend/access/transam/multixact.c Hunk #1 FAILED at 401. Hunk #2 FAILED at 413. Hunk #3 FAILED at 2033. Hunk #4 FAILED at 2134. Hunk #5 FAILED at 2569. Hunk #6 FAILED at 2612. Hunk #7 FAILED at 3347. Hunk #8 FAILED at 3401. 8 out of 8 hunks FAILED -- saving rejects to file src/backend/access/transam/multixact.c.rej patching file src/backend/access/transam/slru.c Hunk #1 succeeded at 189 (offset -1 lines). Hunk #2 succeeded at 361 (offset -1 lines). patching file src/backend/access/transam/subtrans.c Hunk #1 FAILED at 74. Hunk #2 FAILED at 269. Hunk #3 FAILED at 335. Hunk #4 FAILED at 395. 4 out of 4 hunks FAILED -- saving rejects to file src/backend/access/transam/subtrans.c.rej patching file src/backend/access/transam/xloginsert.c Hunk #1 succeeded at 1402 (offset 12 lines). patching file src/include/access/slru.h Hunk #1 succeeded at 186 with fuzz 2. patching file src/include/access/xloginsert.h Hunk #1 succeeded at 65 (offset 1 line). Unstaged changes after reset: M src/backend/access/transam/slru.c M src/backend/access/transam/xloginsert.c M src/include/access/slru.h M src/include/access/xloginsert.h Removing src/backend/access/transam/clog.c.rej Removing src/backend/access/transam/commit_ts.c.rej Removing src/backend/access/transam/multixact.c.rej Removing src/backend/access/transam/subtrans.c.rej === using 'git apply' to apply patch ./v7-0001-Elimination-of-the-repetitive-code-at-the-SLRU-bo.patch === Applied patch to 'src/backend/access/transam/clog.c' with conflicts. Applied patch to 'src/backend/access/transam/commit_ts.c' with conflicts. Applied patch to 'src/backend/access/transam/multixact.c' with conflicts. Applied patch to 'src/backend/access/transam/slru.c' cleanly. Applied patch to 'src/backend/access/transam/subtrans.c' with conflicts. Applied patch to 'src/backend/access/transam/xloginsert.c' cleanly. Applied patch to 'src/include/access/slru.h' cleanly. Applied patch to 'src/include/access/xloginsert.h' cleanly. U src/backend/access/transam/clog.c U src/backend/access/transam/commit_ts.c U src/backend/access/transam/multixact.c U src/backend/access/transam/subtrans.c diff --cc src/backend/access/transam/clog.c index e80fbe109cf,e9ac93be9fa..00000000000 --- a/src/backend/access/transam/clog.c +++ b/src/backend/access/transam/clog.c @@@ -830,8 -830,10 +830,15 @@@ check_transaction_buffers(int *newval, void BootStrapCLOG(void) { ++<<<<<<< ours + /* Zero the initial page and flush it to disk */ + SimpleLruZeroAndWritePage(XactCtl, 0); ++======= + /* + * Nullify the page (pageno = 0) and save the page on a disk + */ + SimpleLruZeroPageExt(XactCtl, 0); ++>>>>>>> theirs } /* @@@ -939,9 -941,9 +946,15 @@@ ExtendCLOG(TransactionId newestXact LWLockAcquire(lock, LW_EXCLUSIVE); ++<<<<<<< ours + /* Zero the page and make a WAL entry about it */ + SimpleLruZeroPage(XactCtl, pageno); + XLogSimpleInsertInt64(RM_CLOG_ID, CLOG_ZEROPAGE, pageno); ++======= + /* Zero the page and make an XLOG entry about it */ + SimpleLruZeroPage(XactCtl, pageno); + XLogSimpleInsert(RM_CLOG_ID, CLOG_ZEROPAGE, pageno); ++>>>>>>> theirs LWLockRelease(lock); } @@@ -1069,9 -1071,9 +1082,15 @@@ clog_redo(XLogReaderState *record if (info == CLOG_ZEROPAGE) { int64 pageno; ++<<<<<<< ours + + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + SimpleLruZeroAndWritePage(XactCtl, pageno); ++======= + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + /* Zero the page, write the page on a disk */ + SimpleLruZeroPageExt(XactCtl, pageno); ++>>>>>>> theirs } else if (info == CLOG_TRUNCATE) { diff --cc src/backend/access/transam/commit_ts.c index 370b38e048b,d8c04a0ff63..00000000000 --- a/src/backend/access/transam/commit_ts.c +++ b/src/backend/access/transam/commit_ts.c @@@ -730,7 -723,8 +730,12 @@@ ActivateCommitTs(void /* Create the current segment file, if necessary */ if (!SimpleLruDoesPhysicalPageExist(CommitTsCtl, pageno)) ++<<<<<<< ours + SimpleLruZeroAndWritePage(CommitTsCtl, pageno); ++======= + /* Zero the page, write the page on a disk */ + SimpleLruZeroPageExt(CommitTsCtl, pageno); ++>>>>>>> theirs /* Change the activation status in shared memory. */ LWLockAcquire(CommitTsLock, LW_EXCLUSIVE); @@@ -841,12 -835,11 +846,20 @@@ ExtendCommitTs(TransactionId newestXact LWLockAcquire(lock, LW_EXCLUSIVE); ++<<<<<<< ours + /* Zero the page ... */ + SimpleLruZeroPage(CommitTsCtl, pageno); + + /* and make a WAL entry about that, unless we're in REDO */ + if (!InRecovery) + XLogSimpleInsertInt64(RM_COMMIT_TS_ID, COMMIT_TS_ZEROPAGE, pageno); ++======= + /* Zero the page and make an XLOG entry about it */ + SimpleLruZeroPage(CommitTsCtl, pageno); + + if (!InRecovery) + XLogSimpleInsert(RM_COMMIT_TS_ID, COMMIT_TS_ZEROPAGE, pageno); ++>>>>>>> theirs LWLockRelease(lock); } @@@ -990,9 -983,10 +1003,16 @@@ commit_ts_redo(XLogReaderState *record if (info == COMMIT_TS_ZEROPAGE) { int64 pageno; ++<<<<<<< ours + + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + SimpleLruZeroAndWritePage(CommitTsCtl, pageno); ++======= + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + + /* Zero the page, write the page on a disk */ + SimpleLruZeroPageExt(CommitTsCtl, pageno); ++>>>>>>> theirs } else if (info == COMMIT_TS_TRUNCATE) { diff --cc src/backend/access/transam/multixact.c index 3cb09c3d598,9839037d3d3..00000000000 --- a/src/backend/access/transam/multixact.c +++ b/src/backend/access/transam/multixact.c @@@ -2030,9 -2030,11 +2030,17 @@@ check_multixact_member_buffers(int *new void BootStrapMultiXact(void) { ++<<<<<<< ours + /* Zero the initial pages and flush them to disk */ + SimpleLruZeroAndWritePage(MultiXactOffsetCtl, 0); + SimpleLruZeroAndWritePage(MultiXactMemberCtl, 0); ++======= + /* + * Nullify the page (pageno = 0), save the page on a disk + */ + SimpleLruZeroPageExt(MultiXactOffsetCtl, 0); + SimpleLruZeroPageExt(MultiXactMemberCtl, 0); ++>>>>>>> theirs } /* @@@ -2504,10 -2506,9 +2512,16 @@@ ExtendMultiXactOffset(MultiXactId multi LWLockAcquire(lock, LW_EXCLUSIVE); ++<<<<<<< ours + /* Zero the page and make a WAL entry about it */ + SimpleLruZeroPage(MultiXactOffsetCtl, pageno); + XLogSimpleInsertInt64(RM_MULTIXACT_ID, XLOG_MULTIXACT_ZERO_OFF_PAGE, + pageno); ++======= + /* Zero the page and make an XLOG entry about it */ + SimpleLruZeroPage(MultiXactOffsetCtl, pageno); + XLogSimpleInsert(RM_MULTIXACT_ID, XLOG_MULTIXACT_ZERO_OFF_PAGE, pageno); ++>>>>>>> theirs LWLockRelease(lock); } @@@ -2549,10 -2550,9 +2563,16 @@@ ExtendMultiXactMember(MultiXactOffset o LWLockAcquire(lock, LW_EXCLUSIVE); ++<<<<<<< ours + /* Zero the page and make a WAL entry about it */ + SimpleLruZeroPage(MultiXactMemberCtl, pageno); + XLogSimpleInsertInt64(RM_MULTIXACT_ID, + XLOG_MULTIXACT_ZERO_MEM_PAGE, pageno); ++======= + /* Zero the page and make an XLOG entry about it */ + SimpleLruZeroPage(MultiXactMemberCtl, pageno); + XLogSimpleInsert(RM_MULTIXACT_ID, XLOG_MULTIXACT_ZERO_MEM_PAGE, pageno); ++>>>>>>> theirs LWLockRelease(lock); } @@@ -3329,16 -3329,16 +3349,28 @@@ multixact_redo(XLogReaderState *record if (info == XLOG_MULTIXACT_ZERO_OFF_PAGE) { int64 pageno; ++<<<<<<< ours + + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + SimpleLruZeroAndWritePage(MultiXactOffsetCtl, pageno); ++======= + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + /* Zero the page, write the page on a disk */ + SimpleLruZeroPageExt(MultiXactOffsetCtl, pageno); ++>>>>>>> theirs } else if (info == XLOG_MULTIXACT_ZERO_MEM_PAGE) { int64 pageno; ++<<<<<<< ours + + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + SimpleLruZeroAndWritePage(MultiXactMemberCtl, pageno); ++======= + memcpy(&pageno, XLogRecGetData(record), sizeof(pageno)); + /* Zero the page, write the page on a disk */ + SimpleLruZeroPageExt(MultiXactMemberCtl, pageno); ++>>>>>>> theirs } else if (info == XLOG_MULTIXACT_CREATE_ID) { diff --cc src/backend/access/transam/subtrans.c index 09aace9e09f,e597f54fb1e..00000000000 --- a/src/backend/access/transam/subtrans.c +++ b/src/backend/access/transam/subtrans.c @@@ -268,8 -268,10 +268,15 @@@ check_subtrans_buffers(int *newval, voi void BootStrapSUBTRANS(void) { ++<<<<<<< ours + /* Zero the initial page and flush it to disk */ + SimpleLruZeroAndWritePage(SubTransCtl, 0); ++======= + /* + * Nullify the page (pageno = 0), save the page on a disk + */ + SimpleLruZeroPageExt(SubTransCtl, 0); ++>>>>>>> theirs } /*