PVS & Embla
Moderators: hgm, Rebel, chrisw
Re: PVS & Embla
Ah that I didn't know. Can you advise one by any chance? I'm currently use the dc-3200.bin polyglot book (from http://rebel13.nl/download/books.html).
Re: PVS & Embla
I'm going to fix that right away. Sorry for the inconvenience!
Takes a bit due to heavy merging.
Takes a bit due to heavy merging.
-
- Posts: 6995
- Joined: Thu Aug 18, 2011 12:04 pm
Re: PVS & Embla
Not one of your usual best advices SvenSven wrote:Furthermore I recommend to avoid using "goto" (you do it in your PVS code)
In many cases a programmer outsmarts the compiler and the hardware branch prediction. If you know in advance that in (say) 90% of the cases the branch will be taken or not then why would you leave the decision to the compiler?
I know, can of worms, I know
-
- Posts: 4052
- Joined: Thu May 15, 2008 9:57 pm
- Location: Berlin, Germany
- Full name: Sven Schüle
Re: PVS & Embla
We are talking about the goto inRebel wrote:Not one of your usual best advices SvenSven wrote:Furthermore I recommend to avoid using "goto" (you do it in your PVS code)
In many cases a programmer outsmarts the compiler and the hardware branch prediction. If you know in advance that in (say) 90% of the cases the branch will be taken or not then why would you leave the decision to the compiler
I know, can of worms, I know
Code: Select all
if (bSearchPV)
retry:
score = -search(..., -beta, -alpha, ...);
else {
score = -search(..., -alpha - 1, -alpha, ...);
if (score > alpha && score < beta)
goto retry;
}
Code: Select all
if (bSearchPV) {
score = -search(..., -beta, -alpha, ...);
} else {
score = -search(..., -alpha - 1, -alpha, ...);
if (score > alpha && score < beta) {
score = -search(..., -beta, -alpha, ...);
}
}
Code: Select all
end_of_discussion_about_goto:
goto end_of_discussion_about_goto;
Re: PVS & Embla
Ok, they're now all up to date and I verified that they build with cygwin on windows 10.Sven wrote:Either there are more changes in that branch than what you planned to do, or your Git repo is not up to date again. So currently I can't see what you actually changed.
Also I can't build it even with most recent Cygwin.
-
- Posts: 4052
- Joined: Thu May 15, 2008 9:57 pm
- Location: Berlin, Germany
- Full name: Sven Schüle
Re: PVS & Embla
Thanks, build works out of the box nowflok wrote:Ok, they're now all up to date and I verified that they build with cygwin on windows 10.Sven wrote:Either there are more changes in that branch than what you planned to do, or your Git repo is not up to date again. So currently I can't see what you actually changed.
Also I can't build it even with most recent Cygwin.
I now see that your PVS branch has also removed LMR, and that your most recent branch "onecolor" is under heavy development today. So good luck
Re: PVS & Embla
Correct: I had to figure out how to integrate LMR back in later on. First get PVS stable, then LMR back in.
In my testing (30k games) I also have a branch with both in them. Haven't pushed it to git though.
In my testing (30k games) I also have a branch with both in them. Haven't pushed it to git though.
-
- Posts: 4052
- Joined: Thu May 15, 2008 9:57 pm
- Location: Berlin, Germany
- Full name: Sven Schüle
Re: PVS & Embla
I managed to compile all three branches: master, PVS, onecolor. But I could not get any of them to run under cutechess-cli. Maybe some problem at my side.flok wrote:E.g. in qs there is that BLIND code. It checks if a piece is protected or not. I determine that during movegen.
Depth 14 takes 3.8s without blind and with only 1 color generated and 3.3s with blind and both colors generated. If I replace it by something that checks on the spot, then ttd goes up to 10s.
[...]
I did that in an hour and then it suddenly did depth 31 in a few seconds So clearly this has side effects and haven't figured out what.
But apart from that: it is obvious that your generateMoveLists() has (had) side effects on which you rely so that removing them breaks your code. A possible approach would be to identify all those side effects (hopefully few - calculation of square protection perhaps), isolate them in code that can be called separately (obviously for both colors), and then manage to call move generation only for the current side but still getting your "side effects" from the isolated code. Now that sounds easy but in fact it may be difficult ... Nevertheless I think it will pay off, since you need it anyway for creating a captures-only move generator which would require that refactoring.
-
- Posts: 4052
- Joined: Thu May 15, 2008 9:57 pm
- Location: Berlin, Germany
- Full name: Sven Schüle
Re: PVS & Embla
Problem of not running under cutechess-cli was solved easily (cygwin DLLs had to be copied to the right folder ...). Now I run some tests. As expected, the "onecolor" version makes illegal moves so I took it out.Sven wrote:I managed to compile all three branches: master, PVS, onecolor. But I could not get any of them to run under cutechess-cli. Maybe some problem at my side.flok wrote:E.g. in qs there is that BLIND code. It checks if a piece is protected or not. I determine that during movegen.
Depth 14 takes 3.8s without blind and with only 1 color generated and 3.3s with blind and both colors generated. If I replace it by something that checks on the spot, then ttd goes up to 10s.
[...]
I did that in an hour and then it suddenly did depth 31 in a few seconds So clearly this has side effects and haven't figured out what.
But apart from that: it is obvious that your generateMoveLists() has (had) side effects on which you rely so that removing them breaks your code. A possible approach would be to identify all those side effects (hopefully few - calculation of square protection perhaps), isolate them in code that can be called separately (obviously for both colors), and then manage to call move generation only for the current side but still getting your "side effects" from the isolated code. Now that sounds easy but in fact it may be difficult ... Nevertheless I think it will pay off, since you need it anyway for creating a captures-only move generator which would require that refactoring.
Jumbo seems too strong for Embla, I even tried an old 0.4.14 version which is roughly 200 Elo points weaker than my current best version. So I'll match Embla versions against each other only.
Re: PVS & Embla
I usually let it battle against dorpsgek which is around 220 elo stronger.Sven wrote:Problem of not running under cutechess-cli was solved easily (cygwin DLLs had to be copied to the right folder ...). Now I run some tests. As expected, the "onecolor" version makes illegal moves so I took it out.
Jumbo seems too strong for Embla, I even tried an old 0.4.14 version which is roughly 200 Elo points weaker than my current best version. So I'll match Embla versions against each other only.
What do you do for tournament? Gauntlet?