Anyone have a working makefile for Stockfish under MS Visual Studio 2010? Any special options I should be using?
I compiled Stockfish 1.8 at one time, but I lost the makefile I used.
Compiling Stockfish MSVS 2010
-
- Posts: 127
- Joined: Thu Jun 10, 2010 1:39 am
- Real Name: Martin Wyngaarden
- Location: Holland, Michigan
Re: Compiling Stockfish MSVS 2010
Stockfish is pretty easy to make at the command line with the MS compiler.Webkikr wrote:Anyone have a working makefile for Stockfish under MS Visual Studio 2010? Any special options I should be using?
I compiled Stockfish 1.8 at one time, but I lost the makefile I used.
cl /Festockfish /Ox /DNDEBUG /DIS_64BIT /DUSE_POPCNT /DUSE_PREFETCH *.cpp
of course only use /DIS_64BIT and /DUSE_POPCNT if you can
to do a PGO attach /GL /link /LTCG:PGI
then
stockfish bench 32 1 10 default depth
and re-link: link /LTCG:PGO /OUT:stockfish.exe *.obj
-
- Posts: 40
- Joined: Sat Jun 19, 2010 11:00 pm
- Real Name: Lee Neuse
Re: Compiling Stockfish MSVS 2010
An excellent reply: succinct, helpful, and accurate. Wish there was a way to applaud...oh, wait...I just did.
Re: Compiling Stockfish MSVS 2010
How does this compare to using the ICC compiler for POPCNT? Does the MS compiler do popcnt enabling as well? Curious which one runs better once compiled. Cheers
- kingliveson
- Posts: 1388
- Joined: Thu Jun 10, 2010 1:22 am
- Real Name: Franklin Titus
- Location: 28°32'1"N 81°22'33"W
Re: Compiling Stockfish MSVS 2010
dbxuau wrote:How does this compare to using the ICC compiler for POPCNT? Does the MS compiler do popcnt enabling as well? Curious which one runs better once compiled. Cheers
Both ICC and MSVC have built-in intrinsic functions _mm_popcnt_u64 and __popcnt64 respectively. There should be no difference in speed because they map to CPU specific instructions.
As far as ICC vs MSVC, personal experience is ICC produces faster x86_64 binaries and MSVC, faster x86 binaries.
PAWN : Knight >> Bishop >> Rook >>Queen