77#define LOOPS_UNTIL_HIBERNATE 50
78#define HIBERNATE_FACTOR 25
89 sigjmp_buf local_sigjmp_buf;
91 int left_till_hibernate;
94 Assert(startup_data_len == 0);
148 if (sigsetjmp(local_sigjmp_buf, 1) != 0)
232 if (hibernating != (left_till_hibernate <= 1))
234 hibernating = (left_till_hibernate <= 1);
250 else if (left_till_hibernate > 0)
251 left_till_hibernate--;
261 if (left_till_hibernate > 0)
269 WAIT_EVENT_WAL_WRITER_MAIN);
void AuxiliaryProcessMainCommon(void)
void AtEOXact_Buffers(bool isCommit)
#define Assert(condition)
bool ConditionVariableCancelSleep(void)
void AtEOXact_HashTables(bool isCommit)
void EmitErrorReport(void)
ErrorContextCallback * error_context_stack
void FlushErrorState(void)
sigjmp_buf * PG_exception_stack
void AtEOXact_Files(bool isCommit)
void SignalHandlerForShutdownRequest(SIGNAL_ARGS)
void SignalHandlerForConfigReload(SIGNAL_ARGS)
void HandleMainLoopInterrupts(void)
void ResetLatch(Latch *latch)
int WaitLatch(Latch *latch, int wakeEvents, long timeout, uint32 wait_event_info)
#define WL_EXIT_ON_PM_DEATH
void LWLockReleaseAll(void)
void MemoryContextReset(MemoryContext context)
MemoryContext TopMemoryContext
#define AllocSetContextCreate
#define ALLOCSET_DEFAULT_SIZES
#define RESUME_INTERRUPTS()
#define HOLD_INTERRUPTS()
BackendType MyBackendType
void pgstat_report_wal(bool force)
pqsigfunc pqsignal(int signo, pqsigfunc func)
void procsignal_sigusr1_handler(SIGNAL_ARGS)
MemoryContextSwitchTo(old_ctx)
void ReleaseAuxProcessResources(bool isCommit)
void pg_usleep(long microsec)
static void pgstat_report_wait_end(void)
#define LOOPS_UNTIL_HIBERNATE
void WalWriterMain(char *startup_data, size_t startup_data_len)
#define DEFAULT_WAL_WRITER_FLUSH_AFTER
void SetWalWriterSleeping(bool sleeping)
bool XLogBackgroundFlush(void)