]> git.sesse.net Git - remoteglot/blobdiff - Position.pm
Add a cache around prettyprint_pv, since it is consuming a lot of CPU.
[remoteglot] / Position.pm
index 9868b218e6c4e2b74b5d2a21eeb8623d849d1295..1a02d61d86f28626aff845546b79ddbde6e487c5 100644 (file)
@@ -35,6 +35,7 @@ sub new {
                $pos->{'last_move_uci'} = undef;
        }
        $pos->{'last_move'} = $x[29];
+       $pos->{'prettyprint_cache'} = {};
 
        bless $pos, $class;
        return $pos;