Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit23b56d1

Browse files
committed
don't elog(DEBUG1) in production in ptrack_mark_block either
1 parentf8a7400 commit23b56d1

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

‎engine.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -629,21 +629,27 @@ ptrack_mark_block(RelFileNodeBackend smgr_rnode,
629629
old_init_lsn.value=pg_atomic_read_u64(&ptrack_map->init_lsn);
630630
if (old_init_lsn.value==InvalidXLogRecPtr)
631631
{
632+
#ifUSE_ASSERT_CHECKING
632633
elog(DEBUG1,"ptrack_mark_block: init_lsn "UINT64_FORMAT" <- "UINT64_FORMAT,old_init_lsn.value,new_lsn);
634+
#endif
633635

634636
while (old_init_lsn.value<new_lsn&&
635637
!pg_atomic_compare_exchange_u64(&ptrack_map->init_lsn, (uint64*)&old_init_lsn.value,new_lsn));
636638
}
637639

638640
/* Atomically assign new LSN value to the first slot */
639641
old_lsn.value=pg_atomic_read_u64(&ptrack_map->entries[slot1]);
642+
#ifUSE_ASSERT_CHECKING
640643
elog(DEBUG3,"ptrack_mark_block: map[%zu]="UINT64_FORMAT" <- "UINT64_FORMAT,slot1,old_lsn.value,new_lsn);
644+
#endif
641645
while (old_lsn.value<new_lsn&&
642646
!pg_atomic_compare_exchange_u64(&ptrack_map->entries[slot1], (uint64*)&old_lsn.value,new_lsn));
643647

644648
/* And to the second */
645649
old_lsn.value=pg_atomic_read_u64(&ptrack_map->entries[slot2]);
650+
#ifUSE_ASSERT_CHECKING
646651
elog(DEBUG3,"ptrack_mark_block: map[%zu]="UINT64_FORMAT" <- "UINT64_FORMAT,slot2,old_lsn.value,new_lsn);
652+
#endif
647653
while (old_lsn.value<new_lsn&&
648654
!pg_atomic_compare_exchange_u64(&ptrack_map->entries[slot2], (uint64*)&old_lsn.value,new_lsn));
649655
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp