Re: [PATCHES] Win32 CHECK_FOR_INTERRUPTS() performance tweak

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [PATCHES] Win32 CHECK_FOR_INTERRUPTS() performance tweak
Дата
Msg-id 25762.1129929284@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [PATCHES] Win32 CHECK_FOR_INTERRUPTS() performance tweak  ("Merlin Moncure" <merlin.moncure@rcsonline.com>)
Ответы Re: [PATCHES] Win32 CHECK_FOR_INTERRUPTS() performance tweak  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
BTW, expanding on Andrew's comment, ISTM we could move the kernel call
out of the macro, ie make it look like

#define CHECK_FOR_INTERRUPTS() \
do { \   if (UNBLOCKED_SIGNAL_QUEUE()) \       pgwin32_check_queued_signals(); \   if (InterruptPending) \
ProcessInterrupts();\
 
} while(0)

where pgwin32_check_queued_signals() is just
   if (WaitForSingleObjectEx(pgwin32_signal_event,0,TRUE) == WAIT_OBJECT_0)       pgwin32_dispatch_queued_signals();

This would save a few bytes at each call site while not really costing
anything in performance.
        regards, tom lane


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Qingqing Zhou
Дата:
Сообщение: Re: [PATCHES] Win32 CHECK_FOR_INTERRUPTS() performance
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Seeing context switch storm with 10/13 snapshot of