Hello All -

I have completed my draft native-windows support for mingw's std::thread.

On Wed, Oct 20, 2010 at 12:48 AM, K. Frank <[email protected]> wrote:
> ...
> I have an update on timed mutex waits for mingw support for std::thread.
>
> On Tue, Oct 12, 2010 at 10:50 PM, K. Frank <[email protected]> wrote:
>> ...
>> I have put together a first cut at mingw support for std::thread.
>> ...

I've developed and tested the implementation on windows 7, and I expect
that it will only work on windows vista and above.

All of the basic threading and synchronization functionality seems to  be
working.  I haven't tried everything, but I have written test programs that
exercise the core functionality, and have run some of the gnu std::thread
test suite by hand.  I don't know of anything that doesn't work.

(With one exception: With mingw32 / g++ 4.5.0, I cannot instantiate a
std::future, but I can with mingw-w64 / g++ 4.5.2.  I am guessing that
this is a 4.5.0 issue, rather than a mingw32-specific issue, or a problem
with the threading implementation.)

To summarize what was stated in an earlier post, this implementation
provides wrapper code that translates the pthreads-like gthreads interface
used by gnu's std::thread into native windows calls using native windows
threads (i.e., _beginthreadex), critical sections, and condition variables.
(The use of native windows condition variables is the primary reason this
implementation is limited to windows vista and above.)

Any suggestions about how to integrate this into the mingw32 and mingw-w64
distributions or help with testing would we appreciated.

In the meantime my focus will be playing around with std::thread (which I
don't really know how to use yet), rather than tweaking the implementation.
(From what I've seen so far of std::thread, it looks pretty good.  It's worth a
look, if you like playing around with that sort of thing.  I believe
that std::thread
will work out of the box with recent linux versions of gcc.)

Thanks.


K. Frank

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to