Contents page | Winboard setup | Command line parameters | Commands reference | Licence and Warranty

# Commands Reference: Test Commands

analhash | - Analyse hash table contents.
endtest | - Run test for whether game is finished.
hamm | - Check hamming distance/Generate hash key data.
kpk | - Probe KPK endgame table (for current position).
kpktest | - Test KPK endgame table against Edwards tablebase.
perf | - Psuedo move generation/move performance test.
perfc | - Capture move generation/move performance test.
perft | - Psuedo move generation tree test.
score | - Show evaluation of current position.
tbanal | - Analyse Edwards tablebase file.
tbprobe | - Probe Edwards TB/Set Edwards TB directory.
testeval | - Test evaluation for black/white consistency.

##

The analhash command

### Summary

The analhash command scans the contents of the hash table and produces a report about its findings. It also reports some extra hash table counters that are not shown at the end of thinking.

### Format

`

      analh[ash]

`

##

The endtest command

### Summary

The endtest command simply tests whether the current position is an end of game position. I.E. it tests for checkmate, stalemate, draw-by-repetition, draw-by-50-move-rule and draw-by-insufficient-material.

### Format

`

      endt[est]

`

##

The hamm command

### Summary

The hamm command is used to generate and test the hash key data. It attempts to generate the hash keys with the minimum hamming distance that is specified. It is probably best to even exit the engine after running this command as it modifies the Zobrist hash key table, but doesn't make sure that anything else (e.g. the transposition table) has been updated to be in sync.

### Format

`

      hamm [max-hamm-dist]

`

##

The kpk command

### Summary

The kpk command causes the current position to be looked up in the internal KPK endgame table. If the current position isn't a KPK endgame then an error message is displayed instead. The KPK endgame table stores the distance (number of moves) to a successful promotion of the pawn (to a queen).

### Format

`

      kpk

`

##

The kpktest command

### Summary

The kpktest command verifies the internal KPK endgame table against the corresponding Edwards table base files.

### Format

`

      kpktest edwards-dir

`

##

The perf command

### Summary

The perf command performs the ssuedo move generation/move performance test. This test is done in two stages. In the first stage, the moves for the current position are repeatedly generated and thrown away. In the second stage, the moves are generated, and then each move is made and unmade on the board. At the end of each stage a report is made.

### Format

`

      perf

`

##

The perfc command

### Summary

The perfc command does the same as the perf test above, except it only generates the capture moves (which includes pawn promotions to queens.)

### Format

`

      perfc

`

##

The perft command

### Summary

The perft command generates and makes moves in a hierarchical tree structure rooted at the current position. It counts the number of "nodes" in the tree, and reports the amount of time it took to search to each depth in the tree.

### Format

`

      perft [depth]

`

##

The score command

### Summary

The score command shows a the static evaluation of current position, including lots of debug info showing how the the total score was arrived at.

### Format

`

      sc[ore]

`

##

The tbanal command

### Summary

The tbanal command analyses a single Edwards tablebase file. It produces a report of its findings. You specify which file to use with the "KxKy" and "w|b" parameters. You can optionally specify a restricted position for the major and minor pieces. Set up the directory for the tablebase files using the tbprobe command.

### Format

`

      tba[nal] KxKy w|b [major-sq [minor-sq]]

`

##

The tbprobe command

### Summary

The tbprobe command attempts to look up the current position in an Edwards tablebase file. If you supply a parameter, this sets the directory where the tablebase files reside.

### Format

`

      tbp[robe] [edwards-dir]

`

##

The testeval command

### Summary

The testeval command generates 10000 pseudo-legal random chess positions and their logical reflections (change side to move, flip board vertically, change colours of pieces), and makes sure that both evaluations of the same position match. This is great for catching black/white consistency mistakes in the coding of the static evaluation function.

### Format

`

      teste[val]

`

Send e-mail to chess@7sun.com.
Page last updated by Tim Foden on the 17th March 2003.