Skip site navigation (1) Skip section navigation (2)

Re: Win32 signal code - first try

From: "Magnus Hagander" <mha(at)sollentuna(dot)net>
To: "Claudio Natoli" <claudio(dot)natoli(at)memetrics(dot)com>,"Merlin Moncure " <merlin(dot)moncure(at)rcsonline(dot)com>
Cc: "pgsql-hackers-win32 " <pgsql-hackers-win32(at)postgresql(dot)org>
Subject: Re: Win32 signal code - first try
Date: 2004-01-13 16:16:14
Message-ID: 6BCB9D8A16AC4241919521715F4D8BCE2A6B04@algol.sollentuna.se (view raw or flat)
Thread:
Lists: pgsql-hackers-win32
> > It is if you use WaitForMultipleObjectsEx(). Or if you use
> > WSAEventSelect() and then WaitForSingleObjectEx() on the 
> event (this 
> > emulates select() the closest)
> 
> I'd just as soon as avoid WSAEventSelect; I think that will 
> complicate matters quite a bit.
> 
> FWIW, in a multithreaded version of postgres I'm fooling 
> around with, I replaced the recv call (where backends spend 
> most of their time waiting) which a select(small 
> timeout)/SleepEx(0) "busy" loop, which calls to recv when 
> ready. Works just fine.

It's probably not quite as fast, but that's not the point where we need
to go for max performance. It's probably an easier and smaller changes,
yes, so this looks like a good way. If it turns out bad we can always
change it later, and in that case it's good to have started with the
easy implementation :-)

//Magnus

pgsql-hackers-win32 by date

Next:From: Merlin MoncureDate: 2004-01-14 19:12:14
Subject: Microsoft releses Services for Unix
Previous:From: Claudio NatoliDate: 2004-01-12 22:37:31
Subject: Re: Win32 signal code - first try

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group