And tell me how many syscalls does stockfish makes when thinking?dangi12012 wrote: ↑Thu Dec 02, 2021 11:45 pmI feel second hand embarrassment... or Fremdschämen now.
Cygwin is not as fast as a native linux program. Who would have thought? Apperently not you. You think that having a translation layer is free.
But to not make you embarrased more: Its only when system calls are involved. You know like getting time - opening a file WRITING TO THE CONSOLE etc.. only that part is slower.
https://softwareengineering.stackexchan ... n%20Linux).
To make this interesting for other people here: Calls that dont exist in windows had to be supported very creatively. Like the good description by actual experts under "Process Creation" found here:
https://cygwin.com/cygwin-ug-net/highlights.html
Cfish for Windows possible ?
Moderator: Ras
-
- Posts: 391
- Joined: Tue Oct 08, 2019 11:39 pm
- Full name: Tomasz Sobczyk
Re: Cfish for Windows possible ?
dangi12012 wrote:No one wants to touch anything you have posted. That proves you now have negative reputations since everyone knows already you are a forum troll.
Maybe you copied your stockfish commits from someone else too?
I will look into that.
-
- Posts: 1062
- Joined: Tue Apr 28, 2020 10:03 pm
- Full name: Daniel Infuehr
Re: Cfish for Windows possible ?
Idk what PEFFT means but i am happy if you provide an urlAndrewGrant wrote: ↑Thu Dec 02, 2021 11:51 pmCfish when up to date with Stockfish has always been faster by 10% to 15%.dangi12012 wrote: ↑Thu Dec 02, 2021 11:20 pmCFish repo translation is over one year old - so any "conclusions" you might draw are useless because it is not the current state of the software.AndrewGrant wrote: ↑Thu Dec 02, 2021 11:04 pm So is CFish faster than C++ Stockfish because Stockfish devs are unaware of how to write the language to the degree of competence you can, or because Ronald is a genius?
Why would a C program be faster than the corresponding C++ program?
It wouldnt be unless you strip out and optimize the code - like they did for CFish.
https://github.com/syzygy1/Cfish/network
Were you too lazy to look that up?
In light of your ability to demonstrate something to counter this, I will stand by the collective belief most hold.
Since you've thrown an insult, I find it a good time to point out that your movegen thing is not even close to the fastest thing out there. There are PEFFT programs that beat what you have done, using bitboards, by orders of magnitude.
Its not for me to "demonstrate how C++ is faster than C" so you are satisfied. Either you read the documentation and think for yourself or you are stuck with your own assumptions.
Let me just expand an olive branch for you to read: https://www.quora.com/Is-C++-slower-tha ... ignificant
And then watch this EYE OPENING youtube video - by an actual world leading expert.
Worlds-fastest-Bitboard-Chess-Movegenerator
Daniel Inführ - Software Developer
Daniel Inführ - Software Developer
-
- Posts: 1957
- Joined: Tue Apr 19, 2016 6:08 am
- Location: U.S.A
- Full name: Andrew Grant
Re: Cfish for Windows possible ?
I take it that you outsourced your website then?dangi12012 wrote: ↑Fri Dec 03, 2021 12:14 amIdk what PEFFT means but i am happy if you provide an urlAndrewGrant wrote: ↑Thu Dec 02, 2021 11:51 pmCfish when up to date with Stockfish has always been faster by 10% to 15%.dangi12012 wrote: ↑Thu Dec 02, 2021 11:20 pmCFish repo translation is over one year old - so any "conclusions" you might draw are useless because it is not the current state of the software.AndrewGrant wrote: ↑Thu Dec 02, 2021 11:04 pm So is CFish faster than C++ Stockfish because Stockfish devs are unaware of how to write the language to the degree of competence you can, or because Ronald is a genius?
Why would a C program be faster than the corresponding C++ program?
It wouldnt be unless you strip out and optimize the code - like they did for CFish.
https://github.com/syzygy1/Cfish/network
Were you too lazy to look that up?
In light of your ability to demonstrate something to counter this, I will stand by the collective belief most hold.
Since you've thrown an insult, I find it a good time to point out that your movegen thing is not even close to the fastest thing out there. There are PEFFT programs that beat what you have done, using bitboards, by orders of magnitude.
Its not for me to "demonstrate how C++ is faster than C" so you are satisfied. Either you read the documentation and think for yourself or you are stuck with your own assumptions.
Let me just expand an olive branch for you to read: https://www.quora.com/Is-C++-slower-tha ... ignificant
And then watch this EYE OPENING youtube video - by an actual world leading expert.

