Re: [HACKERS] [PATCHES] fork/exec patch

Поиск
Список
Период
Сортировка
От Steve Tibbett
Тема Re: [HACKERS] [PATCHES] fork/exec patch
Дата
Msg-id 546CD3100F4C0F42A30A94C0F2B349148FC666@zimmail1.zim.zimismobile.com
обсуждение исходный текст
Список pgsql-hackers-win32
>Right. Just like select() puts your thread to sleep until one of its
files is ready (or it times out).
>Do we have a terminology problem here?

Ah I see what you're saying, the polling isn't the WaitForSingleObject,
it's that the main thread that's going to have to poll something to see
if the thread that's doing the WaitForSingleObject has woken up and set
a signal or something.

WaitForSingleObject itself isn't polling the same way select() isn't
polling..

Anyway, this article has an interesting twist on the issue:

http://www.codeproject.com/threads/queueuserapcex.asp

It uses a driver to set a thread into an alertable state, so that an APC
sent with QueueUserAPC() can be delivered any time.  It's kinda messy
that it has to use a driver to get the job done but OTOH it gives you
signals that work pretty similarly to what you get with Unix I believe.

--
Steve Tibbett
stibbett@zim.biz


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

Предыдущее
От: "Magnus Hagander"
Дата:
Сообщение: Re: [HACKERS] [PATCHES] fork/exec patch
Следующее
От: "Merlin Moncure"
Дата:
Сообщение: Re: [HACKERS] [PATCHES] fork/exec patch