| From: | "Merlin Moncure" <merlin(dot)moncure(at)rcsonline(dot)com> |
|---|---|
| To: | "Magnus Hagander" <mha(at)sollentuna(dot)net> |
| Cc: | "pgsql-hackers-win32" <pgsql-hackers-win32(at)postgresql(dot)org> |
| Subject: | Re: Win32 signal code - first try |
| Date: | 2004-01-08 22:17:27 |
| Message-ID: | 303E00EBDD07B943924382E153890E5434AA42@cuthbert.rcsinc.local |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers-win32 |
Magnus Hagander wrote:
> >Have you have given up on using a kernel mode driver to throw a
thread
> >into alertable state?
>
> I think we agreed that we'd go with the polling method if it worked
well
> enough, so we don't need a kernel driver. If that doesn't work out,
the
> kernel driver would be the fallback method.
That makes sense.
> Looking at this code, I'm thinking we can probably do away with the
> critical section alltogether. All that code now executes on the main
> thread. Does this seem correct?
Yep, now everything becomes very lightweight implementation-wise.
Virtually all the code runs in the main thread.
One quick point:
WaitForMultipleObjectsEx(0,NULL,FALSE,0,TRUE); fails. Just as
WaitForSingleObjects(0, 0, TRUE) also fails.
It is not clear from the documentation if this sets the thread to
altertable, and I don't know if this is predictable behavior. My
timings were based on WFSOEx with a dummy event.
Also, all signals will be run FIFO. Is this acceptable? (maybe a unix
expert could chime in here).
Merlin
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andrew Dunstan | 2004-01-08 22:53:20 | Re: Win32 signal code - first try |
| Previous Message | Magnus Hagander | 2004-01-08 21:56:38 | Re: Win32 signal code - first try |