Hi Guys, Just a quick volunteers-wanted notice.
I'm adding a score bar widget to a few GUI elements in Scid vs PC, for a point release hopefully in a few months,
and am briefly revisiting the inbuilt engine. Called from sc_pos_analyze (in tkscid.cpp) to src/engine.cpp (and a few other files).
It is also used by the scidlet engine/wrapper.
This proc has had virtually no use for a long time now, but i dimly recall it may have been the cause of Segfaults when it reached near-mate positions, but i'm definitely not sure, as i havent seen ScidvsPC segfault for a long time, and don't use nalimov bases examples like i used to.
Anyway, i was wondering if someone wanted to have a look at it, and without going overboard, improve and/or debug it.
If you check out scidvspc subversion head, you can see Hanish's new Score/eval bar which he wrote for the engine window mini boards, and i'm adopting for a main board score bar, and also the game browser and fics observed games.
Even just giving it a good probe through valgrind or clang/gcc -Wall would be appreciated. I'm not the most experienced C coder.
(Yes, sorry for all the warnings! Code readability always meant more to me than otherwise).
cheers, Steven
Scid vs PC built in engine
Moderator: Ras
-
- Posts: 613
- Joined: Wed Oct 13, 2010 9:44 am
- Location: Australia
-
- Posts: 669
- Joined: Sat Jun 08, 2013 10:07 am
- Location: France
- Full name: Roland Chastain
Re: Scid vs PC built in engine
Hi Steven. Interesting. I didn't know Scidlet. I compiled it and I am testing it.
If someone wishes to compile it too, here are the necessary files:
And here is a simple Makefile (tested under Linux):
I will come back to this discussion if I find something worth noting.
I never really used Scid vs PC. I will try to find time to discover it.
Regards.
Roland
If someone wishes to compile it too, here are the necessary files:
Code: Select all
attacks.h
common.h
dstring.cpp
dstring.h
engine.cpp
engine.h
error.h
hash.h
mfile.cpp
mfile.h
misc.cpp
misc.h
movelist.cpp
movelist.h
myassert.h
position.cpp
position.h
recog.cpp
recog.h
scidlet.cpp
sqlist.h
sqmove.h
sqset.h
timer.h
tokens.h
Code: Select all
scidlet: scidlet.cpp misc.cpp position.cpp dstring.cpp engine.cpp movelist.cpp recog.cpp
g++ -o $@ $^ -Wall -Wextra -Wno-class-memaccess
I never really used Scid vs PC. I will try to find time to discover it.
Regards.
Roland
Qui trop embrasse mal étreint.
-
- Posts: 613
- Joined: Wed Oct 13, 2010 9:44 am
- Location: Australia
Re: Scid vs PC built in engine
Ok, cheers. I've got a little stress testing happening, and haven't seen any segfaults yet.
Afaics, Shane Hudson wrote this engine himself, just as an aside to the C++ database backend + Tk gui. As you do
Afaics, Shane Hudson wrote this engine himself, just as an aside to the C++ database backend + Tk gui. As you do
-
- Posts: 161
- Joined: Wed Feb 17, 2021 7:44 pm
- Full name: Christian Petersen
Re: Scid vs PC built in engine
Hello Steven!
Scidlet might have 2200-2300 "Elo". Why and for what purpose would you let Scid call it nowadays, if I may ask?
Greetings
Scidlet might have 2200-2300 "Elo". Why and for what purpose would you let Scid call it nowadays, if I may ask?
Greetings
-
- Posts: 613
- Joined: Wed Oct 13, 2010 9:44 am
- Location: Australia
Re: Scid vs PC built in engine
I'm calling it through sc_pos analyze which currently analyzes the current game position, but it can also analyze any board for a set (short) period of time. This way i can add a static scorebar to any observed fics board, or any game browser window, both of which have no data structure asociated with them except a fen-like char board[66]
eg
# sc_pos board
> ......K..P....PPP.P..................P...p......p...Qkpp........ b
The fairly trivial new sub-command is "-board $BOARD"
sc_pos analyze -board {......K..P....PPP.P..................P...p......p...Qkpp........ b} -time 200
> 233 Kxe7
but the problem now is , any crash in scidlet/engine.cpp will crash the whole app.
eg
# sc_pos board
> ......K..P....PPP.P..................P...p......p...Qkpp........ b
The fairly trivial new sub-command is "-board $BOARD"
sc_pos analyze -board {......K..P....PPP.P..................P...p......p...Qkpp........ b} -time 200
> 233 Kxe7
but the problem now is , any crash in scidlet/engine.cpp will crash the whole app.
-
- Posts: 613
- Joined: Wed Oct 13, 2010 9:44 am
- Location: Australia
Re: Scid vs PC built in engine
I better add - for anyone testing in scid/vspc, Scidlet behaves quite badly in analysis mode when start/stop is pressed, as 'exit' is not supported.
I have recently added this sendToEngine $n ? which seems to make it alot better.
I have recently added this sendToEngine $n ? which seems to make it alot better.
Code: Select all
proc stopAnalyzeMode { {n 0} } {
.....
else {
if { $analysis(has_analyze$n) } {
sendToEngine $n exit
} else {
sendToEngine $n ?
}