And ... the entire code base?
https://github.com/Gigantua/Gigantua/search?q=PERFT
-
- Posts: 463
- Joined: Mon Jun 07, 2010 3:13 am
- Location: Holland, MI
- Full name: Martin W
Re: Cfish for Windows possible ?
That's an 80 minutes video. Can you point to the relevant part?dangi12012 wrote: ↑Fri Dec 03, 2021 12:14 amIdk what PEFFT means but i am happy if you provide an urlAndrewGrant wrote: ↑Thu Dec 02, 2021 11:51 pmCfish when up to date with Stockfish has always been faster by 10% to 15%.dangi12012 wrote: ↑Thu Dec 02, 2021 11:20 pmCFish repo translation is over one year old - so any "conclusions" you might draw are useless because it is not the current state of the software.AndrewGrant wrote: ↑Thu Dec 02, 2021 11:04 pm So is CFish faster than C++ Stockfish because Stockfish devs are unaware of how to write the language to the degree of competence you can, or because Ronald is a genius?
Why would a C program be faster than the corresponding C++ program?
It wouldnt be unless you strip out and optimize the code - like they did for CFish.
https://github.com/syzygy1/Cfish/network
Were you too lazy to look that up?
In light of your ability to demonstrate something to counter this, I will stand by the collective belief most hold.
Since you've thrown an insult, I find it a good time to point out that your movegen thing is not even close to the fastest thing out there. There are PEFFT programs that beat what you have done, using bitboards, by orders of magnitude.
Its not for me to "demonstrate how C++ is faster than C" so you are satisfied. Either you read the documentation and think for yourself or you are stuck with your own assumptions.
Let me just expand an olive branch for you to read: https://www.quora.com/Is-C++-slower-tha ... ignificant
And then watch this EYE OPENING youtube video - by an actual world leading expert.
-
- Posts: 1062
- Joined: Tue Apr 28, 2020 10:03 pm
- Full name: Daniel Infuehr
Re: Cfish for Windows possible ?
The relevant part is towards the end where he summarizes what he did and how the compiler optimized his whole program away and in the end produced asm for an almost 30 year old system that is 1:1 translated to a 40 year old system the C64.
Some people have the misinformed opinion that C++ is somehow worse performing than C while its quite the opposite.
I want to say here that "speed" is not baked into any language per se but is a function of how well a compiler translates your intentions under the "as-if" rule.
With C++ you can convey your intentions more clearly with [[likely]] and other good baked in goodies like the STL and Templates. That enables the compiler to emit faster code under the "as-if" rule.
Worlds-fastest-Bitboard-Chess-Movegenerator
Daniel Inführ - Software Developer
Daniel Inführ - Software Developer
-
- Posts: 382
- Joined: Thu Jun 05, 2014 2:14 pm
- Location: Iran
- Full name: Mehdi Amini
Re: Cfish for Windows possible ?
For now , I am not able to access download of MinGW64 at source forge site. Meanwhile I tried LLVM-mingw . I was able to compile "hello world" but it seems make does not work for me in msvcrt or ucrt case. I got some errors.AndrewGrant wrote: ↑Thu Dec 02, 2021 5:10 pm I as able to build perfectly fine on windows in my first attempt -- "make build ARCH=x86-64-modern"
I believe it is important that you have a POSIX version of gcc, for pthread reasons.Code: Select all
$ gcc --version gcc.exe (x86_64-posix-seh-rev0, Built by MinGW-W64 project) 8.1.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.
Farewell.
-
- Posts: 28353
- Joined: Fri Mar 10, 2006 10:06 am
- Location: Amsterdam
- Full name: H G Muller
Re: Cfish for Windows possible ?
I have always used gcc. And yes, it works natively under Windows. When I compile with the option -mno-cygwin. Then it directly uses Windows API.dangi12012 wrote: ↑Thu Dec 02, 2021 9:54 pmYou claim your gcc runs natively in windows and you dont even know that you are linking against a posix translation layer.
-
- Posts: 1062
- Joined: Tue Apr 28, 2020 10:03 pm
- Full name: Daniel Infuehr
Re: Cfish for Windows possible ?
Update on your information: https://stackoverflow.com/questions/414 ... r/41586517hgm wrote: ↑Fri Dec 03, 2021 4:16 pmI have always used gcc. And yes, it works natively under Windows. When I compile with the option -mno-cygwin. Then it directly uses Windows API.dangi12012 wrote: ↑Thu Dec 02, 2021 9:54 pmYou claim your gcc runs natively in windows and you dont even know that you are linking against a posix translation layer.
Also this: https://stackoverflow.com/questions/779 ... t-is-mingw
So yeah you can use gcc with mingw (not cygwin) but every software that uses "fork" will crash.
What I am telling the people here is that you should think about using the more modern and better benchmarking compiler CLANG over gcc.
Dont use emulation layers - create native binaries and use them on the native system.
Worlds-fastest-Bitboard-Chess-Movegenerator
Daniel Inführ - Software Developer
Daniel Inführ - Software Developer
-
- Posts: 749
- Joined: Tue May 22, 2007 11:13 am
Re: Cfish for Windows possibl
https://nuwen.net/mingw.htmlhgm wrote: ↑Fri Dec 03, 2021 4:16 pmI have always used gcc. And yes, it works natively under Windows. When I compile with the option -mno-cygwin. Then it directly uses Windows API.dangi12012 wrote: ↑Thu Dec 02, 2021 9:54 pmYou claim your gcc runs natively in windows and you dont even know that you are linking against a posix translation layer.
This version of MinGW is actively maintained by Stephan T. Lavavej, Microsoft maintainer for their C++ Standard Library. It’s fully x64-native.
-
- Posts: 2696
- Joined: Tue Aug 30, 2016 8:19 pm
- Full name: Rasmus Althoff
Re: Cfish for Windows possible ?
Chess engines, which is what we're talking about in this thread, usually don't use fork anyway because they centre around threads, not processes. For that, plus thread synchronisation with mutexes and conditions, MingW with its pthread wrapper library (not Cygwin) works just fine. The main drawback is that it adds about 30kB to the executable.dangi12012 wrote: ↑Fri Dec 03, 2021 5:20 pmSo yeah you can use gcc with mingw (not cygwin) but every software that uses "fork" will crash.
Rasmus Althoff
https://www.ct800.net
https://www.ct800.net