summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-05-20Add proper file headers.Mario Lang
2014-05-19Add proper file header.Mario Lang
2014-05-19Add proper file header.Mario Lang
2014-05-19Add proper file header.Mario Lang
2014-05-19Add proper file header.Mario Lang
2014-05-19Convert some file headers to the standard form including license.Mario Lang
2014-05-18Update commentary.Mario Lang
2014-05-18Avoid repeatedly calling chess-pos-en-passant.Mario Lang
2014-05-18Update URL.Mario Lang
2014-05-18Remove obsolte note.Mario Lang
2014-04-28Replace a few chess-incr-index calls with chess-next-index.Mario Lang
2014-04-27Simplify.Mario Lang
2014-04-26chess-pos.el: Another 10% speedup by precalculating sliding piece rays.Mario Lang
2014-04-26chess-perft.el: Another test case to improve coverage.Mario Lang
make perft now takes 13m45s.
2014-04-25chess-ai-eval-static: Avoid checking for mate if we just count mobility.Mario Lang
2014-04-25chess-search-position: Merge K testing into BRQ testing.Mario Lang
Another noticeable speedup.
2014-04-24chess-plain.el: Rename chess-plain-border-chars to chess-plain-border-style.Mario Lang
Also, remove chess-plain-draw-borders, if chess-plain-boder-style is nil, we do not draw any borders now.
2014-04-23Misc. fixes.Mario Lang
2014-04-23docstring fixes.Mario Lang
2014-04-22chess-ics.el: oics definition.Mario Lang
2014-04-21chess-legal-plies: Simplify the :color case.Mario Lang
2014-04-21chess-pos-search*: New function.Mario Lang
Search for several pieces in one swipe of the board, returning an alist of pieces and their indices. Use this in chess-legal-plies for the common case where we want all legal plies for a certain color makes the testsuite time go down to 9m57s.
2014-04-21chess-perft.el: Add another test case with depth 5.Mario Lang
Now that our execution time has been reduced significantly, add a bigger test case to improve the testsuite coverage. "make perft" now takes 10m33s.
2014-04-21chess-search-position: 20% performance improvement by treating ray pieces ↵Mario Lang
commonly. When we search for pieces of a certain color, we iterate over all results from all pieces of that color. However, this is redunant as we end up to check the compass rose twice, once for bishops/rooks and once for queens. We actually just need to check all 8 directions once and keep a list of what piece type can move in which direction.
2014-04-21chess-search-position: Move castling check for rooks out of the direction loop.Mario Lang
2014-04-20chess-pos.el: Eliminate unused conditional.Mario Lang
2014-04-20chess-pos.el: Collapse two chess-pos-piece-p calls into one chess-pos-piece ↵Mario Lang
call. Unexpected but true, this increases performance noticeably.
2014-04-20chess-pos.el: Refactor/simplify 10x12 code.Mario Lang
2014-04-20chess-pos.el: Convert 3 more chess-incr-index calls to chess-next-index.Mario Lang
2014-04-20chess-pos.el: Convert 2 more calls to chess-incr-index to chess-next-index.Mario Lang
2014-04-20chess-pos.el: Convert 4 more chess-incr-index calls to chess-next-index.Mario Lang
2014-04-19chess-knight-directions: New constant.Mario Lang
2014-04-19chess-pos.el: Define constant lists of directions various pieces can move to.Mario Lang
This avoid useless consing and makes things a bit more reusable.
2014-04-19chess-next-index: A 10x12 mailbox based function for advancing indices.Mario Lang
This one is a lot faster then chess-incr-index. Casual replacing in some caller sites yields about 30% performance improvement, more to be gained if more callers are converted.
2014-04-19chess-polyglot.el: Docs + one assert.Mario Lang
2014-04-19chess-perft: Interactive spec and progress info.Mario Lang
2014-04-18Silly typo.Mario Lang
2014-04-18chess-perft: Refactor to avoid repeatedly visiting the same list of plies at ↵Mario Lang
depth 1.
2014-04-18Remove obsolete note.Mario Lang
2014-04-18chess-perft: Simplify en-passant checks.Mario Lang
2014-04-18chess-pos-move: Really remove castling ability if rook has been moved.Mario Lang
This one was *very subtle. Looking at the code, we already tried to prevent this case, and it evenw orked for *some* instances. The problem is that castling flags are boolean in the position structure, chess-pos-can-castle determines the rook location from the position if castling flag is true. But we have already moved the rook around in chess-pos-move before we do the fixup stuff, so chess-pos-can-castle is just wrong in some cases. Fix is simple, call chess-pos-can-castle before we modify the position, and use these values later. This fixes the remaining perft mixmatches.
2014-04-18chess-perft.el: Count en passant and promotion plies.Mario Lang
Also, add ERT tags to selectively run tests which validate a certain ply property, like :castle or :check.
2014-04-18Add the perft makefile target for easy running of the testsuite.Mario Lang
2014-04-18chess-legal-plies: It is illegal to castle if the king is in check right now.Mario Lang
2014-04-18chess-legal-plies: Stop generating duplicate castling moves.Mario Lang
2014-04-18chess-legal-plies: Generate R and B promotions in addtion to Q and N.Mario Lang
2014-04-18chess-perft.el: ert tests to find move generator bugs.Mario Lang
2014-04-17chess-perft.el: move generator testing.Mario Lang
2014-04-17chess-ics.el: Add guest login support for chess.net.Mario Lang
2014-04-16chess-ai.el: Spare computing time by consulting the opening book.Mario Lang