<
Regenaxer>
tankf33der, the 'pipe' call looks good
<
Regenaxer>
I assume instead of (prinl @) you do something else then
stultulo has joined #picolisp
f8l has quit [Ping timeout: 264 seconds]
emacsomancer has quit [*.net *.split]
casaca has quit [*.net *.split]
cyborg_ar has quit [*.net *.split]
cyborg_ar has joined #picolisp
casaca has joined #picolisp
emacsomancer has joined #picolisp
<
tankf33der>
I belive i neee first form of pipe
<
tankf33der>
and in and out from file descriptor
<
Regenaxer>
Do you call myMove or yourMove directly somewhere
<
Regenaxer>
and/or the *Undo / *Redo stacks?
<
Regenaxer>
I want to extend the internal data structures to keep the move's scores
<
tankf33der>
My tests calls directly myMove and yourMove. I dont use cli.l
<
Regenaxer>
What changes is only the
*return* values of myMove and yourMove
<
Regenaxer>
I think the test will ignore them, no?
<
tankf33der>
Now ignoring and looping until mate.
<
tankf33der>
Do what you want i will update, no problem.
<
Regenaxer>
good, so I can safely change it
<
Regenaxer>
The score is returned in the CAR
<
tankf33der>
How should i call pipe for komodo in first form?
<
Regenaxer>
-> (9999 "BlackRook" d8 . d4)
<
Regenaxer>
(setq Fd (pipe (out '("foo))))
<
Regenaxer>
Then probably it needs a task on Fd
<
Regenaxer>
the answers are asyncronously
<
Regenaxer>
Why do you think you need the Fd version?
<
tankf33der>
Because i need read and write to komodo on both sides of pipe if called in second form.
<
Regenaxer>
Hmm, writing is always only on one side
<
Regenaxer>
Stdin of the child process
<
Regenaxer>
So you can write to Fd and read from Fd, yes
<
tankf33der>
komodo sometimes will play black, sometimes white
<
Regenaxer>
Make sure that the child always 'flush'es
<
tankf33der>
task i also never used and do not understand :)
<
Regenaxer>
otherwise the parent hangs
<
tankf33der>
i already seen this
<
Regenaxer>
With task it will not hang
<
Regenaxer>
not block
<
Regenaxer>
Done! Chess shows score of last move now
<
Regenaxer>
Released chess.tgz and chess.zip
<
Regenaxer>
Now you can see a score of -9999 when black noticed that it will lose
<
Regenaxer>
or 9999 if it is guaranteed to win
<
tankf33der>
Now i know when to stop battle against komodo :)
<
tankf33der>
anyway i dont know how to start it. Lol.
<
tankf33der>
Will start handle komodo after a lunch.
<
tankf33der>
For komodo i need properly init engine and handle loop: pass position, type go and skip output until “bestmove …”.
<
tankf33der>
Komodo provide old versions of engines, all versions, i will start from 2.x.
<
tankf33der>
Will disable all modern advandage feature it have except depth.
<
tankf33der>
Regenaxer
<
tankf33der>
i have this version, but it does not work
<
Regenaxer>
(setq Fd (pipe (out '(./komodo) (echo))))
<
Regenaxer>
Without (echo) the child terminates immediately
<
Regenaxer>
(echo) terminates on EOF
<
Regenaxer>
(out Fd (pr "uci") (flush)) 'flush' is not needed
<
Regenaxer>
because 'out' does a flush at the end
<
tankf33der>
cant get output from "uci" in (in ...)
<
Regenaxer>
yeah, cause komodo perhaps does not flush
<
Regenaxer>
strace kommodo
<
Regenaxer>
it receives data, prints something to internal buffers, but does not flush cause stdout is not a tty
<
Regenaxer>
I think you need a continuous stream
<
Regenaxer>
(pipe (out ...) (while ...))
<
tankf33der>
this is strace output
<
Regenaxer>
Hmm, only read from stdin but only errors
<
Regenaxer>
Unrelated, but why (pr "uci")?
<
Regenaxer>
Does komodo understand PLIO?
<
tankf33der>
of course not
<
tankf33der>
it was experiment
<
Regenaxer>
The read(0,... is in (echo)?
<
Regenaxer>
why read(0, 0x9840883c883, 1) only a single byte?
<
tankf33der>
this is strace from komodo9
<
Regenaxer>
Seems not to read anything from stdin
<
tankf33der>
all komodo engines do this
<
tankf33der>
this is current code
<
tankf33der>
and another engine
<
tankf33der>
latest stockfish
<
tankf33der>
look at output of code run:
<
tankf33der>
stockfish's strace
<
Regenaxer>
No idea
<
tankf33der>
list of chess engines:
<
Regenaxer>
How does this lisp code get there. Fd is 4
<
tankf33der>
too much
<
tankf33der>
give up.
<
Regenaxer>
me too afp
beneroth has joined #picolisp
beneroth is now known as Guest723
Guest723 is now known as beneroth
beneroth is now known as Guest1340
peterhil has joined #picolisp
mtsd has joined #picolisp
mtsd_ has joined #picolisp
mtsd_ has quit [Client Quit]
mtsd has quit [Client Quit]
<
tankf33der>
Stoped all mate searching, it works great, rest are waste of energy.
m42e has quit [Quit: WeeChat 3.1]
m42e has joined #picolisp
<
Regenaxer>
Perfect then :)
Regenaxer has left #picolisp [#picolisp]
Regenaxer has joined #picolisp
<
Regenaxer>
tankf33der, but perhaps you can run the existing tests once more, cause I changed lib.ldto propagate the score?
<
Regenaxer>
Latest version from today
<
Regenaxer>
No hurry :)
<
Regenaxer>
Good night!
Guest1340 has quit [Quit: Leaving]