Improve I/O responsivness

Added checking of (stdin->_cnt > 0) from Greko.

This seems to greatly improve responsivness when running
under console. Now while running a 'stockfish bench', any key
press immediately is detected by SF while before there was a
delay of some fraction of a second.

No functional change.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
Marco Costalba
2011-01-08 14:16:04 +01:00
parent d9b96f0e49
commit 0f81f97bb6
3 changed files with 23 additions and 12 deletions

View File

@@ -46,7 +46,7 @@
extern const std::string engine_name();
extern int get_system_time();
extern int cpu_count();
extern int data_available();
extern int input_available();
extern void prefetch(char* addr);
extern void prefetchPawn(Key, int);