Position::gives_check - use ci.ksq

Also remove a couple of local variables while
there.

No functional change.
Merge remote-tracking branch 'upstream/master'
Merge branch 'master' into update_stats
use weighted countermoves stats