If you use gcc/g++ under msys2

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

Dann Corbit
Posts: 12537
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

If you use gcc/g++ under msys2

Post by Dann Corbit »

Gigantic update recently.
pacman -Syu
restart msys
pacman -Su

is good for you.

I had 141 packages updated, including bringing g++ and gcc up to 8.2

dcorbit@DCORBIT MINGW64 ~
$ g++ --version
g++.exe (Rev1, Built by MSYS2 project) 8.2.0
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
Dann Corbit
Posts: 12537
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: If you use gcc/g++ under msys2

Post by Dann Corbit »

Binaries built after the msys2 update:
Directory of F:\project\dcorbit\Stockfish-master2\src
2018-08-08 12:06 PM 1,184,256 stockfish-x64-crusty.exe
2018-08-08 12:04 PM 1,178,112 stockfish-x64-mingw.exe

Binaries built before the msys2 update (same code):
Directory of F:\project\dcorbit\Stockfish-master\src
2018-08-08 11:44 AM 1,428,992 stockfish-x64-crusty.exe
2018-08-08 11:42 AM 1,422,336 stockfish-x64-mingw.exe

Quite a bit smaller with the new version of the compiler. Doing a speed test now.
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
Dann Corbit
Posts: 12537
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: If you use gcc/g++ under msys2

Post by Dann Corbit »

New:
setoption name SyzygyPath value c:\chess\syzygy;
info string Found 510 tablebases
bench 4096 11

New compiler output:
Total time (ms) : 4346
Nodes searched : 31177066
Nodes/second : 7173738

Old compiler gives better NPS:
Total time (ms) : 4036
Nodes searched : 32715842
Nodes/second : 8106006
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.
Dann Corbit
Posts: 12537
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: If you use gcc/g++ under msys2

Post by Dann Corbit »

I think it was just SMP variability using multiple threads, because the numbers were all over on repeated runs.

Here is a single thread, no TB:

Old compiler:
Total time (ms) : 3805
Nodes searched : 4391118
Nodes/second : 1154038

New compiler:
Total time (ms) : 3613
Nodes searched : 4391118
Nodes/second : 1215366
Taking ideas is not a vice, it is a virtue. We have another word for this. It is called learning.
But sharing ideas is an even greater virtue. We have another word for this. It is called teaching.