I am one of the developer of a chess engine called Stockfish:

https://github.com/official-stockfish/Stockfish

A chess engine is a high performance piece of multi-thread software, where
even a small sub-optimal code path immediately translates in a sensible
slow down.

The master version is written in C++03 and uses some low level wrappers to
get thread functionality on supported platforms:

https://github.com/official-stockfish/Stockfish/blob/master/src/platform.h

Recently we started to switch to C++11 for various reasons, but especially
due to library support for std::thread and friends. This allows us to
greatly simplify the code and getting rid of all the platform specific
wrappers.

While on Linux and on MSVC 2013 we have similar performance between C++11
and C++03 versions, under Windows with mingw there is a huge performance
gap when run in SMP mode (around 30% slower), when we run in single thread
mode speed is similar. This is particularly unfortunate because our release
version is compiled with gcc for all the platforms because currently gcc
gives the best speed.

After some analysis we realized the speed difference is all due to thread
library implementation on mingw that is based on POSIX instead of native
Win32 threads.

We have goggled around for some specific version of mingw that used win32
_and_ supports std::thread, but we have found nothing so far.

So I would like to ask:

1. There exists somewhere a mingw-w64 build supporting native win32
std::thread?

2. There is some plan to develop it?


Thanks for your help and support

Marco
------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to